Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mayi-mp-shop
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
程默
mayi-mp-shop
Commits
9c83b605
Commit
9c83b605
authored
May 20, 2021
by
李嘉林
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
领取会员卡方法
parent
908e3b2b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
src/utils/mayi.js
+13
-10
No files found.
src/utils/mayi.js
View file @
9c83b605
...
@@ -275,7 +275,7 @@ function useCoupon(val, couponCode, usingIntegrals) {
...
@@ -275,7 +275,7 @@ function useCoupon(val, couponCode, usingIntegrals) {
}
}
});
});
};
};
export
function
themeMemberCardClick
(
item
)
{
export
function
themeMemberCardClick
(
item
)
{
let
query
=
{
let
query
=
{
portalCardId
:
item
.
id
portalCardId
:
item
.
id
};
};
...
@@ -295,12 +295,14 @@ export function themeMemberCardClick (item) {
...
@@ -295,12 +295,14 @@ export function themeMemberCardClick (item) {
shop
.
drawV3Card
(
cardId
).
then
(
res
=>
{
shop
.
drawV3Card
(
cardId
).
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
wx
.
showToast
({
wx
.
showToast
({
title
:
`开通【
${
cardData
.
title
}
】成功`
,
content
:
`开通【
${
cardData
.
title
}
】成功`
,
icon
:
"none"
showCancel
:
false
,
}).
then
(
res
=>
{
confirmColor
:
''
,
let
backParams
=
`&cardId=
${
cardData
.
id
}
&userTel=
${
userInfo
.
mobilephone
}
`
;
success
:
res
=>
{
toPage
(
"/personalCenter/membershipCard"
,
backParams
);
let
backParams
=
`&cardId=
${
cardData
.
id
}
&userTel=
${
userInfo
.
mobilephone
}
`
;
});
toPage
(
"/personalCenter/membershipCard"
,
backParams
);
}
})
}
else
{
}
else
{
if
(
res
.
data
.
msg
==
"不能重复领卡"
)
{
if
(
res
.
data
.
msg
==
"不能重复领卡"
)
{
console
.
log
(
"---------------------------to-----1"
)
console
.
log
(
"---------------------------to-----1"
)
...
@@ -333,9 +335,10 @@ export function themeMemberCardClick (item) {
...
@@ -333,9 +335,10 @@ export function themeMemberCardClick (item) {
if
(
res
.
data
.
code
==
300
)
{
if
(
res
.
data
.
code
==
300
)
{
console
.
log
(
'----------334'
)
console
.
log
(
'----------334'
)
// 未登录
// 未登录
const
url
=
`/pages/login/main?back=
${
encodeURIComponent
(
'/'
)}
`
;
setTimeout
(()
=>
{
let
url
=
`/pages/login/main?back=
${
encodeURIComponent
(
'/'
)}
`
;
wx
.
navigateTo
({
url
:
url
});
wx
.
navigateTo
({
url
:
url
});
},
200
);
}
}
}
}
});
});
...
...
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