选择部门

This commit is contained in:
shijingjing
2023-03-02 09:24:02 +08:00
parent 25402fcfa4
commit f04ea2777d
2 changed files with 20 additions and 16 deletions

View File

@@ -98,12 +98,15 @@ export default {
type: ["department"], // 选部门
selectedDepartmentIds: this.deptListArr?.map(e => e.id) // 已选部门ID列表。用于多次选人时可重入
}).then((res)=>{
if(res?.userList) {
console.log(res,'企微通讯录');
this.deptListArr = res.userList
console.log(res,'企微通讯录');
if(res.err_msg == "selectEnterpriseContact:ok") {
if(typeof res.result == 'string') {
res.result = JSON.parse(res.result)
//由于目前各个终端尚未完全兼容需要开发者额外判断result类型以保证在各个终端的兼容性
}
this.deptListArr = res.result.departmentList
}
).catch((err) => {
}).catch((err) => {
this.$u.toast(err)
})
},