Showing
1 changed file
with
4 additions
and
3 deletions
... | ... | @@ -134,11 +134,10 @@ |
134 | 134 | const getTitle = computed(() => (!unref(isUpdate) ? '新增角色' : '编辑角色')); |
135 | 135 | |
136 | 136 | async function handleSubmit() { |
137 | + setDrawerProps({ confirmLoading: true }); | |
137 | 138 | const { createMessage } = useMessage(); |
138 | - | |
139 | 139 | try { |
140 | 140 | const values = await validate(); |
141 | - setDrawerProps({ confirmLoading: true }); | |
142 | 141 | const req = { |
143 | 142 | id: roleId.value, |
144 | 143 | name: values.name, |
... | ... | @@ -155,7 +154,9 @@ |
155 | 154 | }); |
156 | 155 | } catch { |
157 | 156 | } finally { |
158 | - setDrawerProps({ confirmLoading: false }); | |
157 | + setTimeout(() => { | |
158 | + setDrawerProps({ confirmLoading: false }); | |
159 | + }, 300); | |
159 | 160 | } |
160 | 161 | } |
161 | 162 | // Tree check事件 | ... | ... |