From fa3acb21b06bec979ab485da1e350811a8fef1f3 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sun, 24 Sep 2023 12:10:03 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20member=20=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E6=97=A0=E6=B3=95=E5=B1=95=E7=A4=BA=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit 539f8a5bb5a63da15fe13be582ce23ee44b56ce3) --- src/views/member/user/detail/index.vue | 2 +- src/views/member/user/index.vue | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/views/member/user/detail/index.vue b/src/views/member/user/detail/index.vue index 7b943494..7b388d75 100644 --- a/src/views/member/user/detail/index.vue +++ b/src/views/member/user/detail/index.vue @@ -74,7 +74,7 @@ defineOptions({ name: 'MemberDetail' }) const activeName = ref('point') // 账户明细 选中的 tabs const loading = ref(true) // 加载中 -const user = ref() +const user = ref({}) /** 添加/修改操作 */ const formRef = ref() diff --git a/src/views/member/user/index.vue b/src/views/member/user/index.vue index 066d5f79..0a45f17c 100644 --- a/src/views/member/user/index.vue +++ b/src/views/member/user/index.vue @@ -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)