extend maestro status API for the multi-service scenario, RT#9334
[freeside.git] / httemplate / view / cust_main / attachments.html
index dbb29a7..bdd4f59 100755 (executable)
@@ -82,7 +82,7 @@
     <TR>
       <% note_datestr($attach,$conf,$bgcolor) %>
       <TD CLASS="grid" BGCOLOR="<% $bgcolor %>">
-        &nbsp;<% $attach->otaker%>
+        &nbsp;<% $attach->usernum ? $attach->access_user->name : $attach->otaker %>
       </TD>
       <TD CLASS="grid" BGCOLOR="<% $bgcolor %>">
        &nbsp;<% $attach->filename %>
 
 my $conf = new FS::Conf;
 my $curuser = $FS::CurrentUser::CurrentUser;
-
+die "access denied" if !$curuser->access_right('View attachments');
 my(%opt) = @_;
 
 my $custnum = $opt{'custnum'};