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
c29ea6c0
Commit
c29ea6c0
authored
Jul 27, 2023
by
hxx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
我要送礼处理
parent
39ee4fab
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
3 deletions
+15
-3
src/api/order.js
+4
-0
src/pages/paySuccess/index.vue
+11
-3
No files found.
src/api/order.js
View file @
c29ea6c0
...
@@ -25,4 +25,8 @@ export default {
...
@@ -25,4 +25,8 @@ export default {
save_pay_with_courtesy_integral
(
data
)
{
save_pay_with_courtesy_integral
(
data
)
{
return
requestPOST
(
`
${
process
.
env
.
OLSHOP_URL
}
/order/save_pay_with_courtesy_integral`
,
data
)
return
requestPOST
(
`
${
process
.
env
.
OLSHOP_URL
}
/order/save_pay_with_courtesy_integral`
,
data
)
},
},
// 查询送礼相关订单
getGiveGiftsOrderDetail
(
giveGiftsCode
)
{
return
requestPOST
(
`
${
process
.
env
.
OLSHOP_URL
}
/order/getGiveGiftsOrderDetail?giveGiftsCode=
${
giveGiftsCode
}
`
);
},
}
}
src/pages/paySuccess/index.vue
View file @
c29ea6c0
...
@@ -290,7 +290,7 @@ export default {
...
@@ -290,7 +290,7 @@ export default {
}
}
},
},
orderMsg
()
{
orderMsg
()
{
order
.
orderDetail
(
this
.
query
).
then
(
res1
=>
{
order
.
orderDetail
(
this
.
query
).
then
(
async
(
res1
)
=>
{
let
res
=
res1
.
data
;
let
res
=
res1
.
data
;
if
(
res
.
code
==
200
)
{
if
(
res
.
code
==
200
)
{
console
.
log
(
"----------------------------------2"
)
console
.
log
(
"----------------------------------2"
)
...
@@ -312,7 +312,15 @@ export default {
...
@@ -312,7 +312,15 @@ export default {
this
.
goodsId
=
this
.
goodsId
=
res
.
data
.
noShipmentOrderItems
[
0
].
terminalProductGoodsId
;
res
.
data
.
noShipmentOrderItems
[
0
].
terminalProductGoodsId
;
}
}
// 查询是否为我要送礼订单
let
sendTotalPrice
=
0
;
if
(
res
.
data
.
giveGiftsCode
)
{
const
response
=
await
order
.
getGiveGiftsOrderDetail
(
res
.
data
.
giveGiftsCode
);
if
(
response
.
data
.
code
==
200
)
{
const
result
=
response
.
data
.
data
.
filter
(
item
=>
item
.
orderSn
!=
res
.
data
.
orderSn
);
if
(
result
.
length
!==
0
)
sendTotalPrice
=
result
[
0
].
totalAmountPayable
-
0
;
}
}
//查询是否是分销员
//查询是否是分销员
getMiniProgram
().
then
(
res1
=>
{
getMiniProgram
().
then
(
res1
=>
{
console
.
log
(
res1
,
'---------------------------res1143'
)
console
.
log
(
res1
,
'---------------------------res1143'
)
...
@@ -349,7 +357,7 @@ export default {
...
@@ -349,7 +357,7 @@ export default {
}
}
});
});
this
.
orderDetail
=
res
.
data
;
this
.
orderDetail
=
res
.
data
;
this
.
totalMoney
=
Number
(
res
.
data
.
totalAmountPayabl
e
).
toFixed
(
2
);
this
.
totalMoney
=
(
Number
(
res
.
data
.
totalAmountPayable
)
+
sendTotalPric
e
).
toFixed
(
2
);
console
.
log
(
Number
(
res
.
data
.
totalAmountPayable
).
toFixed
(
2
),
'--Number(res.data.totalAmountPayable).toFixed(2)'
)
console
.
log
(
Number
(
res
.
data
.
totalAmountPayable
).
toFixed
(
2
),
'--Number(res.data.totalAmountPayable).toFixed(2)'
)
this
.
inviteelShow
=
true
;
this
.
inviteelShow
=
true
;
}
else
{
}
else
{
...
...
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