mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-18 20:51:23 +01:00
Fix custom rights option messes selected mail acl rights
This commit is contained in:
parent
c3136791b5
commit
a4b850cd8d
@ -3432,13 +3432,25 @@ app.classes.mail = AppJS.extend(
|
|||||||
acl_common_rights_selector: function(event,widget)
|
acl_common_rights_selector: function(event,widget)
|
||||||
{
|
{
|
||||||
var rowId = widget.id.replace(/[^0-9.]+/g, '');
|
var rowId = widget.id.replace(/[^0-9.]+/g, '');
|
||||||
var rights = (widget.get_value() == "custom"?[]:widget.get_value() == "aeiklprstwx")?
|
var rights = [];
|
||||||
widget.get_value().replace(/[k,x,t,e]/g,"cd").split(""):widget.get_value().split("");
|
|
||||||
|
switch (widget.get_value())
|
||||||
for (var i=0;i<this.aclRights.length;i++)
|
|
||||||
{
|
{
|
||||||
var rightsWidget = this.et2.getWidgetById(rowId+'[acl_' + this.aclRights[i]+ ']');
|
case 'custom':
|
||||||
rightsWidget.set_value((jQuery.inArray(this.aclRights[i],rights) != -1 )?true:false);
|
break;
|
||||||
|
case 'aeiklprstwx':
|
||||||
|
rights = widget.get_value().replace(/[k,x,t,e]/g,"cd").split("");
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
rights = widget.get_value().split("");
|
||||||
|
}
|
||||||
|
if (rights.length > 0)
|
||||||
|
{
|
||||||
|
for (var i=0;i<this.aclRights.length;i++)
|
||||||
|
{
|
||||||
|
var rightsWidget = this.et2.getWidgetById(rowId+'[acl_' + this.aclRights[i]+ ']');
|
||||||
|
rightsWidget.set_value((jQuery.inArray(this.aclRights[i],rights) != -1 )?true:false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user