提交 ef135825 编写于 作者: U unknown

后台API增加listGroupWithIdentity

上级 ed53fbeb
......@@ -95,9 +95,16 @@
"张三@zhangsan@P",
"李四@lisi@P"
],
"identityList": [
"王五@kfb_wangwu@I",
"赵六@kfb_zhaoliu@I"
],
"groupList": [
"所有部门领导@AllDepartLeader@G",
"所有部门汇报管理员@AllDepartReportManager@G"
],
"unitList": [
"开发部@kfb@U"
]
}
}
\ No newline at end of file
......@@ -626,6 +626,21 @@
* var groupList = this.org.listGroupWithPerson( name );
*/
//身份所在群组(嵌套)--返回群组的对象数组
/**
* 根据身份标识获取所有的群组对象数组。如果群组具有群组(group)成员,且群组成员中包含该身份,那么该群组也被返回。
* @method listGroupWithIdentity
* @o2membercategory group
* @methodOf module:server.org
* @static
* @param {IdentityFlag|IdentityFlag[]} name - 身份的distinguishedName、name、id、unique属性值,身份对象,或上述属性值和对象的数组。
* @return {GroupData[]} 返回群组对象数组。
* @o2ActionOut x_organization_assemble_express.GroupAction.listWithPersonObject|example=Group
* @o2syntax
* //返回群组数组。
* var groupList = this.org.listGroupWithIdentity( name );
*/
//角色***************
//获取角色--返回角色的对象数组
......
......@@ -2155,7 +2155,7 @@ MWF.xScript.ViewEnvironment = function (ev) {
* @return {Promise|GroupData[]} 当async为true时,返回
* {@link https://developer.mozilla.org/zh-CN/docs/Web/JavaScript/Reference/Global_Objects/Promise|Promise}。
* 否则返回群组对象数组。
* @o2ActionOut x_organization_assemble_express.GroupAction.listGroupWithIdentity|example=Group
* @o2ActionOut x_organization_assemble_express.GroupAction.listWithPersonObject|example=Group
* @o2syntax
* //同步执行,返回群组数组。
* var groupList = this.org.listGroupWithIdentity( identity );
......
......@@ -338,6 +338,11 @@ var _org = {
var v = this.oGroup.listWithPerson(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//身份所在群组(嵌套)--返回群组的对象数组
listGroupWithIdentity:function(name){
var v = this.oGroup.listWithIdentity(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//群组是否拥有角色--返回true, false
groupHasRole: function(name, role){
nameFlag = (library.typeOf(name)==="object") ? (name.distinguishedName || name.id || name.unique || name.name) : name;
......
......@@ -553,6 +553,11 @@ var _org = {
var v = this.oGroup.listWithPerson(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//身份所在群组(嵌套)--返回群组的对象数组
listGroupWithIdentity:function(name){
var v = this.oGroup.listWithIdentity(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//群组是否拥有角色--返回true, false
groupHasRole: function(name, role){
nameFlag = (library.typeOf(name)==="object") ? (name.distinguishedName || name.id || name.unique || name.name) : name;
......
......@@ -328,6 +328,11 @@ var _org = {
var v = this.oGroup.listWithPerson(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//身份所在群组(嵌套)--返回群组的对象数组
listGroupWithIdentity:function(name){
var v = this.oGroup.listWithIdentity(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//群组是否拥有角色--返回true, false
groupHasRole: function(name, role){
nameFlag = (library.typeOf(name)==="object") ? (name.distinguishedName || name.id || name.unique || name.name) : name;
......
......@@ -2954,6 +2954,11 @@ var _org = {
var v = this.oGroup.listWithPerson(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//身份所在群组(嵌套)--返回群组的对象数组
listGroupWithIdentity:function(name){
var v = this.oGroup.listWithIdentity(getNameFlag(name));
return this.getObject(this.oGroup, v);
},
//群组是否拥有角色--返回true, false
groupHasRole: function(name, role){
nameFlag = (library.typeOf(name)==="object") ? (name.distinguishedName || name.id || name.unique || name.name) : name;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册