[freeside-commits] freeside/rt/share/html/Elements SelectQueue, 1.1.1.2, 1.1.1.2.4.1
Mark Wells
mark at wavetail.420.am
Fri Dec 31 16:47:21 PST 2010
- Previous message: [freeside-commits] freeside/rt/lib/RT Principal_Overlay.pm, 1.1.1.12, 1.1.1.12.4.1 Queue_Overlay.pm, 1.1.1.12, 1.1.1.12.4.1 System.pm, 1.1.1.8, 1.1.1.8.4.1 Test.pm, 1.1.1.2, 1.1.1.2.4.1
- Next message: [freeside-commits] freeside/rt/share/html/Ticket Create.html, 1.1.1.2.4.2, 1.1.1.2.4.3
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /home/cvs/cvsroot/freeside/rt/share/html/Elements
In directory wavetail.420.am:/tmp/cvs-serv23404/rt/share/html/Elements
Modified Files:
Tag: FREESIDE_2_1_BRANCH
SelectQueue
Log Message:
limit ticket creation queue dropdowns based on ACL, RT#7778
Index: SelectQueue
===================================================================
RCS file: /home/cvs/cvsroot/freeside/rt/share/html/Elements/SelectQueue,v
retrieving revision 1.1.1.2
retrieving revision 1.1.1.2.4.1
diff -u -w -d -r1.1.1.2 -r1.1.1.2.4.1
--- SelectQueue 18 May 2010 18:45:58 -0000 1.1.1.2
+++ SelectQueue 1 Jan 2011 00:47:17 -0000 1.1.1.2.4.1
@@ -55,7 +55,7 @@
% if ($ShowNullOption) {
<option value="">-</option>
% }
-% for my $queue (@{$session{$cache_key}}) {
+% for my $queue (@{$session{$cache_key}{queues}}) {
<option value="<% ($NamedValues ? $queue->{Name} : $queue->{Id}) %>"
% if ($queue->{Id} eq ($Default||'') || $queue->{Name} eq ($Default||'')) {
@@ -90,18 +90,27 @@
. $session{'CurrentUser'}->Id
. "---$CheckQueueRight---$ShowAllQueues";
+if ( defined $session{$cache_key} && ref $session{$cache_key} eq 'ARRAY') {
+ delete $session{$cache_key};
+}
+if ( defined $session{$cache_key} &&
+ $session{$cache_key}{lastupdated} <= RT->System->QueueCacheNeedsUpdate ) {
+ delete $session{$cache_key};
+}
+
if (not defined $session{$cache_key} and not $Lite) {
my $q = new RT::Queues($session{'CurrentUser'});
$q->UnLimit;
while (my $queue = $q->Next) {
if ($ShowAllQueues || $queue->CurrentUserHasRight($CheckQueueRight)) {
- push @{$session{$cache_key}}, {
+ push @{$session{$cache_key}{queues}}, {
Id => $queue->Id,
Name => $queue->Name,
Description => $queue->Description,
};
}
}
+ $session{$cache_key}{lastupdated} = time();
}
</%init>
- Previous message: [freeside-commits] freeside/rt/lib/RT Principal_Overlay.pm, 1.1.1.12, 1.1.1.12.4.1 Queue_Overlay.pm, 1.1.1.12, 1.1.1.12.4.1 System.pm, 1.1.1.8, 1.1.1.8.4.1 Test.pm, 1.1.1.2, 1.1.1.2.4.1
- Next message: [freeside-commits] freeside/rt/share/html/Ticket Create.html, 1.1.1.2.4.2, 1.1.1.2.4.3
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the freeside-commits
mailing list