Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
U
uni-pdtravel
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
panyongping
uni-pdtravel
Commits
932e7f3e
Commit
932e7f3e
authored
Aug 28, 2023
by
renjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
进入相册首页获取优惠券
parent
7620c9d6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
7 deletions
+26
-7
albumIndex.vue
pages/album/albumIndex.vue
+26
-7
No files found.
pages/album/albumIndex.vue
View file @
932e7f3e
...
@@ -182,7 +182,9 @@ export default {
...
@@ -182,7 +182,9 @@ export default {
}
}
],
],
rules
:
[],
//使用规则
rules
:
[],
//使用规则
options
:
{}
//路由参数
options
:
{},
//路由参数
openid
:
''
,
userId
:
''
}
}
},
},
methods
:
{
methods
:
{
...
@@ -199,9 +201,8 @@ export default {
...
@@ -199,9 +201,8 @@ export default {
this
.
showUseRule
=
true
this
.
showUseRule
=
true
},
},
jumpToScanFaceClick
()
{
//---跳转扫脸页面
jumpToScanFaceClick
()
{
//---跳转扫脸页面
const
openid
=
uni
.
getStorageSync
(
'openid'
)
this
.
$request
(
'wechatUser/pdFace/checkScanFace'
,{
openid
}).
then
(
res
=>
{
this
.
$request
(
'wechatUser/pdFace/checkScanFace'
,{
openid
:
this
.
openid
}).
then
(
res
=>
{
if
(
res
.
code
===
'00'
)
{
if
(
res
.
code
===
'00'
)
{
const
merchantId
=
this
.
options
.
merchantId
||
'z0015605022691a5945bbe463141668c'
// 默认长江索道
const
merchantId
=
this
.
options
.
merchantId
||
'z0015605022691a5945bbe463141668c'
// 默认长江索道
if
(
res
.
data
.
isScanFace
===
0
)
{
//未扫脸
if
(
res
.
data
.
isScanFace
===
0
)
{
//未扫脸
...
@@ -292,10 +293,26 @@ export default {
...
@@ -292,10 +293,26 @@ export default {
this
.
show
=
true
this
.
show
=
true
}
}
},
},
findPageMarketFun
(){
//---获取优惠券
var
data
=
{
pageCode
:
'orderInfo'
,
marketingStatus
:
1
,
openid
:
this
.
openid
,
userId
:
this
.
userId
,
}
this
.
$request
(
'scenic/market/findPageMarket'
,
data
).
then
((
res
)
=>
{
if
(
res
.
code
===
'00'
){
this
.
couponIsUse
()
}
else
{
uni
.
showToast
({
title
:
res
.
message
,
icon
:
'none'
})
}
})
},
couponIsUse
()
{
//---判断是否有劵
couponIsUse
()
{
//---判断是否有劵
const
openid
=
uni
.
getStorageSync
(
'openid'
)
this
.
$request
(
'wechatUser/myPage/getUserCouponList'
,{
openid
:
this
.
openid
}).
then
(
res
=>
{
this
.
$request
(
'wechatUser/myPage/getUserCouponList'
,{
openid
}).
then
(
res
=>
{
if
(
res
.
code
===
'00'
)
{
if
(
res
.
code
===
'00'
)
{
res
.
data
.
forEach
(
item
=>
{
res
.
data
.
forEach
(
item
=>
{
if
(
item
.
useRange
===
11
&&
item
.
couponStatus
===
1
)
{
if
(
item
.
useRange
===
11
&&
item
.
couponStatus
===
1
)
{
...
@@ -342,7 +359,9 @@ export default {
...
@@ -342,7 +359,9 @@ export default {
},
},
onLoad
(
options
)
{
onLoad
(
options
)
{
this
.
$commonjs
.
getCompanyId
(
options
)
this
.
$commonjs
.
getCompanyId
(
options
)
this
.
couponIsUse
()
this
.
openid
=
uni
.
getStorageSync
(
'openid'
)
this
.
userId
=
uni
.
getStorageSync
(
'userId'
)
this
.
findPageMarketFun
()
this
.
recordDeviceInfo
()
this
.
recordDeviceInfo
()
this
.
options
=
options
this
.
options
=
options
if
(
this
.
options
.
tip
===
'true'
)
{
// 从模板选择页进入
if
(
this
.
options
.
tip
===
'true'
)
{
// 从模板选择页进入
...
...
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