Showing
1 changed file
with
4 additions
and
2 deletions
| ... | ... | @@ -132,10 +132,10 @@ |
| 132 | 132 | const getTitle = computed(() => (!unref(isUpdate) ? '新增角色' : '编辑角色')); |
| 133 | 133 | |
| 134 | 134 | async function handleSubmit() { |
| 135 | + setDrawerProps({ confirmLoading: true }); | |
| 135 | 136 | const { createMessage } = useMessage(); |
| 136 | 137 | try { |
| 137 | 138 | const values = await validate(); |
| 138 | - setDrawerProps({ confirmLoading: true }); | |
| 139 | 139 | const req = { |
| 140 | 140 | id: roleId.value, |
| 141 | 141 | name: values.name, |
| ... | ... | @@ -150,7 +150,9 @@ |
| 150 | 150 | createMessage.success(`${unref(isUpdate) ? '编辑' : '新增'}成功`); |
| 151 | 151 | }); |
| 152 | 152 | } finally { |
| 153 | - setDrawerProps({ confirmLoading: false }); | |
| 153 | + setTimeout(() => { | |
| 154 | + setModalProps({ confirmLoading: false }); | |
| 155 | + }, 300); | |
| 154 | 156 | } |
| 155 | 157 | } |
| 156 | 158 | // Tree check事件 | ... | ... |