From d1965ef64c2cee4f6e1b4b531a754b5790902cf2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rapha=C3=ABl=20Barrois?= Date: Sun, 19 Sep 2010 17:31:56 +0200 Subject: [PATCH] Fix listing of xnetevent participants. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Raphaël Barrois --- modules/xnetevents.php | 2 +- modules/xnetevents/xnetevents.inc.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/xnetevents.php b/modules/xnetevents.php index 4db4710..8702d79 100644 --- a/modules/xnetevents.php +++ b/modules/xnetevents.php @@ -638,7 +638,7 @@ class XnetEventsModule extends PLModule $page->assign('absents', $absents); $page->assign('participants', get_event_participants($evt, $item_id, UserFilter::sortByName(), - new PLLimit(NB_PER_PAGE), $ofs * NB_PER_PAGE)); + new PLLimit(NB_PER_PAGE, $ofs * NB_PER_PAGE))); } } diff --git a/modules/xnetevents/xnetevents.inc.php b/modules/xnetevents/xnetevents.inc.php index 93f011c..237e3f7 100644 --- a/modules/xnetevents/xnetevents.inc.php +++ b/modules/xnetevents/xnetevents.inc.php @@ -109,7 +109,7 @@ function get_event_detail($eid, $item_id = false, $asso_id = null) // }}} // {{{ function get_event_participants() -function get_event_participants(&$evt, $item_id, array $tri = array(), $count = null, $offset = null) +function get_event_participants(&$evt, $item_id, array $tri = array(), $limit = null) { global $globals; @@ -124,7 +124,7 @@ function get_event_participants(&$evt, $item_id, array $tri = array(), $count = WHERE ep.eid = {?} AND nb > 0 ' . $append . ' GROUP BY ep.uid', $eid); $uf = new UserFilter(new PFC_True(), $tri); - $users = User::getBulkUsersWithUIDs($uf->filter(array_keys($query), $count, $offset)); + $users = User::getBulkUsersWithUIDs($uf->filter(array_keys($query), $limit)); $tab = array(); foreach ($users as $user) { $uid = $user->id(); -- 2.1.4