From: ivan Date: Sat, 6 Sep 2008 20:54:25 +0000 (+0000) Subject: don't link to customer service view unless the user has the ACL to view the resulting... X-Git-Tag: freeside_1_7_4rc1~202 X-Git-Url: http://git.freeside.biz/gitweb/?a=commitdiff_plain;h=bcb0e7d62c3533db5889bcfb97e312e277eceb0f;p=freeside.git don't link to customer service view unless the user has the ACL to view the resulting page --- diff --git a/FS/FS/UI/Web.pm b/FS/FS/UI/Web.pm index e4a9ac1b8..bcb4b0a78 100644 --- a/FS/FS/UI/Web.pm +++ b/FS/FS/UI/Web.pm @@ -138,6 +138,10 @@ sub svc_label_link { sub svc_X_link { my ($x, $m, $part_svc, $cust_svc) = @_ or return ''; + + return $x + unless $FS::CurrentUser::CurrentUser->access_right('View customer services'); + my $ahref = svc_url( 'ahref' => 1, 'm' => $m, @@ -149,6 +153,7 @@ sub svc_X_link { "$ahref$x"; } +#this probably needs an ACL too... sub svc_export_links { my ($m, $part_svc, $cust_svc) = @_ or return '';