修复 member 详情无法展示的问题

This commit is contained in:
YunaiV 2023-09-24 12:10:03 +08:00
parent e489627748
commit 539f8a5bb5
2 changed files with 8 additions and 1 deletions

View File

@ -75,7 +75,7 @@ defineOptions({ name: 'MemberDetail' })
const activeName = ref('point') // tabs
const loading = ref(true) //
const user = ref<UserApi.UserVO>()
const user = ref<UserApi.UserVO>({})
/** 添加/修改操作 */
const formRef = ref()

View File

@ -160,6 +160,7 @@
import { dateFormatter } from '@/utils/formatTime'
import * as UserApi from '@/api/member/user'
import { DICT_TYPE } from '@/utils/dict'
import UserForm from './UserForm.vue'
import MemberTagSelect from '@/views/member/tag/components/MemberTagSelect.vue'
import MemberLevelSelect from '@/views/member/level/components/MemberLevelSelect.vue'
import MemberGroupSelect from '@/views/member/group/components/MemberGroupSelect.vue'
@ -218,6 +219,12 @@ const openDetail = (id: number) => {
push({ name: 'MemberUserDetail', params: { id } })
}
/** 添加/修改操作 */
const formRef = ref()
const openForm = (type: string, id?: number) => {
formRef.value.open(type, id)
}
/** 表格选中事件 */
const handleSelectionChange = (rows: UserApi.UserVO[]) => {
selectedIds.value = rows.map((row) => row.id)