Commit 1a20a316 authored by 姬鋆屾's avatar 姬鋆屾

parent 1b2583e2
......@@ -28,6 +28,12 @@ export default {
if (data.leavePerson == 0 || data.leavePerson) {
if (this.dict.staffList) {
data.leavePerson = this.dict.staffList[this.form.leavePerson];
for (let key in this.dict.staffList) {
if (this.dict.staffList[key] == data.leavePerson) {
data.leavePersonId = Number(key);
}
}
console.log(this.dict.staffList);
}
}
......
......@@ -234,8 +234,9 @@ export default {
}).then((res) => {
let data = res.data.data;
let obj = {};
console.log(data);
for (let key in data) {
obj[key] = data[key].name;
obj[data[key].id] = data[key].name;
}
this.staffList = obj;
this.dict.staffList = this.staffList;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment