mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-11-22 07:14:21 +00:00
feat(mail(js)): new button to expand recipients that are LDAP groups
This commit is contained in:
1 parent
f140bba03a
commit
456a66b66b
8 files changed
+81
-22
No files matched your search
@@ -254,7 +254,7 @@
|
||||
if (this.members)
|
||||
return Card.$q.when(this.members);
|
||||
|
||||
if (this.isgroup) {
|
||||
if (this.$isGroup({expandable: true})) {
|
||||
return Card.$$resource.fetch(this.$path(), 'members').then(function(data) {
|
||||
_this.members = _.map(data.members, function(member) {
|
||||
return new Card(member);
|
||||
@@ -262,6 +262,8 @@
|
||||
return _this.members;
|
||||
});
|
||||
}
|
||||
|
||||
return Card.$q.reject("Card " + this.id + " is not an LDAP group");
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -429,6 +431,11 @@
|
||||
return this.c_component == 'vlist' && condition;
|
||||
};
|
||||
|
||||
Card.prototype.$isGroup = function(options) {
|
||||
var condition = (!options || !options.expandable || options.expandable && Card.$Preferences.defaults.SOGoLDAPGroupExpansionEnabled);
|
||||
return this.isgroup && condition;
|
||||
};
|
||||
|
||||
Card.prototype.$addOrg = function(org) {
|
||||
if (angular.isUndefined(this.orgs)) {
|
||||
this.orgs = [org];
|
||||
|
||||
Reference in new issue
Block a user