Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cauchy-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
ui
cauchy-ui
Commits
1f906032
Commit
1f906032
authored
Jul 17, 2021
by
FE-安焕焕
👣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
支付成功的金额
parent
ed2fb93a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
6 deletions
+9
-6
index.vue
src/views/pay/index.vue
+9
-6
No files found.
src/views/pay/index.vue
View file @
1f906032
...
...
@@ -388,6 +388,7 @@ export default {
this
.
$toast
(
'
请仔细阅读并同意相关协议
'
);
return
;
}
this
.
setAmount
();
if
(
!
params
&&
!
this
.
isDetention
&&
IS_THIRD_PAY
(
this
.
payType
))
{
this
.
isDetention
=
true
;
isDetentionFn
.
call
(
this
);
...
...
@@ -466,12 +467,6 @@ export default {
}
},
payResult
(
type
,
error
)
{
const
finalAmt
=
IS_THIRD_PAY
(
this
.
payType
)
||
!
this
.
showCoupon
?
this
.
displayInfo
.
orderAmt
||
'
0.00
'
:
(
this
.
displayInfo
.
orderAmt
-
this
.
selectedCoupon
.
faceValue
||
0
).
toFixed
(
2
);
const
freeAmount
=
this
.
showCoupon
?
this
.
selectedCoupon
.
faceValue
||
'
0.00
'
:
'
0.00
'
;
cookies
.
set
(
'
amount
'
,
{
finalAmt
,
freeAmount
});
/* 跳转支付结果页面 */
this
.
$router
.
replace
({
name
:
`pay
${
type
}
`
,
...
...
@@ -572,6 +567,14 @@ export default {
},
getObjectKey
(
obj
)
{
return
Object
.
keys
(
obj
);
},
setAmount
()
{
const
finalAmt
=
IS_THIRD_PAY
(
this
.
payType
)
||
!
this
.
showCoupon
?
this
.
displayInfo
?.
orderAmt
||
'
0.00
'
:
(
this
.
displayInfo
?.
orderAmt
-
this
.
selectedCoupon
?.
faceValue
||
0
).
toFixed
(
2
);
const
freeAmount
=
this
.
showCoupon
?
this
.
selectedCoupon
?.
faceValue
||
'
0.00
'
:
'
0.00
'
;
cookies
.
set
(
'
amount
'
,
{
finalAmt
,
freeAmount
});
}
}
};
...
...
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