[freeside-commits] freeside/httemplate/view/cust_main tickets.html, 1.15, 1.15.4.1
Mark Wells
mark at wavetail.420.am
Fri Dec 31 16:47:19 PST 2010
Update of /home/cvs/cvsroot/freeside/httemplate/view/cust_main
In directory wavetail.420.am:/tmp/cvs-serv23404/httemplate/view/cust_main
Modified Files:
Tag: FREESIDE_2_1_BRANCH
tickets.html
Log Message:
limit ticket creation queue dropdowns based on ACL, RT#7778
Index: tickets.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/view/cust_main/tickets.html,v
retrieving revision 1.15
retrieving revision 1.15.4.1
diff -u -w -d -r1.15 -r1.15.4.1
--- tickets.html 22 Jul 2010 23:33:30 -0000 1.15
+++ tickets.html 1 Jan 2011 00:47:16 -0000 1.15.4.1
@@ -11,7 +11,9 @@
</SCRIPT>
<A id="CreateTicketLink" HREF="<% $new_link %>">Create new ticket</A>
in queue
-% my %queues = FS::TicketSystem->queues();
+%# fetch list of queues in which the user can create tickets
+% my $session = FS::TicketSystem->session();
+% my %queues = FS::TicketSystem->queues($session, 'CreateTicket');
% if( $conf->exists('ticket_system-force_default_queueid') ) {
<B><% $queues{$new_param{'Queue'}} %></B>
<INPUT TYPE="hidden" NAME="Queue" VALUE="<% $new_param{'Queue'} %>">
@@ -19,7 +21,6 @@
% else {
<SELECT NAME="Queue" id="Queue" onchange="updateTicketLink()">
% foreach my $queueid ( sort { $queues{$a} cmp $queues{$b} } keys %queues ) {
-% #should consider whether the user has ACL to create ticket in each queue
<OPTION VALUE="<% $queueid %>"
<% $queueid == $new_param{'Queue'} ? 'SELECTED' : '' %>
><% $queues{$queueid} |h %>
More information about the freeside-commits
mailing list