Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mallapp
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
viitto
mallapp
Commits
eb6a468c
Commit
eb6a468c
authored
Nov 04, 2020
by
Mac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
97ec767f
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
1054 additions
and
137 deletions
+1054
-137
index.vue
pages/index/index.vue
+2
-2
cardList.vue
pages/reserve/personal/cardList.vue
+116
-115
couponDetail.vue
pages/reserve/personal/couponDetail.vue
+35
-19
order-commit-details.vue
pages/reserve/personal/order-commit-details.vue
+362
-0
order-commit.vue
pages/reserve/personal/order-commit.vue
+246
-0
receivecard.vue
pages/reserve/personal/receivecard.vue
+292
-0
storeDetails.vue
pages/reserve/storeDetails.vue
+1
-1
No files found.
pages/index/index.vue
View file @
eb6a468c
...
...
@@ -615,7 +615,7 @@
});
},
isShowBack
()
{
let
navs
=
uni
.
getStorageSync
(
"navs"
)
?
?
[];
let
navs
=
uni
.
getStorageSync
(
"navs"
)
?
uni
.
getStorageSync
(
"navs"
):
[];
if
(
navs
)
{
let
t
=
getCurrentPages
();
let
query
=
t
[
t
.
length
-
1
].
__displayReporter
.
query
;
...
...
@@ -818,7 +818,7 @@
y
.
templateBg
.
backgroundColor
=
x
.
data
.
backgroundColor
;
y
.
templateBg
.
backgroundImage
=
`url('
${
x
.
data
.
backgroundPicUrl
}
')`
;
y
.
templateBg
.
backgroundPosition
=
x
.
data
.
positionText
;
y
.
templateBg
.
backgroundRepeat
=
x
.
data
.
repeatText
?
?
"no-repeat"
;
y
.
templateBg
.
backgroundRepeat
=
x
.
data
.
repeatText
?
x
.
data
.
repeatText
:
"no-repeat"
;
y
.
templateBg
.
backgroundSize
=
`
${
x
.
data
.
backgroundWidth
==
0
...
...
pages/reserve/personal/cardList.vue
View file @
eb6a468c
<
template
>
<view
class=
"cardList"
:style=
"
{ height: contentHeight }">
<u-empty
v-if=
"g.length == 0"
text=
"暂无相关学习卡"
mode=
"coupon"
></u-empty>
<u-tabs
:list=
"list"
:is-scroll=
"false"
:current=
"msg.UseState"
@
change=
"change"
:active-color=
"mainColor"
></u-tabs>
<u-empty
v-if=
"g.length == 0"
text=
"暂无相关套餐卡"
mode=
"coupon"
></u-empty>
<view
v-if=
"g.length > 0"
style=
"
height: calc(100vh);
height: calc(100vh
- 50px
);
width: calc(100vw);
overflow: hidden;
padding-bottom: 50px;
...
...
@@ -20,23 +26,18 @@
:style=
"
{ height: '100%' }"
>
<view
class=
"details"
>
<view
class=
"item"
v-for=
"(x, i) in g"
:key=
"i"
>
<view
class=
"ticket"
>
<image
mode=
"aspectFill"
:src=
"x.CouponIco"
style=
"width: 100%; height: 100%;border-top-left-radius: 5px;border-bottom-left-radius: 5px;"
></image>
</view>
<view
class=
"detail"
>
<view
class=
"coupond"
>
<view
class=
"name"
>
{{
x
.
Name
}}
</view>
<view
class=
"rule"
>
{{
x
.
UseTypeStr
}}
</view>
<view
class=
"date"
v-if=
"x.IndateType==1"
>
领券后
{{
x
.
IndateDay
}}
天过期
</view>
<view
class=
"date"
v-if=
"x.IndateType==2"
>
{{
x
.
StartDate
.
split
(
' '
)[
0
].
replace
(
/-/g
,
'.'
)
+
"-"
+
x
.
EndDate
.
split
(
' '
)[
0
].
replace
(
/-/g
,
'.'
)
}}
</view>
</view>
<view
class=
"chosen"
:style=
"
{'background':mainColor}" @click="receive(x,i)">
<Text>
{{
x
.
IsReceive
==
1
?
'已领取'
:
'立即领取'
}}
</Text>
</view>
<view
class=
"cd-t-box"
v-for=
"(x, i) in g"
:key=
"i"
@
click=
"gocoupon(x)"
>
<view
style=
"display: flex;flex-direction: row;align-items: center;justify-content: space-between;"
>
<text
style=
"font-size: 12px;color: rgba(239, 220, 203, 0.6);"
>
{{
x
.
Name
}}
</text>
<view
class=
"receivebtn"
v-if=
"msg.UseState ==0"
@
click
.
stop=
"gouseUrl(x)"
>
去使用
</view>
</view>
<text
class=
"cd-tt"
>
{{
x
.
Describe
}}
</text>
<text
style=
"font-size: 13px;"
>
核销次数:
{{
x
.
HeXiao
}}
次
</text>
<view
class=
"setmeal-pl"
style=
"left: -12px;"
></view>
<view
class=
"setmeal-pl"
style=
"right: -12px;"
>
</view>
</view>
</view>
</view>
</view>
<u-loadmore
...
...
@@ -49,7 +50,9 @@
/>
</scroll-view>
</view>
<!--
<view
style=
"width: 100%;height: 50px;background: #FFFFFF;display: flex;align-items: center;justify-content: center;position: absolute;left: 0;bottom: 0;border-top: 1px solid #E1E1E1;"
@
click=
"goUrl"
>
<Text>
去领取套餐卡
</Text>
</view>
-->
<!-- 加载中 -->
<view
class=
"loading"
v-if=
"loading"
>
<u-loading
mode=
"flower"
size=
"48"
>
>
</u-loading>
...
...
@@ -69,16 +72,21 @@ export default {
},
data
()
{
return
{
pageTitle
:
"
学习卡中心
"
,
pageTitle
:
"
套餐卡
"
,
showAuth
:
false
,
u
:{},
list
:
[
{
name
:
"未使用"
},
{
name
:
"已使用"
},
{
name
:
"已过期"
},
],
mainColor
:
""
,
contentHeight
:
0
,
msg
:{
pageIndex
:
1
,
pageSize
:
10
,
SmallShopId
:
0
,
UseState
:
0
},
page_count
:
1
,
g
:
[],
...
...
@@ -123,12 +131,19 @@ export default {
}
},
methods
:
{
change
(
index
)
{
this
.
msg
.
UseState
=
index
;
this
.
msg
.
pageIndex
=
1
;
this
.
g
=
[];
this
.
loading
=
true
;
this
.
init
();
},
init
()
{
this
.
msg
.
SmallShopId
=
this
.
u
.
UserSmallShopId
this
.
request2
(
{
url
:
'/api/Applet
Education/GetAll
CouponPageList'
,
url
:
'/api/Applet
Stores/GetMember
CouponPageList'
,
data
:
this
.
msg
},
res
=>
{
...
...
@@ -143,35 +158,6 @@ export default {
}
);
},
receive
(
x
,
i
){
if
(
x
.
IsReceive
==
0
){
this
.
request2
(
{
url
:
'/api/AppletEducation/GrantCoupon'
,
data
:
{
CouponId
:
x
.
CouponId
}
},
(
res
)
=>
{
if
(
res
.
resultCode
==
1
){
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
});
this
.
g
[
i
].
IsReceive
=
1
;
}
}
);
}
else
{
uni
.
showToast
({
title
:
"已领取过学习卡"
,
icon
:
"none"
});
}
},
lower
(
e
)
{
if
(
this
.
msg
.
pageIndex
<
this
.
page_count
)
{
this
.
msg
.
pageIndex
++
;
...
...
@@ -190,7 +176,29 @@ export default {
//关闭登录窗口
gbAuth
(){
uni
.
navigateBack
()
},
},
gouseUrl
(
g
){
let
data
=
[]
if
(
g
.
UseType
==
1
||
g
.
UseType
==
2
){
g
.
ProductList
.
forEach
(
x
=>
{
data
.
push
(
x
.
ProductId
)
})
let
id
=
data
.
toString
()
uni
.
redirectTo
({
url
:
'/pages/goods/list?coupon_id='
+
id
+
'&UseType='
+
g
.
UseType
});
}
else
{
uni
.
redirectTo
({
url
:
'/pages/goods/list'
});
}
},
gocoupon
(
item
){
//优惠券详情
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/couponDetail?ID="
+
item
.
ID
,
})
},
goUrl
(){
//领取套餐卡
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/receivecard"
});
}
},
};
</
script
>
...
...
@@ -222,70 +230,63 @@ export default {
padding
:
15px
;
display
:
flex
;
flex-direction
:
column
;
position
:
relative
;
}
.cardList
.item
{
display
:
flex
;
margin-bottom
:
10px
;
align-items
:
flex-start
;
background
:
#fff
;
border-radius
:
5px
;
box-shadow
:
0
4px
6px
1px
rgba
(
76
,
76
,
76
,
0.1
);
}
.cardList
.details
.item
.ticket
{
width
:
104px
;
height
:
78px
;
.cardList
.receivebtn
{
height
:
25px
;
width
:
60px
;
font-size
:
11px
;
color
:
#221818
;
border-radius
:
4px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
background
:
#FFF
;
}
.cardList
.details
.item
.detail
{
width
:
1px
;
flex
:
1
;
background
:
#fff
;
padding
:
10px
;
display
:
flex
;
align-items
:
center
;
}
.cardList
.details
.item
.detail
.coupond
{
flex
:
1
;
}
.cardList
.details
.item
.detail
.coupond
.name
{
font-size
:
13px
;
font-weight
:
600
;
color
:
#000
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
1
;
-webkit-box-orient
:
vertical
;
}
.cardList
.details
.item
.detail
.coupond
.date
{
margin-top
:
5px
;
font-size
:
11px
;
color
:
#777
;
}
.cardList
.details
.item
.detail
.coupond
.rule
{
font-size
:
11px
;
color
:
#777
;
margin-top
:
5px
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
1
;
-webkit-box-orient
:
vertical
;
}
.cardList
.details
.item
.detail
.chosen
{
width
:
60px
;
height
:
25px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
font-size
:
11px
;
border-radius
:
4px
;
color
:
#FFF
;
}
.cardList
.details
.imgs
{
width
:
55px
;
height
:
52px
;
position
:
absolute
;
top
:
0px
;
right
:
0px
;
}
.cardList
.cd-t-box
{
width
:
100%
;
height
:
115px
;
background-image
:
url('https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/cpoun.png')
;
background-repeat
:
no-repeat
;
background-size
:
cover
;
padding
:
15px
20px
;
color
:
#EFDCCB
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
space-between
;
border-radius
:
6px
;
position
:
relative
;
box-shadow
:
0
4px
10px
1px
#D2D2D2
;
margin-bottom
:
15px
;
}
.cardList
.cd-tt
{
width
:
100%
;
display
:
inline-block
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
2
;
line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
font-size
:
15px
;
}
.cardList
.setmeal-pl
{
position
:
absolute
;
top
:
45.5px
;
width
:
24px
;
height
:
24px
;
border-radius
:
12px
;
background
:
#FFF
;
}
...
...
pages/reserve/personal/couponDetail.vue
View file @
eb6a468c
...
...
@@ -129,7 +129,7 @@
<view
class=
"cd-t-box"
>
<text
style=
"font-size: 12px;color: rgba(239, 220, 203, 0.6);"
>
{{
cdetail
.
Name
}}
</text>
<text
class=
"cd-tt"
>
{{
cdetail
.
Describe
}}
</text>
<text
style=
"font-size: 13px;"
>
核销次数:
{{
cdetail
.
TotalNum
}}
次
</text>
<text
style=
"font-size: 13px;"
>
核销次数:
{{
cdetail
.
HeXiao
}}
次
</text>
<view
class=
"setmeal-pl"
style=
"left: -12px;"
></view>
<view
class=
"setmeal-pl"
style=
"right: -12px;"
>
</view>
</view>
...
...
@@ -195,15 +195,15 @@
:ripple=
"true"
shape=
"circle"
@
click=
"
cdetail.MemberNum>0?'':
submitreceive()"
@
click=
"submitreceive()"
:custom-style=
"
{
backgroundColor:
cdetail.MemberNum>0? '#D4D4D4':
mc,
backgroundColor:mc,
height: '80rpx',
color: '#FFF',
fontSize: '14px',
}"
>
{{
cdetail
.
MemberNum
>
0
?
'
已领取
'
:
'立即领取'
}}
{{
cdetail
.
MemberNum
>
0
?
'
去使用
'
:
'立即领取'
}}
</u-button>
</view>
</view>
...
...
@@ -218,6 +218,7 @@
mc
:
""
,
loading
:
false
,
ID
:
0
,
storeId
:
0
,
cdetail
:{},
current
:
0
,
submitOrder
:
false
,
...
...
@@ -236,6 +237,9 @@
if
(
option
&&
option
.
ID
){
this
.
ID
=
option
.
ID
}
if
(
option
&&
option
.
storeId
){
this
.
storeId
=
option
.
storeId
}
this
.
getDetail
()
//获取套餐卡详情
...
...
@@ -268,23 +272,35 @@
);
},
submitreceive
(){
this
.
request2
({
url
:
'/api/AppletStores/GrantCoupon'
,
data
:
{
ID
:
this
.
ID
}
},
res
=>
{
if
(
res
.
resultCode
==
1
)
{
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
,
});
this
.
cdetail
.
MemberNum
=
1
if
(
this
.
cdetail
.
MemberNum
==
0
){
this
.
request2
({
url
:
'/api/AppletStores/GrantCoupon'
,
data
:
{
CouponId
:
this
.
ID
,
StoreId
:
this
.
storeId
}
},
res
=>
{
if
(
res
.
resultCode
==
1
)
{
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
,
});
this
.
cdetail
.
MemberNum
=
1
}
}
);
}
else
{
let
data
=
[]
let
g
=
this
.
cdetail
if
(
g
.
UseType
==
1
||
g
.
UseType
==
2
){
g
.
ProductList
.
forEach
(
x
=>
{
data
.
push
(
x
.
ProductId
)
})
let
id
=
data
.
toString
()
uni
.
redirectTo
({
url
:
'/pages/goods/list?coupon_id='
+
id
+
'&UseType='
+
g
.
UseType
});
}
else
{
uni
.
redirectTo
({
url
:
'/pages/goods/list'
});
}
);
}
},
change
(
e
){
this
.
current
=
e
;
...
...
pages/reserve/personal/order-commit-details.vue
0 → 100644
View file @
eb6a468c
<
template
>
<view
class=
"commit-detail"
>
<u-top-tips
ref=
"uTips"
></u-top-tips>
<view
class=
"good_List"
>
<view
class=
"good-item"
>
<image
class=
"good-pic"
:src=
"dataList.CoverImage"
mode=
"aspectFill"
/>
<view
class=
"right-box"
>
<view
class=
"good-info"
>
{{
dataList
.
GoodsName
}}
</view>
<view
class=
"op-box"
>
服务时间:
{{
dataList
.
ServiceDate
+
' '
+
dataList
.
ServiceTime
}}
</view>
</view>
</view>
<view
class=
"good_Line"
></view>
<view
style=
"padding:0 10px 20px 10px;"
>
<view
class=
"title-box"
>
<text
style=
"margin-right:10px;"
>
商品评价
</text>
<u-rate
:current=
"msg[0].CommentScore"
active-color=
"#FA3534"
inactive-color=
"#b2b2b2"
active-icon=
"star"
inactive-icon=
"star-o"
size=
"40"
@
change=
'change1'
></u-rate>
</view>
<view
class=
"editor-box"
>
<view
class=
"editor-icon"
>
<u-icon
name=
"edit"
size=
"36"
></u-icon>
</view>
<view
class=
"editor"
>
<textarea
placeholder=
"写入评价"
v-model=
"msg[0].Content"
maxlength=
"200"
></textarea>
<u-upload
:action=
"action"
:file-list=
"fileList"
@
on-remove=
"onRemove1"
max-count=
"9"
:custom-btn=
"true"
@
on-success=
"uploadSuccessHandler"
>
<view
slot=
"addBtn"
class=
"slot-btn"
>
<u-icon
name=
"photograph"
size=
"40"
color=
"#888"
></u-icon>
<view
class=
"mian-title"
>
上传图片
</view>
</view>
</u-upload>
</view>
</view>
</view>
</view>
<view
class=
"good_List"
>
<view
class=
"good-item"
style=
"margin-bottom:0;"
>
<u-avatar
mode=
"circle"
:src=
"dataList.ServicepersonalHead"
></u-avatar>
<view
style=
"margin:13px 0 0 10px;"
>
{{
dataList
.
ServicepersonalName
}}
</view>
</view>
<view
style=
"padding:0 10px 20px 10px;"
>
<view
class=
"title-box"
>
<text
style=
"margin-right:10px;"
>
服务人员评价
</text>
<u-rate
:current=
"msg[1].CommentScore"
active-color=
"#FA3534"
inactive-color=
"#b2b2b2"
active-icon=
"star"
inactive-icon=
"star-o"
size=
"40"
@
change=
'change2'
></u-rate>
</view>
<view
class=
"editor-box"
>
<view
class=
"editor-icon"
>
<u-icon
name=
"edit"
size=
"36"
></u-icon>
</view>
<view
class=
"editor"
>
<textarea
placeholder=
"写入评价"
v-model=
"msg[1].Content"
maxlength=
"200"
></textarea>
<u-upload
:action=
"action"
:file-list=
"fileList2"
style=
"display:none;"
@
on-remove=
"onRemove2"
max-count=
"9"
:custom-btn=
"true"
@
on-success=
"uploadSuccessHandler2"
>
<view
slot=
"addBtn"
class=
"slot-btn"
>
<u-icon
name=
"photograph"
size=
"40"
color=
"#888"
></u-icon>
<view
class=
"mian-title"
>
上传图片
</view>
</view>
</u-upload>
</view>
</view>
</view>
</view>
<view
style=
"padding:10px 40px;"
>
<u-button
size=
"80"
:ripple=
"true"
@
click=
"submitForm"
shape=
"circle"
:custom-style=
"
{
backgroundColor: mc,
height: '80rpx',
color: '#FFF',
fontSize: '14px'
}">
<u-loading
mode=
"circle"
style=
"margin-right: 5px;"
v-if=
"submitStatus"
></u-loading>
提交评价
</u-button>
</view>
</view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
pageTitle
:
"发表评价"
,
mc
:
""
,
secondary
:
""
,
msg
:
[{
OrderDetailId
:
0
,
//订单详情
GoodsId
:
0
,
//商品id
Content
:
''
,
//评价内容
CommentImgList
:
[],
//评价图片
CommentScore
:
5
,
//分数
GuideId
:
0
,
//导游(导游id(新增一条评论需新增2调数据,一个是对导游(车辆id=0)的一个是对车辆的(导游id=0)
CarId
:
0
,
//车辆(车辆id)
ServicePersonalId
:
0
,
StoreId
:
0
,
},
{
OrderDetailId
:
0
,
//订单详情
GoodsId
:
0
,
//商品id
Content
:
''
,
//评价内容
CommentImgList
:
[],
//评价图片
CommentScore
:
5
,
//分数
GuideId
:
0
,
//导游(导游id(新增一条评论需新增2调数据,一个是对导游(车辆id=0)的一个是对车辆的(导游id=0)
CarId
:
0
,
//车辆(车辆id)
ServicePersonalId
:
0
,
StoreId
:
0
,
}],
OrderId
:
0
,
submitStatus
:
false
,
goodsName
:
""
,
goodsPic
:
""
,
action
:
this
.
host2
+
"/api/File/UploadTencent"
,
fileList
:
[],
//商品上传图
fileList2
:
[],
//导游上传图
dataList
:
{},
//商品详情数据
};
},
onLoad
(
option
)
{
if
(
option
.
param
)
{
let
param
=
JSON
.
parse
(
decodeURIComponent
(
option
.
param
));
console
.
log
(
param
)
this
.
dataList
=
param
this
.
msg
[
0
].
GoodsId
=
param
.
GoodsId
;
this
.
msg
[
1
].
GoodsId
=
param
.
GoodsId
;
this
.
msg
[
0
].
StoreId
=
param
.
StoreId
;
this
.
msg
[
1
].
ServicePersonalId
=
param
.
ServicePersonalId
;
this
.
msg
[
0
].
OrderDetailId
=
param
.
OrderDetailId
;
this
.
msg
[
1
].
OrderDetailId
=
param
.
OrderDetailId
;
this
.
goodsName
=
param
.
GoodsName
;
this
.
goodsPic
=
param
.
CoverImage
;
this
.
OrderId
=
param
.
OrderId
;
// this.getOrderDetail();
}
},
mounted
()
{
uni
.
setNavigationBarTitle
({
title
:
this
.
pageTitle
,
});
this
.
mc
=
this
.
$uiConfig
.
mainColor
;
this
.
secondary
=
this
.
$uiConfig
.
secondary
;
let
MallBaseId
=
uni
.
getStorageSync
(
"mall_UserInfo"
).
MallBaseId
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
MallBaseId
:
1
;
this
.
action
=
this
.
host2
+
'/api/File/UploadTencent?MallBaseId='
+
MallBaseId
},
methods
:
{
uploadSuccessHandler
(
data
,
index
,
lists
)
{
let
r
=
JSON
.
parse
(
data
);
this
.
msg
[
0
].
CommentImgList
.
push
(
r
.
data
);
},
uploadSuccessHandler2
(
data
,
index
,
lists
)
{
let
r
=
JSON
.
parse
(
data
);
this
.
msg
[
1
].
CommentImgList
.
push
(
r
.
data
);
},
//删除1
onRemove1
(
index
)
{
this
.
msg
[
0
].
CommentImgList
.
splice
(
index
,
1
);
},
//删除2
onRemove2
(
index
)
{
this
.
msg
[
1
].
CommentImgList
.
splice
(
index
,
1
);
},
change1
(
val
)
{
this
.
msg
[
0
].
CommentScore
=
val
},
change2
(
val
)
{
this
.
msg
[
1
].
CommentScore
=
val
},
submitForm
()
{
let
pages
=
getCurrentPages
();
// 当前页面
let
beforePage
beforePage
=
pages
[
pages
.
length
-
2
];
// 前一个页面
if
(
this
.
msg
[
0
].
CommentScore
==
0
)
{
this
.
$refs
.
uTips
.
show
({
title
:
"请您为门店打打分吧"
,
type
:
"error"
,
duration
:
"2300"
,
});
return
;
}
if
(
this
.
msg
[
1
].
CommentScore
==
0
)
{
this
.
$refs
.
uTips
.
show
({
title
:
"请您为服务人员打打分吧"
,
type
:
"error"
,
duration
:
"2300"
,
});
return
;
}
this
.
submitStatus
=
true
;
this
.
request2
({
url
:
"/api/AppletStores/SetGuideCarCommentInfo"
,
data
:
this
.
msg
,
},
(
res
)
=>
{
if
(
res
.
resultCode
==
1
)
{
let
that
=
this
uni
.
showModal
({
content
:
"评价成功,感谢您的反馈"
,
showCancel
:
false
,
confirmText
:
"确认"
,
success
:
function
(
res2
)
{
if
(
res2
.
confirm
)
{
uni
.
navigateBack
({
delta
:
1
,
success
:
function
()
{
if
(
res
.
msgType
==
2
&&
res
.
couponResultCode
==
1
)
{
beforePage
.
$vm
.
getReceive
(
res
.
couponMessage
,
res
.
msgType
);
// 执行前一个页面的方法
}
}
});
}
that
.
submitStatus
=
false
;
},
});
}
else
{
this
.
submitStatus
=
false
;
this
.
$refs
.
uTips
.
show
({
title
:
res
.
msg
,
type
:
"error"
,
duration
:
"2300"
,
});
}
}
);
},
}
};
</
script
>
<
style
>
.commit-detail
{
background
:
#faf8f9
;
position
:
relative
;
}
.commit-detail
.good-item
{
margin
:
10px
0
;
background
:
#fff
;
padding
:
10px
;
border-radius
:
10px
;
display
:
flex
;
}
.good_Line
{
width
:
95%
;
margin
:
auto
;
height
:
1px
;
border-top
:
1px
solid
#e2e2e2
;
padding-bottom
:
15px
;
}
.commit-detail
.good-item
.good-pic
{
width
:
120
rpx
;
height
:
120
rpx
;
margin-right
:
15px
;
border-radius
:
5px
;
}
.commit-detail
.good-item
.right-box
{
width
:
1px
;
flex
:
1
;
display
:
flex
;
flex-direction
:
column
;
height
:
100
rpx
;
}
.commit-detail
.good-item
.right-box
.good-info
{
flex
:
1
;
width
:
100%
;
height
:
1px
;
font-size
:
28
rpx
;
color
:
#333
;
white-space
:
nowrap
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
word-break
:
break-all
;
margin-bottom
:
5px
;
}
.commit-detail
.good-item
.right-box
.op-box
{
height
:
25px
;
line-height
:
25px
;
font-family
:
aa
;
font-size
:
12px
;
color
:
#A3A3A3
;
}
.commit-detail
.content-box
{
background
:
#fff
;
padding
:
15px
;
border-radius
:
5px
;
}
.commit-detail
.good_List
.title-box
{
padding-bottom
:
15px
;
/* border-bottom: 1px solid #e3e3e3; */
font-size
:
15px
;
font-weight
:
500
;
margin-bottom
:
15px
;
color
:
#000
;
display
:
flex
;
align-items
:
center
;
}
.commit-detail
.good_List
.editor-box
{
display
:
flex
;
}
.commit-detail
.good_List
.editor-box
.editor-icon
{
width
:
18px
;
margin-right
:
5px
;
}
.commit-detail
.good_List
.editor-box
.editor
{
width
:
1px
;
flex
:
1
;
}
.commit-detail
.good_List
.editor-box
.editor
textarea
{
width
:
100%
;
height
:
100px
;
font-size
:
14px
;
color
:
#000
;
border
:
none
;
outline
:
none
;
margin-bottom
:
10px
;
}
.commit-detail
.good_List
.editor-box
.editor
.slot-btn
{
width
:
140
rpx
;
height
:
140
rpx
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
flex-direction
:
column
;
background
:
rgb
(
244
,
245
,
246
);
border-radius
:
10
rpx
;
}
.commit-detail
.content-box
.editor-box
.editor
.slot-btn
.mian-title
{
font-size
:
28
rpx
;
color
:
#888
;
font-weight
:
600
;
margin
:
10
rpx
0
;
}
.commit-detail
.content-box
.editor-box
.editor
.slot-btn
.sub-title
{
color
:
#999
;
font-size
:
26
rpx
;
font-family
:
"microsoft yahei"
!important
;
}
.commit-detail
.u-list-item
{
width
:
90px
!important
;
height
:
90px
!important
;
}
.commit-detail
.good_List
{
background-color
:
#fff
;
margin-bottom
:
10px
;
}
</
style
>
pages/reserve/personal/order-commit.vue
0 → 100644
View file @
eb6a468c
<
template
>
<view
class=
"commit-box"
>
<u-empty
text=
"没有找到未评价的商品信息"
font-size=
"36"
mode=
"list"
v-if=
"g.length == 0 && !loading"
></u-empty>
<view
v-if=
"g.length > 0"
style=
"height: 100vh;width: 100vw;overflow: hidden;padding:0 0 10px 0;"
>
<scroll-view
:scroll-y=
"true"
@
scrolltolower=
"lower"
:enable-back-to-top=
"true"
:enable-flex=
"true"
:scroll-top=
"scrollTop"
@
scroll=
"scroll"
style=
"height: 100%; padding-bottom: 0px;"
>
<view
class=
"good-list"
>
<view
class=
"good-item"
v-for=
"(x, i) in g"
:key=
"i"
>
<image
class=
"good-pic"
:src=
"x.CoverImage"
mode=
"aspectFill"
/>
<view
class=
"right-box"
>
<view
class=
"good-info"
>
<view
class=
"good-name"
>
{{
x
.
GoodsName
}}
</view>
<view
class=
"good-attr"
>
服务人员:
{{
x
.
ServicepersonalName
}}
</view>
<view
class=
"good-attr"
>
服务时间:
{{
x
.
ServiceDate
+
' '
+
x
.
ServiceTime
}}
</view>
</view>
<view
class=
"op-box"
>
<u-button
size=
"mini"
ripple
plain
shape=
"circle"
:custom-style=
"
{color:mc,borderColor:mc}" @click="goCommit(x)">评价
</u-button>
</view>
</view>
</view>
</view>
<u-loadmore
v-if=
"showLoading"
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"20"
:margin-bottom=
"20"
bg-color=
"#F5F5F5"
/>
</scroll-view>
</view>
<coupon
v-if=
"showCoupons"
:coupon-message=
"couponMessage"
:msgtype=
"msgType"
@
goLook=
"goLook"
@
closeBtn=
"closeBtn"
></coupon>
</view>
</
template
>
<
script
>
import
coupon
from
"@/components/coupons/coupons"
;
export
default
{
components
:
{
coupon
},
data
()
{
return
{
pageTitle
:
"评价中心"
,
loading
:
false
,
g
:
[],
showLoading
:
false
,
loadText
:
{
loadmore
:
"轻轻上拉,加载更多"
,
loading
:
"努力加载中"
,
nomore
:
"没有更多评价商品了"
,
},
status
:
"loadmore"
,
scrollTop
:
0
,
old
:
{
scrollTop
:
0
,
},
mc
:
""
,
secondary
:
""
,
msg
:
{
pageIndex
:
1
,
pageSize
:
10
,
IsComment
:
2
,
GoodsName
:
""
,
OrderNo
:
""
,
OrderClassify
:
3
,
},
page_count
:
0
,
isover
:
false
,
couponMessage
:
""
,
//弹出优惠券的内容
showCoupons
:
false
,
msgType
:
1
,
//类型
};
},
onShow
()
{
this
.
msg
.
pageIndex
=
1
;
this
.
g
=
[];
console
.
log
(
this
.
g
)
this
.
init
();
},
mounted
()
{
uni
.
setNavigationBarTitle
({
title
:
this
.
pageTitle
,
});
this
.
mc
=
this
.
$uiConfig
.
mainColor
;
this
.
secondary
=
this
.
$uiConfig
.
secondary
;
},
methods
:
{
scroll
(
e
)
{
this
.
old
.
scrollTop
=
e
.
detail
.
scrollTop
;
},
goCommit
(
x
)
{
// let msg = {
// GoodsId: x.GoodsId,
// OrderDetailId: x.OrderDetailId,
// GoodsName: x.GoodsName,
// CoverImage: x.CoverImage,
// };
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/order-commit-details?param="
+
encodeURIComponent
(
JSON
.
stringify
(
x
)),
fail
:
function
(
e
)
{
console
.
log
(
e
);
},
});
},
goTop
(
e
)
{
this
.
scrollTop
=
this
.
old
.
scrollTop
;
this
.
$nextTick
(
function
()
{
this
.
scrollTop
=
0
;
});
},
init
()
{
this
.
isover
=
false
;
this
.
loading
=
true
;
this
.
showLoading
=
this
.
msg
.
pageIndex
!=
1
;
this
.
request2
({
url
:
"/api/AppletOrder/GetAppletGoodsWaitCommentPageList"
,
data
:
this
.
msg
,
},
(
res
)
=>
{
this
.
isloading
=
false
;
if
(
res
.
resultCode
==
1
)
{
this
.
g
=
this
.
g
.
concat
(
res
.
data
.
pageData
);
this
.
page_count
=
res
.
data
.
pageCount
;
if
(
this
.
page_count
==
1
)
{
this
.
isover
=
true
;
this
.
status
=
"nomore"
;
}
else
{
this
.
status
=
"loadmore"
;
}
}
uni
.
hideNavigationBarLoading
();
}
);
},
lower
(
e
)
{
if
(
this
.
msg
.
pageIndex
<
this
.
page_count
)
{
this
.
status
=
"loading"
;
this
.
msg
.
pageIndex
++
;
this
.
init
();
}
else
{
this
.
isover
=
true
;
this
.
status
=
"nomore"
;
}
},
getReceive
(
couponMessage
,
msgType
)
{
setTimeout
(()
=>
{
this
.
couponMessage
=
'获取'
+
couponMessage
+
'套餐卡'
;
this
.
msgType
=
msgType
;
this
.
showCoupons
=
true
;
},
500
)
},
goLook
()
{
this
.
showCoupons
=
true
;
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/cardList"
,
});
},
closeBtn
()
{
this
.
showCoupons
=
false
;
},
},
};
</
script
>
<
style
>
.commit-box
{
background
:
#faf8f9
;
height
:
100vh
;
position
:
relative
;
}
.commit-box
.quick
{
right
:
50
rpx
;
bottom
:
50
rpx
;
position
:
absolute
;
}
.commit-box
.quick
.item
{
background
:
#fff
;
border
:
1px
solid
#aaa
;
height
:
90
rpx
;
width
:
90
rpx
;
color
:
#333
;
border-radius
:
90
rpx
;
margin-top
:
40
rpx
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
}
.commit-box
.good-list
{}
.commit-box
.good-list
.good-item
{
margin-top
:
10px
;
background
:
#fff
;
padding
:
10px
;
border-radius
:
10px
;
display
:
flex
;
}
.commit-box
.good-list
.good-item
.good-pic
{
width
:
200
rpx
;
height
:
200
rpx
;
margin-right
:
15px
;
border-radius
:
5px
;
}
.commit-box
.good-list
.good-item
.right-box
{
width
:
1px
;
flex
:
1
;
display
:
flex
;
flex-direction
:
column
;
height
:
200
rpx
;
}
.commit-box
.good-list
.good-item
.right-box
.good-info
{
flex
:
1
;
width
:
100%
;
height
:
1px
;
}
.commit-box
.good-list
.good-item
.right-box
.op-box
{
text-align
:
right
;
height
:
25px
;
}
.commit-box
.good-list
.good-item
.right-box
.good-info
.good-name
{
font-size
:
28
rpx
;
color
:
#333
;
text-overflow
:
-o-ellipsis-lastline
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
2
;
line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
margin-bottom
:
5px
;
}
.commit-box
.good-list
.good-item
.right-box
.good-info
.good-attr
{
text-align
:
left
;
font-family
:
aa
;
font-size
:
12px
;
color
:
#A3A3A3
;
}
</
style
>
pages/reserve/personal/receivecard.vue
0 → 100644
View file @
eb6a468c
<
template
>
<view
class=
"receivecard"
:style=
"
{ height: contentHeight }">
<u-empty
v-if=
"g.length == 0"
text=
"暂无相关套餐卡"
mode=
"coupon"
></u-empty>
<view
v-if=
"g.length > 0"
style=
"
height: calc(100vh);
width: calc(100vw);
overflow: hidden;
padding-bottom: 50px;
"
>
<scroll-view
:scroll-y=
"true"
:enable-back-to-top=
"true"
:enable-flex=
"true"
@
scrolltolower=
"lower"
:style=
"
{ height: '100%' }"
>
<view
class=
"details"
>
<view
class=
"cd-t-box"
v-for=
"(x, i) in g"
:key=
"i"
@
click=
"gocoupon(x)"
>
<view
style=
"display: flex;flex-direction: row;align-items: center;justify-content: space-between;"
>
<text
style=
"font-size: 12px;color: rgba(239, 220, 203, 0.6);"
>
{{
x
.
Name
}}
</text>
<view
class=
"receivebtn"
@
click
.
stop=
"receive(x)"
>
{{
x
.
IsReceive
>
0
?
'去使用'
:
'立即领取'
}}
</view>
</view>
<text
class=
"cd-tt"
>
{{
x
.
Describe
}}
</text>
<text
style=
"font-size: 13px;"
>
核销次数:
{{
x
.
TotalNum
}}
次
</text>
<view
class=
"setmeal-pl"
style=
"left: -12px;"
></view>
<view
class=
"setmeal-pl"
style=
"right: -12px;"
>
</view>
</view>
</view>
<u-loadmore
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"20"
:margin-bottom=
"20"
bg-color=
"#FFF"
/>
</scroll-view>
</view>
<!-- 加载中 -->
<view
class=
"loading"
v-if=
"loading"
>
<u-loading
mode=
"flower"
size=
"48"
>
>
</u-loading>
<Text
style=
"color: #fff; margin-top: 10rpx;"
>
加载中...
</Text>
</view>
<!-- 取消提示 -->
<u-toast
ref=
"uToast"
/>
<auth
v-if=
"showAuth"
@
changeuserinfo=
"reloadUserinfo"
@
gbAuth=
'gbAuth'
></auth>
</view>
</
template
>
<
script
>
import
auth
from
"@/components/auth/index.vue"
;
export
default
{
components
:
{
auth
},
data
()
{
return
{
pageTitle
:
"套餐卡中心"
,
showAuth
:
false
,
u
:{},
mainColor
:
""
,
contentHeight
:
0
,
msg
:{
pageIndex
:
1
,
pageSize
:
10
,
SmallShopId
:
0
,
StoreId
:
0
,
},
page_count
:
1
,
g
:
[],
loading
:
false
,
status
:
"loadmore"
,
loadText
:
{
loadmore
:
"轻轻上拉,加载更多"
,
loading
:
"努力加载中"
,
nomore
:
"没有更多了"
,
},
};
},
created
()
{
this
.
contentHeight
=
this
.
$utils
.
calcContentHeight
(
-
40
)
+
"px"
;
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
},
mounted
()
{
let
currentPages
=
getCurrentPages
();
let
u
=
"/"
+
currentPages
[
currentPages
.
length
-
1
].
route
;
let
pages
=
wx
.
getStorageSync
(
"basedata"
)
?
wx
.
getStorageSync
(
"basedata"
).
bar_title
:
[];
pages
.
forEach
((
x
)
=>
{
if
(
x
.
value
==
u
)
{
this
.
pageTitle
=
x
.
new_name
?
x
.
new_name
:
x
.
name
;
}
});
uni
.
setNavigationBarTitle
({
title
:
this
.
pageTitle
,
});
},
onLoad
:
function
(
option
)
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
if
(
!
this
.
u
)
{
this
.
u
=
{
nickName
:
"未登录"
,
avatarUrl
:
""
};
this
.
showAuth
=
true
;
}
else
{
this
.
init
();
}
},
methods
:
{
init
()
{
this
.
msg
.
SmallShopId
=
this
.
u
.
UserSmallShopId
this
.
msg
.
StoreId
=
uni
.
getStorageSync
(
"storeId"
)?
uni
.
getStorageSync
(
"storeId"
).
storeId
:
0
;
this
.
request2
(
{
url
:
'/api/AppletStores/GetAllCouponPageList'
,
data
:
this
.
msg
},
res
=>
{
if
(
res
.
resultCode
==
1
){
this
.
loading
=
false
;
this
.
g
=
this
.
g
.
concat
(
res
.
data
.
pageData
);
this
.
page_count
=
res
.
data
.
pageCount
;
if
(
this
.
page_count
==
1
)
{
this
.
status
=
"nomore"
;
}
}
}
);
},
gocoupon
(
item
){
//优惠券详情
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/couponDetail?ID="
+
item
.
CouponId
,
})
},
receive
(
x
,
i
){
if
(
x
.
IsReceive
==
0
){
this
.
request2
(
{
url
:
'/api/AppletStores/GrantCoupon'
,
data
:
{
CouponId
:
x
.
CouponId
}
},
(
res
)
=>
{
if
(
res
.
resultCode
==
1
){
uni
.
showToast
({
title
:
res
.
message
,
icon
:
"none"
});
this
.
g
[
i
].
IsReceive
=
1
;
}
}
);
}
else
{
let
data
=
[]
let
g
=
x
if
(
g
.
UseType
==
1
||
g
.
UseType
==
2
){
g
.
ProductList
.
forEach
(
x
=>
{
data
.
push
(
x
.
ProductId
)
})
let
id
=
data
.
toString
()
uni
.
redirectTo
({
url
:
'/pages/goods/list?coupon_id='
+
id
+
'&UseType='
+
g
.
UseType
});
}
else
{
uni
.
redirectTo
({
url
:
'/pages/goods/list'
});
}
}
},
lower
(
e
)
{
if
(
this
.
msg
.
pageIndex
<
this
.
page_count
)
{
this
.
msg
.
pageIndex
++
;
this
.
status
=
"loading"
;
this
.
init
();
}
else
{
this
.
status
=
"nomore"
;
}
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
// this.showAuth=false;
this
.
init
();
},
//关闭登录窗口
gbAuth
(){
uni
.
navigateBack
()
},
},
};
</
script
>
<
style
>
.receivecard
{
width
:
100%
;
height
:
100%
;
background
:
#FFF
;
position
:
relative
;
}
.receivecard
.loading
{
width
:
180
rpx
;
height
:
180
rpx
;
background
:
#000000
;
opacity
:
0.7
;
border-radius
:
10
rpx
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
justify-content
:
center
;
position
:
fixed
;
left
:
50%
;
top
:
30%
;
margin-left
:
-100
rpx
;
z-index
:
999
;
}
.receivecard
.details
{
padding
:
15px
;
display
:
flex
;
flex-direction
:
column
;
position
:
relative
;
}
.receivecard
.cd-t-box
{
width
:
100%
;
height
:
115px
;
background-image
:
url('https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/cpoun.png')
;
background-repeat
:
no-repeat
;
background-size
:
cover
;
padding
:
15px
20px
;
color
:
#EFDCCB
;
display
:
flex
;
flex-direction
:
column
;
justify-content
:
space-between
;
border-radius
:
6px
;
position
:
relative
;
box-shadow
:
0
4px
10px
1px
#D2D2D2
;
margin-bottom
:
15px
;
}
.receivecard
.cd-tt
{
width
:
100%
;
display
:
inline-block
;
overflow
:
hidden
;
text-overflow
:
ellipsis
;
display
:
-webkit-box
;
-webkit-line-clamp
:
2
;
line-clamp
:
2
;
-webkit-box-orient
:
vertical
;
font-size
:
15px
;
}
.receivecard
.setmeal-pl
{
position
:
absolute
;
top
:
45.5px
;
width
:
24px
;
height
:
24px
;
border-radius
:
12px
;
background
:
#FFF
;
}
.receivecard
.receivebtn
{
height
:
25px
;
width
:
60px
;
font-size
:
11px
;
color
:
#221818
;
border-radius
:
4px
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
background
:
#FFF
;
}
</
style
>
pages/reserve/storeDetails.vue
View file @
eb6a468c
...
...
@@ -767,7 +767,7 @@
},
gocoupon
(
item
){
//优惠券详情
uni
.
navigateTo
({
url
:
"/pages/reserve/personal/couponDetail?ID="
+
item
.
CouponId
,
url
:
"/pages/reserve/personal/couponDetail?ID="
+
item
.
CouponId
+
'&storeId='
+
this
.
id
,
})
},
godesigner
(
item
){
//设计师详情
...
...
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