部门修改

This commit is contained in:
zoujiandong 2023-07-19 08:55:57 +08:00
parent 953cb0ded0
commit df6f3a3b2c

View File

@ -55,9 +55,9 @@
@close="() => $refs.modalFormRef.resetFields()"
>
<a-form :model="modalForm" :rules="rules" ref="modalFormRef">
<a-form-item field="parentId" label="上级部门">
<a-form-item field="parent_id" label="上级部门">
<a-tree-select
:disabled="(modalForm.dept_id || modalForm.dept_id==0)?true:false"
:disabled="(modalForm.parent_id && modalForm.parent_id==0)?true:false"
v-model="modalForm.parent_id"
:data="tableData"
:field-names="{ key: 'dept_id', title: 'dept_name' }"
@ -185,9 +185,10 @@ const handleUpdate = async (record) => {
modalVisible.value = true;
modalTitle.value = '修改部门信息';
await nextTick();
//await nextTick();
const { parent_id, dept_name, leader, phone, email, dept_status, dept_id } = record;
Object.assign(modalForm, {
Object.assign(modalForm,{
parent_id,
dept_name,
leader,