diff --git a/hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue b/hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue
index 4918d21..9694769 100644
--- a/hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue
+++ b/hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue
@@ -168,10 +168,12 @@
const addApartment = () => {
disabled.value = false;
+ opMap.type = 'add';
};
const addApartmentSon = () => {
disabled.value = false;
+ opMap.type = 'addson';
};
const addUser = () => {
@@ -240,11 +242,16 @@
const ApartmentSure = () => {
disabled.value = !disabled.value;
opMap.fuc && opMap.fuc(formData.value);
- console.log(formData.value.name, 'formData');
- apartmentTreeData.value[0].children.push({
- title: formData.value.name,
- key: 'a1',
- });
+ // console.log(formData.value.name, 'formData');
+ console.log(opMap.type, 'opMap.type');
+ if (opMap.type === 'add') {
+ apartmentTreeData.value[0].children.push({
+ title: formData.value.name,
+ key: 'a1',
+ });
+ } else {
+ console.log('ss');
+ }
};
const UserSure = () => {
disabled2.value = !disabled2.value;
diff --git a/hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue b/hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue
index aedd860..e52c0ae 100644
--- a/hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue
+++ b/hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue
@@ -63,7 +63,7 @@
cancelText="取消"
@ok="handleOk"
@cancel="handleClose">
-
+
@@ -106,7 +106,7 @@
]);
const mockData2 = ref([
{
- information: '1',
+ information: '铁路局1/产品部1/产品总监1',
},
]);
@@ -152,12 +152,18 @@
};
const onEdit = () => {
+ console.log(formData.value, 'formData.value');
opMap.fuc && opMap.fuc(formData.value);
visible.value = false;
};
const handleOk = () => {
- // opMap.fuc && opMap.fuc(formData2.value);
+ console.log(formData2.value, 'formData2.value');
+ console.log(opMap.type, 'type');
+ if (opMap.type === 'add') {
+ mockData2.value.push({ information: casData.value.join('/') });
+ } else {
+ }
addformvisible.value = false;
};
const handleClose = () => {
@@ -207,12 +213,14 @@
label: '批量删除',
type: 'primary',
name: 'RoleTypeAdd',
- handle: () => {},
dynamicDisabled: (data: any) => {
return data.list.length === 0;
},
confirm: true,
isReload: true,
+ handle: (data: any) => {
+ console.log(data.list);
+ },
},
],
params: {
@@ -310,9 +318,7 @@
// .then((res) => {
// mainRef.value.nsTableRef.reload();
// });
- return new Promise((resolve, reject) => {
- NsMessage.success('冻结成功');
- }).catch(() => console.log('Oops errors!'));
+ NsMessage.success('冻结成功');
},
class: 'test',
});
@@ -347,7 +353,7 @@
uuid: 'uuid',
},
confirm: true,
- handle: (record: any, name, reload) => {
+ handle: (record: any, name: any, reload: any) => {
console.log(record, name, reload, 'record');
mockData.value.splice(0, 1);
},
@@ -466,7 +472,7 @@
label: '删除',
name: 'RoleTypeEdit',
confirm: true,
- handle: (record: any, name, reload) => {
+ handle: (record: any, name: any, reload: any) => {
console.log(record, name, reload, 'record');
mockData2.value.splice(0, 1);
},
@@ -493,6 +499,7 @@
],
},
};
+ const casData = ref([]);
const formSchema = reactive([
{
@@ -591,18 +598,22 @@
component: 'NsCascader',
componentProps: {
placeholder: '请选择',
+ displayRender: ({ labels }: any) => {
+ casData.value = labels;
+ return labels.join('/');
+ },
options: [
{
- value: 'zhejiang',
+ value: '1',
label: '铁路局',
children: [
{
- value: 'hangzhou',
- label: '铁路局1',
+ value: '2',
+ label: '产品部',
children: [
{
- value: 'xihu',
- label: '铁路局2',
+ value: '3',
+ label: '产品总监',
},
],
},