diff --git a/src/views/ea/electronicEmployee/index.vue b/src/views/ea/electronicEmployee/index.vue index 331403dd..807275c0 100644 --- a/src/views/ea/electronicEmployee/index.vue +++ b/src/views/ea/electronicEmployee/index.vue @@ -687,6 +687,7 @@ export default { Authorization: "Bearer " + getAccessToken(), "tenant-id": getTenantId(), }, // 设置上传的请求头 + optType: undefined, fileList: [], // 文件列表 // 部门树选项 deptOptions: undefined, @@ -986,24 +987,24 @@ export default { /** 查看按钮操作 */ handleView(row) { this.reset(); - this.optType = "view"; const id = row.id; getElectronicEmployee(id).then((response) => { this.form = response.data; this.dateArray(this.form.birthdate); this.open = true; + this.optType = "view"; this.title = "查看员工档案"; }); }, /** 修改按钮操作 */ handleUpdate(row) { this.reset(); - this.optType = "edit"; const id = row.id; getElectronicEmployee(id).then((response) => { this.form = response.data; this.dateArray(this.form.birthdate); this.open = true; + this.optType = "edit"; this.title = "修改员工档案"; }); }, diff --git a/src/views/ea/electronicOther/index.vue b/src/views/ea/electronicOther/index.vue index 5f939011..a35ed2d2 100644 --- a/src/views/ea/electronicOther/index.vue +++ b/src/views/ea/electronicOther/index.vue @@ -339,7 +339,7 @@ @@ -368,6 +368,7 @@ export default { components: { Treeselect }, data() { return { + optType:undefined, // 部门树选项 deptOptions: undefined, // 遮罩层 @@ -597,15 +598,18 @@ export default { this.reset(); this.fileList = []; this.open = true; + this.optType = "add"; this.title = "添加其他档案"; }, /** 修改按钮操作 */ handleUpdate(row) { this.reset(); const id = row.id; + getElectronicOther(id).then((response) => { this.form = response.data; this.open = true; + this.optType = "edit"; this.title = "修改其他档案"; }); },