Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
group-buy-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
group-buy-ui
Commits
17127c7a
Commit
17127c7a
authored
Oct 10, 2021
by
Xuguangxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 处理头像问题
parent
8e30f018
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
24 deletions
+16
-24
avatorGroup.vue
src/components/avatorGroup.vue
+9
-23
groupDescInfo.vue
src/views/goodsDetail/components/groupDescInfo.vue
+7
-1
No files found.
src/components/avatorGroup.vue
View file @
17127c7a
<
template
>
<
template
>
<div
class=
"avator-group"
>
<div
class=
"avator-group"
>
<div
<div
v-for=
"(item, index) in avators.slice(0, 9)"
:key=
"index"
class=
"avator-item"
>
v-for=
"(item, index) in avators.slice(0, 9)"
:key=
"index"
class=
"avator-item"
:style=
"widthStyle"
>
<cr-image
<cr-image
class=
"avator-img"
class=
"avator-img"
:class=
"
{ avator: index == 0 }"
:class=
"
{ avator: index == 0 }"
...
@@ -36,7 +31,6 @@
...
@@ -36,7 +31,6 @@
:key=
"`placeholder-${n}`"
:key=
"`placeholder-${n}`"
class=
"placeholder"
class=
"placeholder"
:class=
"{ leader: avators.length == 0 }"
:class=
"{ leader: avators.length == 0 }"
:style=
"widthStyle"
>
>
<
template
v-if=
"avators.length == 0 && n == 1"
>
<
template
v-if=
"avators.length == 0 && n == 1"
>
<div
class=
"is-leader"
>
<div
class=
"is-leader"
>
...
@@ -54,7 +48,7 @@
...
@@ -54,7 +48,7 @@
</
template
>
</
template
>
<div
class=
"content"
:class=
"{ avator: avators.length == 0 && n == 1 }"
>
?
</div>
<div
class=
"content"
:class=
"{ avator: avators.length == 0 && n == 1 }"
>
?
</div>
</div>
</div>
<div
v-if=
"groupHC >= 10"
class=
"more"
:style=
"widthStyle"
@
click=
"showMoreAvator"
>
<div
v-if=
"groupHC >= 10"
class=
"more"
@
click=
"showMoreAvator"
>
<div
class=
"content"
/>
<div
class=
"content"
/>
</div>
</div>
<
template
v-if=
"showDialogSlot"
>
<
template
v-if=
"showDialogSlot"
>
...
@@ -71,12 +65,7 @@
...
@@ -71,12 +65,7 @@
justify-content: center;
justify-content: center;
"
"
>
>
<div
<div
v-for=
"(item, index) in avators"
:key=
"index"
class=
"avator-item"
>
v-for=
"(item, index) in avators"
:key=
"index"
class=
"avator-item"
:style=
"widthStyle"
>
<cr-image
<cr-image
:key=
"index"
:key=
"index"
:class=
"
{ avator: index == 0 }"
:class=
"
{ avator: index == 0 }"
...
@@ -99,6 +88,7 @@
...
@@ -99,6 +88,7 @@
src=
"@/assets/images/leader-name.png"
src=
"@/assets/images/leader-name.png"
/>
/>
</div>
</div>
<div
class=
"border"
/>
</div>
</div>
</div>
</div>
</cr-dialog>
</cr-dialog>
...
@@ -132,10 +122,6 @@ export default {
...
@@ -132,10 +122,6 @@ export default {
}
else
{
}
else
{
return
this
.
groupHC
-
this
.
avators
.
length
<
0
?
0
:
this
.
groupHC
-
this
.
avators
.
length
;
return
this
.
groupHC
-
this
.
avators
.
length
<
0
?
0
:
this
.
groupHC
-
this
.
avators
.
length
;
}
}
},
widthStyle
()
{
// 用于单个头像不能占一排
return
this
.
avators
.
length
==
6
?
{
width
:
'
25%
'
}
:
{
width
:
'
20%
'
};
}
}
},
},
created
()
{
created
()
{
...
@@ -168,14 +154,14 @@ export default {
...
@@ -168,14 +154,14 @@ export default {
}
}
.border {
.border {
position: absolute;
position: absolute;
top:
0
;
top:
-1px
;
left: 50%;
left: 50%;
transform: translateX(-50%);
transform: translateX(-50%);
background: url('../assets/images/leaderBorder.png');
background: url('../assets/images/leaderBorder.png');
background-size: cover;
background-size: cover;
z-index: 2;
z-index: 2;
width: 4
4
px;
width: 4
8
px;
height:
100%
;
height:
48px
;
}
}
.avator {
.avator {
// background: url('../assets/images/leaderBorder.png');
// background: url('../assets/images/leaderBorder.png');
...
@@ -201,8 +187,8 @@ export default {
...
@@ -201,8 +187,8 @@ export default {
}
}
.is-leader {
.is-leader {
position: absolute;
position: absolute;
right:
4
px;
right:
0
px;
top: -
9
px;
top: -
10
px;
z-index: 3;
z-index: 3;
.crown {
.crown {
width: 22px;
width: 22px;
...
...
src/views/goodsDetail/components/groupDescInfo.vue
View file @
17127c7a
...
@@ -32,7 +32,13 @@
...
@@ -32,7 +32,13 @@
</
template
>
</
template
>
</template>
</template>
</div>
</div>
<div
v-if=
"groupInfo.groupBuyStatus == 1 || groupInfo.groupBuyStatus == 0"
class=
"gourp-rules"
>
<div
v-if=
"
(groupInfo.groupBuyStatus == 1 || groupInfo.groupBuyStatus == 0) &&
groupInfo.groupBuyNeedNewUserCount
"
class=
"gourp-rules"
>
<p>
成团条件:{{ groupInfo.groupBuyCondition || '' }}
</p>
<p>
成团条件:{{ groupInfo.groupBuyCondition || '' }}
</p>
<cr-image
src=
"@/assets/images/flag.png"
width=
"13px"
/>
<cr-image
src=
"@/assets/images/flag.png"
width=
"13px"
/>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment