Commit 9dcf0218cd7e9a419683e6d34e06a6d65ecfcc2d
1 parent
6360d432
fix: error
Showing
2 changed files
with
3 additions
and
6 deletions
yudao-ui-admin-vue3/src/views/system/role/role.data.ts
yudao-ui-admin-vue3/src/views/system/user/index.vue
| ... | ... | @@ -351,16 +351,17 @@ const setDialogTile = async (type: string) => { |
| 351 | 351 | |
| 352 | 352 | // 新增操作 |
| 353 | 353 | const handleCreate = async () => { |
| 354 | + actionType.value = 'create' | |
| 354 | 355 | // 重置表单 |
| 355 | 356 | deptId.value = null |
| 356 | 357 | postIds.value = [] |
| 357 | 358 | dialogVisible.value = true |
| 358 | 359 | dialogTitle.value = t('action.create') |
| 359 | - actionType.value = 'create' | |
| 360 | 360 | } |
| 361 | 361 | |
| 362 | 362 | // 修改操作 |
| 363 | 363 | const handleUpdate = async (rowId: number) => { |
| 364 | + setDialogTile('update') | |
| 364 | 365 | unref(formRef)?.delSchema('username') |
| 365 | 366 | unref(formRef)?.delSchema('password') |
| 366 | 367 | // 设置数据 |
| ... | ... | @@ -368,7 +369,6 @@ const handleUpdate = async (rowId: number) => { |
| 368 | 369 | deptId.value = res.deptId |
| 369 | 370 | postIds.value = res.postIds |
| 370 | 371 | unref(formRef)?.setValues(res) |
| 371 | - setDialogTile('update') | |
| 372 | 372 | } |
| 373 | 373 | const detailData = ref() |
| 374 | 374 | ... | ... |