chore: 默认的清理函数
This commit is contained in:
parent
e13690379c
commit
3edad0459d
@ -27,7 +27,9 @@ const formOptions: VbenFormProps = {
|
|||||||
handleReset: async () => {
|
handleReset: async () => {
|
||||||
selectDeptId.value = [];
|
selectDeptId.value = [];
|
||||||
// eslint-disable-next-line no-use-before-define
|
// eslint-disable-next-line no-use-before-define
|
||||||
await tableApi.query();
|
const { formApi, reload } = tableApi;
|
||||||
|
await formApi.resetForm();
|
||||||
|
await reload();
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -138,7 +140,7 @@ function handleMultiDelete() {
|
|||||||
<Page :auto-content-height="true" content-class="flex gap-[8px]">
|
<Page :auto-content-height="true" content-class="flex gap-[8px]">
|
||||||
<DeptTree
|
<DeptTree
|
||||||
v-model:select-dept-id="selectDeptId"
|
v-model:select-dept-id="selectDeptId"
|
||||||
:height="300"
|
:height="360"
|
||||||
class="w-[260px]"
|
class="w-[260px]"
|
||||||
@select="() => tableApi.query()"
|
@select="() => tableApi.query()"
|
||||||
/>
|
/>
|
||||||
|
@ -64,7 +64,9 @@ const formOptions: VbenFormProps = {
|
|||||||
handleReset: async () => {
|
handleReset: async () => {
|
||||||
selectDeptId.value = [];
|
selectDeptId.value = [];
|
||||||
// eslint-disable-next-line no-use-before-define
|
// eslint-disable-next-line no-use-before-define
|
||||||
await tableApi.query();
|
const { formApi, reload } = tableApi;
|
||||||
|
await formApi.resetForm();
|
||||||
|
await reload();
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -194,7 +196,7 @@ function handleResetPwd(record: Recordable<any>) {
|
|||||||
<div class="flex h-full gap-[8px]">
|
<div class="flex h-full gap-[8px]">
|
||||||
<DeptTree
|
<DeptTree
|
||||||
v-model:select-dept-id="selectDeptId"
|
v-model:select-dept-id="selectDeptId"
|
||||||
:height="300"
|
:height="360"
|
||||||
class="w-[260px]"
|
class="w-[260px]"
|
||||||
@select="() => tableApi.query()"
|
@select="() => tableApi.query()"
|
||||||
/>
|
/>
|
||||||
|
Loading…
Reference in New Issue
Block a user