Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jz_Travel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
zhengke
jz_Travel
Commits
a029b961
Commit
a029b961
authored
Jun 03, 2021
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
4a08ee85
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
220 additions
and
220 deletions
+220
-220
style7.vue
components/goods/style7.vue
+220
-220
No files found.
components/goods/style7.vue
View file @
a029b961
<
template
>
<view
style=
"padding:0 15px;width:100%;"
:style=
"
{
<view
style=
"padding:0 15px;width:100%;"
:style=
"
{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
}"
>
<view
class=
"good-seven"
v-for=
"(item, gli) in goodList"
:key=
"gli"
@
click=
"openGood(item)"
:style=
"
{
}">
<view
class=
"good-seven"
v-for=
"(item, gli) in goodList"
:key=
"gli"
@
click=
"openGood(item)"
:style=
"
{
border: goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background: goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : ''
}"
>
<view
class=
"tips"
v-if=
"goodsInfo.showGoodsTag"
><image
:src=
"goodsInfo.goodsTagPicUrl"
mode=
"widthFix"
style=
"width: 100%;"
/></view>
}">
<view
class=
"tips"
v-if=
"goodsInfo.showGoodsTag"
>
<image
:src=
"goodsInfo.goodsTagPicUrl"
mode=
"widthFix"
style=
"width: 100%;"
/>
</view>
<view
class=
"img-box"
>
<template
v-if=
"item.imglist&&item.imglist.length==1"
>
<image
class=
"img-0"
:mode=
"goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src=
"item.imglist[0]"
/>
...
...
@@ -40,14 +33,8 @@
<view
class=
"sencond-title"
v-if=
"item.subname"
>
{{item.subname}}
</view>
<view
class=
"good-price-info"
>
<view>
<u-rate
:current=
"item.courseScore!=null &&item.courseScore>0?item.courseScore:'5'"
:active-color=
"mainColor"
inactive-color=
"#DDDDDD"
active-icon=
"star"
inactive-icon=
"star-o"
size=
"34"
:disabled=
"true"
></u-rate>
<u-rate
:current=
"item.courseScore!=null &&item.courseScore>0?item.courseScore:'5'"
:active-color=
"mainColor"
inactive-color=
"#DDDDDD"
active-icon=
"star"
inactive-icon=
"star-o"
size=
"34"
:disabled=
"true"
></u-rate>
<text
class=
"good-rb-text"
>
{{item.courseScore!=null
&&
item.courseScore>0?item.courseScore.toFixed(1):'5.0'}}分
</text>
</view>
<view
class=
"price"
:style=
"{ color: mainColor }"
v-if=
"item.price>0 && goodsInfo.showGoodsPrice"
>
{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }}
...
...
@@ -57,18 +44,11 @@
<view
class=
"buy"
v-if=
"goodsInfo.showBuyBtn"
@
click
.
stop=
"showSkuHandler(item)"
>
<u-icon
name=
"cart-o"
size=
"40"
:color=
"mainColor"
v-if=
"goodsInfo.buyBtn == 'cart'"
/>
<u-icon
name=
"add-o"
size=
"40"
:color=
"mainColor"
v-else-if=
"goodsInfo.buyBtn == 'add'"
/>
<u-button
type=
"primary"
size=
"mini"
:ripple=
"true"
:color=
"goodsInfo.buttonColor"
:custom-style=
"
<u-button
type=
"primary"
size=
"mini"
:ripple=
"true"
:color=
"goodsInfo.buttonColor"
:custom-style=
"
`backgroundColor:${goodsInfo.buttonColor},color:${goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4 ? goodsInfo.buttonColor : '#FFF'}`
"
:plain=
"goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4"
:shape=
"goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4 ? 'circle' : 'square'"
v-else
>
:plain=
"goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4"
:shape=
"goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4 ? 'circle' : 'square'"
v-else
>
{{ goodsInfo.buyBtnText }}
</u-button>
</view>
...
...
@@ -81,9 +61,9 @@
</template>
<
script
>
import
goodSku
from
'../goods/goodsku'
;
import
auth
from
'@/components/auth/index.vue'
;
export
default
{
import
goodSku
from
'../goods/goodsku'
;
import
auth
from
'@/components/auth/index.vue'
;
export
default
{
components
:
{
goodSku
,
auth
...
...
@@ -97,14 +77,15 @@ export default {
sku
:
{},
showAuth
:
false
,
u
:
{},
IsEducation
:
1
IsEducation
:
1
};
},
created
()
{
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
this
.
IsEducation
=
uni
.
getStorageSync
(
'basedata'
)
?
(
uni
.
getStorageSync
(
'basedata'
).
mall
.
setting
.
mallStyle
.
IsEducation
?
uni
.
getStorageSync
(
'basedata'
).
mall
.
setting
.
mallStyle
.
IsEducation
:
0
)
:
0
;
this
.
IsEducation
=
uni
.
getStorageSync
(
'basedata'
)
?
(
uni
.
getStorageSync
(
'basedata'
).
mall
.
setting
.
mallStyle
.
IsEducation
?
uni
.
getStorageSync
(
'basedata'
).
mall
.
setting
.
mallStyle
.
IsEducation
:
0
)
:
0
;
},
methods
:
{
openGood
(
item
)
{
...
...
@@ -155,11 +136,11 @@ export default {
this
.
showAuth
=
false
;
}
}
};
};
</
script
>
<
style
>
.good-seven
{
.good-seven
{
position
:
relative
;
margin-bottom
:
14px
;
display
:
flex
;
...
...
@@ -171,39 +152,44 @@ export default {
overflow
:
hidden
;
padding-bottom
:
14px
;
border-bottom
:
1px
solid
#e2e2e2
;
}
.good-seven
:last-child
{
}
.good-seven
:last-child
{
padding-bottom
:
0
;
border-bottom
:
none
;
}
.good-seven
.tips
{
}
.good-seven
.tips
{
width
:
64
rpx
;
height
:
64
rpx
;
position
:
absolute
;
top
:
0
;
left
:
0
;
z-index
:
4
;
}
.good-seven
.img-box
{
}
.good-seven
.img-box
{
width
:
266
rpx
;
height
:
260
rpx
;
overflow
:
hidden
;
position
:
relative
;
border-radius
:
20
rpx
;
}
.good-seven
.img-box
.img-0
{
border-radius
:
20
rpx
;
}
.good-seven
.img-box
.img-0
{
width
:
200
rpx
;
border-radius
:
20
rpx
;
border-radius
:
20
rpx
;
overflow
:
hidden
;
position
:
absolute
;
left
:
0
;
top
:
0
;
height
:
260
rpx
;
z-index
:
3
;
}
.good-seven
.img-box
.img-1
{
}
.good-seven
.img-box
.img-1
{
width
:
200
rpx
;
border-radius
:
20
rpx
;
border-radius
:
20
rpx
;
overflow
:
hidden
;
position
:
absolute
;
left
:
40
rpx
;
...
...
@@ -211,10 +197,11 @@ export default {
height
:
220
rpx
;
opacity
:
0.6
;
z-index
:
2
;
}
.good-seven
.img-box
.img-2
{
}
.good-seven
.img-box
.img-2
{
width
:
200
rpx
;
border-radius
:
20
rpx
;
border-radius
:
20
rpx
;
overflow
:
hidden
;
position
:
absolute
;
left
:
66
rpx
;
...
...
@@ -222,8 +209,9 @@ export default {
height
:
180
rpx
;
opacity
:
0.3
;
z-index
:
1
;
}
.good-seven
.good-info
{
}
.good-seven
.good-info
{
padding-left
:
12px
;
flex
:
1
;
width
:
1
rpx
;
...
...
@@ -232,8 +220,9 @@ export default {
display
:
flex
;
flex-direction
:
column
;
/* width:20%; */
}
.good-seven
.good-info
.good-name
{
}
.good-seven
.good-info
.good-name
{
font-size
:
30
rpx
;
max-height
:
80
rpx
;
overflow
:
hidden
;
...
...
@@ -242,8 +231,9 @@ export default {
-webkit-line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
color
:
#111
;
}
.good-seven
.good-info
.good-price-info
{
}
.good-seven
.good-info
.good-price-info
{
display
:
flex
;
justify-items
:
center
;
justify-content
:
space-between
;
...
...
@@ -251,29 +241,39 @@ export default {
height
:
10px
;
flex
:
1
;
padding-bottom
:
10
rpx
;
}
.good-seven
.good-info
.sencond-title
{
}
.good-seven
.good-info
.sencond-title
{
font-size
:
24
rpx
;
font-weight
:
500
;
color
:
#999999
;
line-height
:
32
rpx
;
margin-top
:
5px
;
}
.good-seven
.good-rb-text
{
text-overflow
:
-o-ellipsis-lastline
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
3
;
line-clamp
:
3
;
-webkit-box-orient
:
vertical
;
}
.good-seven
.good-rb-text
{
font-size
:
32
rpx
;
color
:
#999999
;
margin-left
:
2px
;
}
}
.good-seven
.good-info
.good-price-info
.price
{
.good-seven
.good-info
.good-price-info
.price
{
color
:
#ff4544
;
font-size
:
14px
;
white-space
:
nowrap
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
.good-seven
.good-info
.good-price-info
.buy
{
}
.good-seven
.good-info
.good-price-info
.buy
{
width
:
24px
;
text-align
:
right
;
}
}
</
style
>
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