Skip to content

Commit 101c704

Browse files
author
puhui999
committed
【功能完善】商城: 会员信息的优化
1 parent d228df5 commit 101c704

File tree

2 files changed

+41
-3
lines changed

2 files changed

+41
-3
lines changed

src/views/member/user/detail/UserAccountInfo.vue

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<el-descriptions :column="column">
2+
<el-descriptions :class="{ 'kefu-descriptions': column === 1 }" :column="column">
33
<el-descriptions-item>
44
<template #label>
55
<descriptions-item-label icon="svg-icon:member_level" label=" 等级 " />
@@ -62,4 +62,23 @@ withDefaults(defineProps<{ user: UserApi.UserVO; wallet: WalletApi.WalletVO; col
6262
.cell-item::after {
6363
content: ':';
6464
}
65+
66+
.kefu-descriptions {
67+
::v-deep(.el-descriptions__cell) {
68+
display: flex;
69+
align-items: center;
70+
justify-content: space-between;
71+
72+
.el-descriptions__label {
73+
width: 120px;
74+
display: block;
75+
text-align: left;
76+
}
77+
78+
.el-descriptions__content {
79+
flex: 1;
80+
text-align: end;
81+
}
82+
}
83+
}
6584
</style>

src/views/member/user/detail/UserBasicInfo.vue

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
</el-row>
6969
<template v-if="mode === 'kefu'">
7070
<ElAvatar :size="140" :src="user.avatar || undefined" shape="square" />
71-
<el-descriptions :column="1">
71+
<el-descriptions :column="1" class="kefu-descriptions">
7272
<el-descriptions-item>
7373
<template #label>
7474
<descriptions-item-label icon="ep:user" label="用户名" />
@@ -81,7 +81,7 @@
8181
</template>
8282
{{ user.nickname }}
8383
</el-descriptions-item>
84-
<el-descriptions-item label="手机号">
84+
<el-descriptions-item>
8585
<template #label>
8686
<descriptions-item-label icon="ep:phone" label="手机号" />
8787
</template>
@@ -143,4 +143,23 @@ withDefaults(defineProps<{ user: UserApi.UserVO; mode?: string }>(), {
143143
justify-content: space-between;
144144
align-items: center;
145145
}
146+
147+
::v-deep(.kefu-descriptions) {
148+
.el-descriptions__cell {
149+
display: flex;
150+
align-items: center;
151+
justify-content: space-between;
152+
153+
.el-descriptions__label {
154+
width: 120px;
155+
display: block;
156+
text-align: left;
157+
}
158+
159+
.el-descriptions__content {
160+
flex: 1;
161+
text-align: end;
162+
}
163+
}
164+
}
146165
</style>

0 commit comments

Comments
 (0)