|
@@ -1342,9 +1342,21 @@ export default {
|
|
|
},
|
|
},
|
|
|
/** 删除按钮操作 */
|
|
/** 删除按钮操作 */
|
|
|
handleDelete(row) {
|
|
handleDelete(row) {
|
|
|
|
|
+
|
|
|
const userIds = row.userId || this.ids;
|
|
const userIds = row.userId || this.ids;
|
|
|
|
|
+
|
|
|
|
|
+ // 筛选出 userType 为 '00' 的 userId
|
|
|
|
|
+ const excludedUserIds = this.userList
|
|
|
|
|
+ .filter(user => user.userType == '00')
|
|
|
|
|
+ .map(user => user.userId);
|
|
|
|
|
+
|
|
|
|
|
+ // 从 userIds 中剔除这些 userId
|
|
|
|
|
+ const finalUserIds = userIds.filter(userId =>
|
|
|
|
|
+ !excludedUserIds.includes(userId)
|
|
|
|
|
+ );
|
|
|
|
|
+
|
|
|
this.$confirm(
|
|
this.$confirm(
|
|
|
- '是否确认删除员工编号为"' + userIds + '"的数据项?【注意:删除后绑定的企业微信相关信息可能会错乱!!】',
|
|
|
|
|
|
|
+ '是否确认删除员工编号为"' + finalUserIds + '"的数据项?【注意:删除后绑定的企业微信相关信息可能会错乱!!】',
|
|
|
"警告",
|
|
"警告",
|
|
|
{
|
|
{
|
|
|
confirmButtonText: "确定",
|
|
confirmButtonText: "确定",
|
|
@@ -1353,7 +1365,7 @@ export default {
|
|
|
}
|
|
}
|
|
|
)
|
|
)
|
|
|
.then(function() {
|
|
.then(function() {
|
|
|
- return delUser(userIds);
|
|
|
|
|
|
|
+ return delUser(finalUserIds);
|
|
|
})
|
|
})
|
|
|
.then(() => {
|
|
.then(() => {
|
|
|
this.getList();
|
|
this.getList();
|