Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.4.0

Bug #5310 order by on getUsers() doesn't work properly
Submitted: 2005-09-06 08:35 UTC Modified: 2006-12-24 14:40 UTC
From: jeroen at terena dot nl Assigned: lsmith
Status: Closed Package: LiveUser_Admin
PHP Version: 5.0.4 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2005-09-06 08:35 UTC] jeroen at terena dot nl
Description: ------------ Order by is ignored when listing the users from the perm container Test script: --------------- $params = array(); $params['orders'] = array('auth_user_id' => 'DESC'); $users = $lu_admin->perm->getUsers($params); FYI: The following bit inside findTables() seems to cause $oders to be reset: if (array_key_exists($field, $orders)) { $orders[$this->alias[$field]] = $orders[$field]; unset($orders[$field]); } When the table isn't aliased, it gets reset. Changing $order to an empty array() Expected result: ---------------- properly ordered array Actual result: -------------- default ordering

Comments

 [2005-09-06 08:41 UTC] lsmith
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. http://cvs.php.net/diff.php/pear/LiveUser_Admin/Storage/SQL.php?r1=1.38&r2=1.39&ty=u