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
153c9228
Commit
153c9228
authored
May 31, 2021
by
zhengke
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.oytour.com/zk123/jz_travel
parents
b4b8bdb9
b98a32fa
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
172 additions
and
162 deletions
+172
-162
style1.vue
components/goods/style1.vue
+2
-1
style2.vue
components/goods/style2.vue
+1
-1
style3.vue
components/goods/style3.vue
+1
-1
style4.vue
components/goods/style4.vue
+1
-1
style5.vue
components/goods/style5.vue
+1
-1
style6.vue
components/goods/style6.vue
+165
-156
style7.vue
components/goods/style7.vue
+1
-1
No files found.
components/goods/style1.vue
View file @
153c9228
...
...
@@ -35,9 +35,10 @@
/>
<div
class=
"good-info"
>
<div
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</div>
<view
class=
"good-sub-name"
>
{{
item
.
subname
}}
</view>
<div
class=
"good-price-info"
>
<span
class=
"price"
:style=
"
{ color: mainColor }">
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
price
)
:
''
}}
<
span
style=
'text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'
>
原价:
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
OriginalPrice
)
:
''
}}
</span
>
<
!--
<span
style=
'text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'
>
原价:
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
OriginalPrice
)
:
''
}}
</span>
--
>
</span>
<span
class=
"buy"
v-if=
"goodsInfo.showBuyBtn"
@
click
.
stop=
"showSkuHandler(item)"
>
<u-icon
name=
"cart-o"
size=
"40"
:color=
"mainColor"
v-if=
"goodsInfo.buyBtn == 'cart'"
/>
...
...
components/goods/style2.vue
View file @
153c9228
...
...
@@ -32,7 +32,7 @@
</view>
</view>
<view
class=
"good-info"
>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</view>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
2
</view>
<view
class=
"good-sub-name"
>
{{
item
.
subname
}}
</view>
<view
class=
"good-price-info"
>
<view
class=
"price"
>
...
...
components/goods/style3.vue
View file @
153c9228
...
...
@@ -32,7 +32,7 @@
</div>
</div>
<div
class=
"good-info"
>
<div
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</div>
<div
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
3
</div>
<div
class=
"good-price-info"
>
<view
class=
"price"
:style=
"
{ color: mainColor }">
<span>
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
price
)
:
''
}}
</span>
...
...
components/goods/style4.vue
View file @
153c9228
...
...
@@ -20,7 +20,7 @@
<view
class=
"tips"
v-if=
"goodsInfo.showGoodsTag"
><image
:src=
"goodsInfo.goodsTagPicUrl"
mode=
"widthFix"
style=
"width: 100%;"
/></view>
<view
class=
"img-box"
><image
style=
"width: 100%; height: 100%;"
:mode=
"goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src=
"item.picUrl"
/></view>
<view
class=
"good-info"
>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</view>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
4
</view>
<view
class=
"good-price-info"
>
<view
class=
"price"
:style=
"
{ color: mainColor }">
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
price
)
:
''
}}
</view>
<view
class=
"buy"
v-if=
"goodsInfo.showBuyBtn"
@
click
.
stop=
"showSkuHandler(item)"
>
...
...
components/goods/style5.vue
View file @
153c9228
...
...
@@ -24,7 +24,7 @@
</view>
</view>
<view
class=
"good-info"
>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</view>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
5
</view>
<view
class=
"good-sub-name"
>
{{
item
.
subname
}}
</view>
<view
class=
"good-price-info"
>
<view
class=
"price"
:style=
"
{ color: mainColor }">
...
...
components/goods/style6.vue
View file @
153c9228
<
template
>
<view
style=
"padding: 12px; padding-bottom: 0;width:100%;"
:style=
"
{
<view
style=
"padding: 12px; padding-bottom: 0;width:100%;"
:style=
"
{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
}"
>
<view
class=
"good-four"
v-for=
"(item, gli) in goodList"
:key=
"gli"
@
click=
"openGood(item)"
:style=
"
{
}">
<view
class=
"good-four"
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=
"img-box"
><image
style=
"width: 100%; height: 100%;"
:mode=
"goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src=
"item.picUrl"
/></view>
}">
<view
class=
"tips"
v-if=
"goodsInfo.showGoodsTag"
>
<image
:src=
"goodsInfo.goodsTagPicUrl"
mode=
"widthFix"
style=
"width: 100%;"
/>
</view>
<view
class=
"img-box"
>
<image
style=
"width: 100%; height: 100%;"
:mode=
"goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src=
"item.picUrl"
/>
</view>
<view
class=
"good-info"
>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</view>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
6
</view>
<view
class=
"good-sub-name"
>
{{
item
.
subname
}}
</view>
<view
class=
"good-price-info"
>
<view
class=
"price"
:style=
"
{ color: mainColor }">
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
price
)
:
''
}}
<
span
style=
'text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'
>
原价:
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
OriginalPrice
)
:
''
}}
</span
>
<
!--
<span
style=
'text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'
>
原价:
{{
goodsInfo
.
showGoodsPrice
?
getPrice
(
item
.
OriginalPrice
)
:
''
}}
</span>
--
>
</view>
<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>
...
...
@@ -52,140 +41,160 @@
</
template
>
<
script
>
import
goodSku
from
'../goods/goodsku'
;
import
auth
from
'@/components/auth/index.vue'
;
export
default
{
components
:
{
goodSku
,
auth
},
props
:
[
'goodList'
,
'goodsInfo'
],
data
()
{
return
{
mainColor
:
''
,
activeKey
:
0
,
showSku
:
false
,
sku
:
{},
showAuth
:
false
,
u
:
{}
};
},
created
()
{
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
},
methods
:
{
openGood
(
item
)
{
//线路
if
(
item
.
goodType
==
4
)
{
uni
.
navigateTo
({
url
:
"/pages/jiuzhai/jz_LineDetail?tcid="
+
item
.
id
+
'&configId='
+
item
.
subid
});
}
//酒店
else
if
(
item
.
goodType
==
1
)
{
uni
.
navigateTo
({
url
:
"/pages/hotel/detail?id="
+
item
.
id
});
}
//餐食
else
if
(
item
.
goodType
==
2
)
{
uni
.
navigateTo
({
url
:
'/pages/restaurant/detail?id='
+
item
.
id
});
}
//景点
else
if
(
item
.
goodType
==
3
)
{
uni
.
navigateTo
({
url
:
'/pages/ticketCoupons/detail?id='
+
item
.
id
});
}
import
goodSku
from
'../goods/goodsku'
;
import
auth
from
'@/components/auth/index.vue'
;
export
default
{
components
:
{
goodSku
,
auth
},
showSkuHandler
(
g
)
{
this
.
sku
=
g
;
this
.
u
=
uni
.
getStorageSync
(
'mall_UserInfo'
);
if
(
!
this
.
u
)
{
this
.
u
=
{
nickName
:
'未登录'
,
avatarUrl
:
''
};
this
.
showAuth
=
true
;
}
else
{
this
.
showSku
=
true
;
}
props
:
[
'goodList'
,
'goodsInfo'
],
data
()
{
return
{
mainColor
:
''
,
activeKey
:
0
,
showSku
:
false
,
sku
:
{},
showAuth
:
false
,
u
:
{}
};
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
'mall_UserInfo'
);
// this.showAuth = false;
created
()
{
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
},
//关闭登录窗口
gbAuth
()
{
this
.
showAuth
=
false
;
methods
:
{
openGood
(
item
)
{
//线路
if
(
item
.
goodType
==
4
)
{
uni
.
navigateTo
({
url
:
"/pages/jiuzhai/jz_LineDetail?tcid="
+
item
.
id
+
'&configId='
+
item
.
subid
});
}
//酒店
else
if
(
item
.
goodType
==
1
)
{
uni
.
navigateTo
({
url
:
"/pages/hotel/detail?id="
+
item
.
id
});
}
//餐食
else
if
(
item
.
goodType
==
2
)
{
uni
.
navigateTo
({
url
:
'/pages/restaurant/detail?id='
+
item
.
id
});
}
//景点
else
if
(
item
.
goodType
==
3
)
{
uni
.
navigateTo
({
url
:
'/pages/ticketCoupons/detail?id='
+
item
.
id
});
}
},
showSkuHandler
(
g
)
{
this
.
sku
=
g
;
this
.
u
=
uni
.
getStorageSync
(
'mall_UserInfo'
);
if
(
!
this
.
u
)
{
this
.
u
=
{
nickName
:
'未登录'
,
avatarUrl
:
''
};
this
.
showAuth
=
true
;
}
else
{
this
.
showSku
=
true
;
}
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
'mall_UserInfo'
);
// this.showAuth = false;
},
//关闭登录窗口
gbAuth
()
{
this
.
showAuth
=
false
;
}
}
}
};
};
</
script
>
<
style
>
.good-four
{
position
:
relative
;
margin-bottom
:
14px
;
display
:
flex
;
height
:
102px
;
border
:
1
rpx
solid
transparent
;
border-radius
:
10
rpx
;
box-sizing
:
border-box
;
padding
:
0
1px
1px
0
;
overflow
:
hidden
;
}
.good-four
.tips
{
width
:
64
rpx
;
height
:
64
rpx
;
position
:
absolute
;
top
:
0
;
left
:
0
;
z-index
:
4
;
}
.good-four
.img-box
{
width
:
100px
;
height
:
100px
;
}
.good-four
.good-info
{
padding
:
12px
;
flex
:
1
;
width
:
1
rpx
;
border
:
10
rpx
;
padding-bottom
:
0
;
display
:
flex
;
flex-direction
:
column
;
/* width:20%; */
}
.good-four
.good-info
.good-name
{
font-size
:
13px
;
height
:
34px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
}
.good-four
.good-info
.good-price-info
{
display
:
flex
;
justify-items
:
center
;
align-items
:
flex-end
;
height
:
22px
;
flex
:
1
;
padding-bottom
:
10
rpx
;
}
.good-four
.good-info
.good-price-info
.price
{
color
:
#ff4544
;
flex
:
1
;
font-size
:
14px
;
white-space
:
nowrap
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
.good-four
.good-info
.good-price-info
.buy
{
width
:
24px
;
text-align
:
right
;
}
.good-four
{
position
:
relative
;
margin-bottom
:
14px
;
display
:
flex
;
height
:
102px
;
border
:
1
rpx
solid
transparent
;
border-radius
:
10
rpx
;
box-sizing
:
border-box
;
padding
:
0
1px
1px
0
;
overflow
:
hidden
;
}
.good-four
.tips
{
width
:
64
rpx
;
height
:
64
rpx
;
position
:
absolute
;
top
:
0
;
left
:
0
;
z-index
:
4
;
}
.good-four
.img-box
{
width
:
100px
;
height
:
100px
;
}
.good-four
.good-info
{
padding
:
12px
;
flex
:
1
;
width
:
1
rpx
;
border
:
10
rpx
;
padding-bottom
:
0
;
display
:
flex
;
flex-direction
:
column
;
/* width:20%; */
}
.good-four
.good-info
.good-name
{
font-size
:
13px
;
height
:
34px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
}
.good-four
.good-info
.good-price-info
{
display
:
flex
;
justify-items
:
center
;
align-items
:
flex-end
;
height
:
22px
;
flex
:
1
;
padding-bottom
:
10
rpx
;
}
.good-four
.good-info
.good-price-info
.price
{
color
:
#ff4544
;
flex
:
1
;
font-size
:
14px
;
white-space
:
nowrap
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
.good-four
.good-info
.good-price-info
.buy
{
width
:
24px
;
text-align
:
right
;
}
.
.good-four
.good-info
.good-sub-name
{
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
/* -webkit-line-clamp: 2;
-webkit-box-orient: vertical; */
white-space
:
nowrap
;
margin-bottom
:
10
rpx
;
font-size
:
22
rpx
;
color
:
#999999
;
/* height: 37px; */
}
</
style
>
components/goods/style7.vue
View file @
153c9228
...
...
@@ -24,7 +24,7 @@
<image
class=
"img-2"
:mode=
"goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src=
"item.picUrl"
/>
</view>
<view
class=
"good-info"
>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
</view>
<view
class=
"good-name"
v-if=
"goodsInfo.showGoodsName"
>
{{
item
.
name
}}
7
</view>
<view
class=
"sencond-title"
>
{{
item
.
subname
}}
</view>
<view
class=
"good-price-info"
>
<view>
...
...
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