[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] preferences/inc class.boadmin_acl.inc.php
From: |
Sigurd Nes |
Subject: |
[Phpgroupware-cvs] preferences/inc class.boadmin_acl.inc.php |
Date: |
Fri, 13 Oct 2006 20:59:03 +0000 |
CVSROOT: /sources/phpgroupware
Module name: preferences
Changes by: Sigurd Nes <sigurdne> 06/10/13 20:59:03
Modified files:
inc : class.boadmin_acl.inc.php
Log message:
Clean up
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/preferences/inc/class.boadmin_acl.inc.php?cvsroot=phpgroupware&r1=1.5&r2=1.6
Patches:
Index: class.boadmin_acl.inc.php
===================================================================
RCS file: /sources/phpgroupware/preferences/inc/class.boadmin_acl.inc.php,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- class.boadmin_acl.inc.php 4 Oct 2006 09:51:00 -0000 1.5
+++ class.boadmin_acl.inc.php 13 Oct 2006 20:59:03 -0000 1.6
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package hrm
* @subpackage admin
- * @version $Id: class.boadmin_acl.inc.php,v 1.5 2006/10/04 09:51:00
sigurdne Exp $
+ * @version $Id: class.boadmin_acl.inc.php,v 1.6 2006/10/13 20:59:03
sigurdne Exp $
*/
/**
@@ -390,5 +390,46 @@
return $user_list;
}
+
+ function get_group_list($format='',$selected='',$start='',
$sort='', $order='', $query='',$offset='')
+ {
+ switch($format)
+ {
+ case 'select':
+
$GLOBALS['phpgw']->xslttpl->add_file(array('group_select'));
+ break;
+ case 'filter':
+
$GLOBALS['phpgw']->xslttpl->add_file(array('group_filter'));
+ break;
+ }
+
+ $accounts = CreateObject('phpgwapi.accounts');
+ $groups = $accounts->get_list('groups', $start, $sort,
$order, $query,$offset);
+ unset($accounts);
+ if (isSet($groups) AND is_array($groups))
+ {
+ foreach($groups as $group)
+ {
+ if ($group['account_id']==$selected)
+ {
+ $group_list[] = array
+ (
+ 'id' =>
$group['account_id'],
+ 'name' =>
$group['account_firstname'],
+ 'selected' =>
'selected'
+ );
+ }
+ else
+ {
+ $group_list[] = array
+ (
+ 'id' =>
$group['account_id'],
+ 'name' =>
$group['account_firstname'],
+ );
+ }
+ }
+ }
+ return $group_list;
+ }
}
?>