* addressbook: distributionlists, allow to add any seen contact to an available (and editable) distributionlist

This commit is contained in:
Klaus Leithoff 2011-12-28 10:55:24 +00:00
parent 9990fe45d6
commit d50d0f3d0a

View File

@ -469,7 +469,7 @@ class addressbook_ui extends addressbook_bo
), ),
'group' => $group, 'group' => $group,
); );
if (($add_lists = $this->get_lists(EGW_ACL_EDIT))) // do we have distribution lists? if (($add_lists = $this->get_lists(EGW_ACL_EDIT))) // do we have distribution lists?, and are we allowed to edit them
{ {
$actions['lists']['children'] += array( $actions['lists']['children'] += array(
'to_list' => array( 'to_list' => array(
@ -477,7 +477,8 @@ class addressbook_ui extends addressbook_bo
'children' => $add_lists, 'children' => $add_lists,
'prefix' => 'to_list_', 'prefix' => 'to_list_',
'icon' => 'foldertree_nolines_plus', 'icon' => 'foldertree_nolines_plus',
'disableClass' => 'rowNoEdit', 'enabled' => ($add_lists?true:false), // if there are editable lists, allow to add a contact to one of them,
//'disableClass' => 'rowNoEdit', // wether you are allowed to edit the contact or not, as you alter a list, not the contact
), ),
'remove_from_list' => array( 'remove_from_list' => array(
'caption' => 'Remove from distribution list', 'caption' => 'Remove from distribution list',