[freeside-commits] freeside/httemplate/elements select-user.html, 1.2, 1.3

Ivan,,, ivan at wavetail.420.am
Sun Aug 15 00:00:23 PDT 2010


Update of /home/cvs/cvsroot/freeside/httemplate/elements
In directory wavetail.420.am:/tmp/cvs-serv21093/elements

Modified Files:
	select-user.html 
Log Message:
additional by-otaker searches fixed for the brave new world of usernum, RT#9555

Index: select-user.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/select-user.html,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -w -d -r1.2 -r1.3
--- select-user.html	15 Aug 2010 06:21:06 -0000	1.2
+++ select-user.html	15 Aug 2010 07:00:21 -0000	1.3
@@ -4,7 +4,10 @@
   <OPTION VALUE="">all</OPTION>
 % }
 
-% foreach my $usernum ( keys %{ $opt{'access_user'} } ) { 
+% foreach my $usernum (
+%   sort { $opt{'access_user'}->{$a} cmp $opt{'access_user'}->{$b} }
+%   keys %{ $opt{'access_user'} }
+% ) { 
     <OPTION VALUE="<%$usernum%>"><% $opt{'access_user'}->{$usernum} %></OPTION>
 % } 
 
@@ -16,12 +19,9 @@
 
 unless ( $opt{'access_user'} ) {
 
-  tie %{ $opt{'access_user'} }, 'Tie::IxHash';
-
   my $sth = dbh->prepare("
     SELECT usernum, username FROM access_user
       WHERE disabled = '' or disabled IS NULL
-        ORDER BY username
   ") or die dbh->errstr;
   $sth->execute or die $sth->errstr;
   while ( my $row = $sth->fetchrow_arrayref ) {



More information about the freeside-commits mailing list