diff --git a/src/views/govern/setting/statisticalType/binding.vue b/src/views/govern/setting/statisticalType/binding.vue index 50a7635..986b800 100644 --- a/src/views/govern/setting/statisticalType/binding.vue +++ b/src/views/govern/setting/statisticalType/binding.vue @@ -1,45 +1,22 @@ - + 向左
- - + + @@ -110,6 +77,7 @@ import { ref, inject } from 'vue' import { CascaderValue, ElMessage } from 'element-plus' import { addStatistical, queryStatistical } from '@/api/system-boot/csstatisticalset' +import { getDictTreeById } from '@/api/system-boot/dictTree' import PopupAdd from './add.vue' import { dicDelete } from '@/api/system-boot/dic' import List from '@/views/pms/comptroller/list.vue' @@ -368,6 +336,8 @@ const dicDeleteGroup = (data: any) => { } const newGroup = () => { + console.log("🚀 ~ newGroup ~ toData.value.length:", toData.value[toData.value.length - 1].sort + 1) + addRef.value.open('新增菜单', { sort: toData.value.length ? toData.value[toData.value.length - 1].sort + 1 : 1, code: '', @@ -377,6 +347,19 @@ const newGroup = () => { name: '' }) } +const editGroup = (data: any) => { + getDictTreeById(data.id).then(res => { + addRef.value.open('修改菜单', { + sort: res.data.sort || 100, + code: res.data.code || '', + pid: res.data.pid || '', + id: res.data.id || '', + remark: res.data.remark || '', + name: res.data.name || '' + }) + }) + +} const open = (id: string) => { dialogVisible.value = true