|
|
@@ -8,8 +8,9 @@
|
|
|
>
|
|
|
<el-form label-width="auto" :model="formData" ref="ruleFormRef" :rules="rules">
|
|
|
<el-form-item label="下发部门名称" prop="deptId">
|
|
|
+ <!-- :disabled="currentDepartmentKey === 'A'" -->
|
|
|
+
|
|
|
<el-cascader
|
|
|
- :disabled="currentDepartmentKey === 'A'"
|
|
|
ref="cascaderRef"
|
|
|
style="width: 100%"
|
|
|
size="large"
|
|
|
@@ -247,7 +248,6 @@
|
|
|
label: 'deptName',
|
|
|
multiple: !/A|B/.test(props.currentDepartmentKey),
|
|
|
disabled: (data, node) => {
|
|
|
- // node.pathValues 是当前节点的完整路径数组,例如 ['zhinan', 'sheji']
|
|
|
return originDeptId.value.some((path) => isEqual(path, node.pathValues));
|
|
|
},
|
|
|
};
|
|
|
@@ -257,10 +257,11 @@
|
|
|
([currentDepartmentKey, departmentOptions]) => {
|
|
|
if (!currentDepartmentKey) return;
|
|
|
// 针对院领导的特殊处理
|
|
|
- if (currentDepartmentKey === 'A' && Array.isArray(departmentOptions) && departmentOptions.length) {
|
|
|
- const id = departmentOptions.find((d) => d.deptName === '院领导')?.id;
|
|
|
- formData.deptId = [id];
|
|
|
- }
|
|
|
+ // if (currentDepartmentKey === 'A' && Array.isArray(departmentOptions) && departmentOptions.length) {
|
|
|
+ // const id = departmentOptions.find((d) => d.deptName === '院领导')?.id;
|
|
|
+ // formData.deptId = [id];
|
|
|
+ // }
|
|
|
+ console.log('departmentOptions:', departmentOptions);
|
|
|
formData.leader1 = null;
|
|
|
formData.leader2 = null;
|
|
|
formData.signPerson = [];
|