Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mongo-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
mongo-ui
Commits
c52cd9c4
Commit
c52cd9c4
authored
Aug 17, 2020
by
郭志伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: #MANGO-9:问题联调
parent
4b79f53d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
10 deletions
+7
-10
index.vue
src/views/Consultant/Buy/index.vue
+7
-10
No files found.
src/views/Consultant/Buy/index.vue
View file @
c52cd9c4
...
@@ -230,10 +230,10 @@ export default {
...
@@ -230,10 +230,10 @@ export default {
this
.
generateOrder
();
this
.
generateOrder
();
}
}
},
},
updateRemain
(
isBuy
=
false
)
{
updateRemain
()
{
let
historyRemain
=
localStorage
.
get
(
"
historyRemain
"
);
let
historyRemain
=
localStorage
.
get
(
"
historyRemain
"
);
if
(
historyRemain
&&
+
historyRemain
>
100
)
{
if
(
historyRemain
&&
+
historyRemain
>
100
)
{
isBuy
&&
historyRemain
--
;
historyRemain
--
;
}
else
{
}
else
{
historyRemain
=
Math
.
floor
(
Math
.
random
()
*
(
200
-
100
)
+
100
);
historyRemain
=
Math
.
floor
(
Math
.
random
()
*
(
200
-
100
)
+
100
);
}
}
...
@@ -244,20 +244,17 @@ export default {
...
@@ -244,20 +244,17 @@ export default {
const
res
=
await
create
();
const
res
=
await
create
();
if
(
res
)
{
if
(
res
)
{
this
.
consultantOrderNo
=
res
.
consultantOrderNo
;
this
.
consultantOrderNo
=
res
.
consultantOrderNo
;
this
.
updateRemain
(
true
);
this
.
updateRemain
();
this
.
goPay
();
this
.
goPay
();
}
}
},
},
async
goPay
()
{
async
goPay
()
{
const
res
=
await
goPay
({
tradeType
:
this
.
tradeType
});
const
res
=
await
goPay
({
tradeType
:
this
.
tradeType
});
if
(
res
)
{
if
(
res
)
{
payByWay
(
this
.
tradeType
,
res
.
payInfo
).
then
(
res
=>
{
payByWay
(
this
.
tradeType
,
res
.
payInfo
).
then
(()
=>
{
if
(
res
===
"
ok
"
)
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
$parent
.
getOrderInfo
();
// this.$router.push("/consultant/success");
},
1000
);
this
.
$parent
.
getOrderInfo
();
},
2000
);
}
});
});
}
}
}
}
...
...
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