mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 16:48:49 +01:00
Fix not selecting right ACL common options when the with different sorted rights. Now common rights abbrivation are sorted alphabetically
This commit is contained in:
parent
796e48cd3d
commit
ecc37850f0
@ -31,8 +31,8 @@ class mail_acl
|
||||
'lrs' => array('label'=>'readable','title'=>'Allows a user to read the contents of the mailbox.'),
|
||||
'lprs' => array('label'=>'post','title'=>'Allows a user to read the mailbox and post to it through the delivery system by sending mail to the submission address of the mailbox.'),
|
||||
'ilprs' => array('label'=>'append','title'=>'Allows a user to read the mailbox and append messages to it, either via IMAP or through the delivery system.'),
|
||||
'ilprws' => array('label'=>'write','title'=>'Allows a user to read the maibox, post to it, append messages to it, and delete messages or the mailbox itself. The only right not given is the right to change the ACL of the mailbox.'),
|
||||
'akxeilprwts'=> array('label'=>'all','title'=>'The user has all possible rights on the mailbox. This is usually granted to users only on the mailboxes they own.'),
|
||||
'ilprsw' => array('label'=>'write','title'=>'Allows a user to read the maibox, post to it, append messages to it, and delete messages or the mailbox itself. The only right not given is the right to change the ACL of the mailbox.'),
|
||||
'aeiklprstwx'=> array('label'=>'all','title'=>'The user has all possible rights on the mailbox. This is usually granted to users only on the mailboxes they own.'),
|
||||
'custom' => array('label'=>'custom','title'=>'User defined combination of rights for the ACL'),
|
||||
);
|
||||
|
||||
@ -93,6 +93,7 @@ class mail_acl
|
||||
$content['grid'][$n]['acl_c'] = array_diff($virtuals['c'],array_intersect($rights,$virtuals['c']))? false: true; //c=kx more information rfc4314, Obsolote Rights
|
||||
$content['grid'][$n]['acl_d'] = array_diff($virtualD,array_intersect($rights,$virtuals['d']))? false: true; //d=et more information rfc4314, Obsolote Rights
|
||||
|
||||
sort($rights);
|
||||
$acl_abbrvs = implode('',$rights);
|
||||
|
||||
if (array_key_exists($acl_abbrvs, $this->aclRightsAbbrvs))
|
||||
|
@ -50,7 +50,7 @@ app.classes.mail = AppJS.extend(
|
||||
* @array
|
||||
*
|
||||
*/
|
||||
aclCommonRights:['lrs','lprs','ilprs', 'ilprws', 'akxeilprwts', 'custom'],
|
||||
aclCommonRights:['lrs','lprs','ilprs', 'ilprsw', 'aeiklprstwx', 'custom'],
|
||||
/**
|
||||
* Demonstrates ACL rights
|
||||
* @array
|
||||
@ -2575,7 +2575,7 @@ app.classes.mail = AppJS.extend(
|
||||
acl_common_rights_selector: function(event,widget)
|
||||
{
|
||||
var rowId = widget.id.replace(/[^0-9.]+/g, '');
|
||||
var rights = (widget.get_value() == "custom")?[]:(widget.get_value() == "akxeilprwts")? widget.get_value().replace(/[k,x,t,e]/g,"cd").split(""):widget.get_value().split("");
|
||||
var rights = (widget.get_value() == "custom")?[]:(widget.get_value() == "aeiklprstwx")? widget.get_value().replace(/[k,x,t,e]/g,"cd").split(""):widget.get_value().split("");
|
||||
for (var i=0;i<this.aclRights.length;i++)
|
||||
{
|
||||
var rightsWidget = this.et2.getWidgetById(rowId+'[acl_' + this.aclRights[i]+ ']');
|
||||
@ -2616,7 +2616,7 @@ app.classes.mail = AppJS.extend(
|
||||
}
|
||||
else if (rights =='lrswipcda')
|
||||
{
|
||||
aclCommonWidget.set_value('akxeilprwts');
|
||||
aclCommonWidget.set_value('aeiklprstwx');
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user