Browse Source

修改

master
mch 2 years ago
parent
commit
3b95ef762a
  1. 29
      src/components/unitGrouping/unitGroupCategory.vue
  2. 4
      src/components/unitGrouping/unitGroupingTable.vue

29
src/components/unitGrouping/unitGroupCategory.vue

@ -167,9 +167,9 @@ export default {
methods: {
//
Onsubmit() {
console.log(this.personnelUnit.form.id);
if (this.personnelUnit.form.id === "") {
this.$message.success("请选择单位分组");
console.log(this.personnelUnit.id);
if (this.personnelUnit.id === "") {
this.$message.warning("请选择单位分组");
} else {
postapi("/api/app/customer-org-group-detail/many", this.addrulst).then(
(res) => {
@ -181,15 +181,22 @@ export default {
//
addselecteditems() {
//personnelUnit.nogroupselected
if (this.rightselctedata.length == 0) {
this.$message.warning("已选数据为空无法移动");
} else {
let count = this.rightselctedata.length - 1;
for (var i = count; i >= 0; i--) {
this.personnelUnit.nogroupselected.splice(i, 1);
this.tabledata.push(this.rightselctedata[i]);
// this.personnelUnit.nogroupselected.splice(i, 1);
if (
!this.rightselctedata.includes(this.rightselctedata[i].displayName)
) {
this.tabledata.push(this.rightselctedata[i]);
this.personnelUnit.nogroupselected.splice(i, 1);
console.log(this.rightselctedata[i]);
}
// this.tabledata.push(this.rightselctedata[i]);
}
// this.
}
},
//
@ -206,8 +213,14 @@ export default {
this.saveornot = false;
let count = this.unselecteddata.length - 1;
for (var i = count; i >= 0; i--) {
this.tabledata.splice(i, 1);
this.personnelUnit.nogroupselected.push(this.unselecteddata[i]);
// this.tabledata.splice(i, 1);
// this.personnelUnit.nogroupselected.push(this.unselecteddata[i]);
if (
[...new Set(this.unselecteddata)]
) {
this.tabledata.splice(i, 1);
this.personnelUnit.nogroupselected.push(this.unselecteddata[i]);
}
}
this.unselecteddata.forEach((item) => {
this.addrulst.push({

4
src/components/unitGrouping/unitGroupingTable.vue

@ -276,9 +276,9 @@ export default {
});
//
getapi(
`/api/app/customer-org-group-detail/customer-org-group-detail-in-asbitem?CustomerOrgGroupId=${this.personnelUnit.id}`
`/api/app/customer-org-group-detail/customer-org-group-detail-in-asbitem?CustomerOrgGroupId=${this.personnelUnit.form.id}`
).then((res) => {
console.log(res.data,'当前列');
console.log(res.data, "当前列");
this.personnelUnit.nogroupselected = res.data;
console.log(this.personnelUnit.nogroupselected, "我是分组");
});

Loading…
Cancel
Save