优化城市、配置
This commit is contained in:
parent
a34bcc4156
commit
dd3ad431e0
@ -139,10 +139,12 @@
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 定义参数
|
||||||
|
*/
|
||||||
const message = useMessage();
|
const message = useMessage();
|
||||||
const dialog = useDialog();
|
const dialog = useDialog();
|
||||||
const fwbHeight = document.body.clientHeight - 350;
|
|
||||||
const loading = ref(false);
|
|
||||||
const createModalRef = ref();
|
const createModalRef = ref();
|
||||||
const editVisible = ref(false);
|
const editVisible = ref(false);
|
||||||
const showTable = ref(true);
|
const showTable = ref(true);
|
||||||
@ -164,6 +166,7 @@
|
|||||||
});
|
});
|
||||||
lists.value = data;
|
lists.value = data;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 刷新数据列表
|
* 刷新数据列表
|
||||||
*/
|
*/
|
||||||
@ -178,41 +181,6 @@
|
|||||||
|
|
||||||
showTable.value = true;
|
showTable.value = true;
|
||||||
};
|
};
|
||||||
const actionColumn = reactive({
|
|
||||||
width: 220,
|
|
||||||
title: '操作',
|
|
||||||
align: 'center',
|
|
||||||
key: 'action',
|
|
||||||
fixed: 'right',
|
|
||||||
render(record) {
|
|
||||||
return h(TableAction as any, {
|
|
||||||
style: 'button',
|
|
||||||
actions: [
|
|
||||||
{
|
|
||||||
label: '新增',
|
|
||||||
type: 'info',
|
|
||||||
icon: renderIcon(PlusOutlined),
|
|
||||||
auth: ['sys:city:add'],
|
|
||||||
onclick: handleAdd.bind(null, record),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '编辑',
|
|
||||||
type: 'warning',
|
|
||||||
icon: renderIcon(FormOutlined),
|
|
||||||
auth: ['sys:city:update'],
|
|
||||||
onclick: handleEdit.bind(null, record),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: '删除',
|
|
||||||
type: 'error',
|
|
||||||
icon: renderIcon(DeleteOutlined),
|
|
||||||
auth: ['sys:city:delete'],
|
|
||||||
onclick: handleDelete.bind(null, record),
|
|
||||||
},
|
|
||||||
],
|
|
||||||
});
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 执行添加
|
* 执行添加
|
||||||
@ -266,6 +234,10 @@
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取子级数据
|
||||||
|
* @param row 参数
|
||||||
|
*/
|
||||||
const getChild = async (row: Record<string, unknown>) => {
|
const getChild = async (row: Record<string, unknown>) => {
|
||||||
expandKeys.value.push(row.areaCode);
|
expandKeys.value.push(row.areaCode);
|
||||||
return new Promise<void>(async (resolve) => {
|
return new Promise<void>(async (resolve) => {
|
||||||
|
@ -9,17 +9,22 @@ export const columns = [
|
|||||||
{
|
{
|
||||||
title: 'ID',
|
title: 'ID',
|
||||||
key: 'id',
|
key: 'id',
|
||||||
|
fixed: 'left',
|
||||||
|
width: 50,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '配置名称',
|
title: '配置名称',
|
||||||
key: 'name',
|
key: 'name',
|
||||||
|
width: 100,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '配置编码',
|
title: '配置编码',
|
||||||
key: 'code',
|
key: 'code',
|
||||||
|
width: 100,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '排序',
|
title: '排序',
|
||||||
key: 'sort',
|
key: 'sort',
|
||||||
|
width: 100,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
Loading…
Reference in New Issue
Block a user