Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
3603fa2c
Commit
3603fa2c
authored
Aug 22, 2019
by
wangshuo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
单集
parent
b3732e15
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
11 deletions
+9
-11
src/components/detail/single/index.js
+9
-11
No files found.
src/components/detail/single/index.js
View file @
3603fa2c
...
@@ -125,29 +125,27 @@ class Single extends Component {
...
@@ -125,29 +125,27 @@ class Single extends Component {
Toast
.
info
(
'支付成功'
,
2
);
Toast
.
info
(
'支付成功'
,
2
);
_this
.
intervalPayStatus
=
setInterval
(
function
()
{
_this
.
intervalPayStatus
=
setInterval
(
function
()
{
http
.
get
(
`
${
API
[
'base-api'
]}
/m/orderState/oid/
${
getParam
(
'oid'
)}
`
).
then
(
res
=>
{
http
.
get
(
`
${
API
[
'base-api'
]}
/m/orderState/oid/
${
getParam
(
'oid'
)}
`
).
then
(
res
=>
{
Toast
.
info
(
res
.
data
.
errno
,
2
);
if
(
res
.
data
.
errno
===
401
)
{
if
(
res
.
data
.
errno
===
401
)
{
clearInterval
(
_this
.
intervalPayStatus
);
clearInterval
(
_this
.
intervalPayStatus
);
_this
.
intervalPayStatus
=
null
;
_this
.
intervalPayStatus
=
null
;
// 获取课程类型
// 获取课程类型
http
.
get
(
`
${
API
[
'base-api'
]}
/class_order_status/
${
getParam
(
'oid'
)}
`
).
then
((
res
)
=>
{
http
.
get
(
`
${
API
[
'base-api'
]}
/class_order_status/
${
getParam
(
'oid'
)}
`
).
then
((
res
)
=>
{
Toast
.
info
(
res
.
data
.
data
.
errno
,
2
);
if
(
Number
(
res
.
data
.
data
.
errno
)
===
200
)
{
if
(
res
.
data
.
data
.
errno
==
'200'
)
{
// 正常购买单集成功
// 正常购买单集成功
this
.
setState
({
this
.
setState
({
status
:
6
status
:
6
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'201'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
201
)
{
// 0元参团
// 0元参团
this
.
setState
({
this
.
setState
({
status
:
4
status
:
4
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'202'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
202
)
{
// 0元购
// 0元购
this
.
setState
({
this
.
setState
({
status
:
3
status
:
3
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'203'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
203
)
{
// 三天内特价
// 三天内特价
this
.
setState
({
this
.
setState
({
nowPrice
:
res
.
data
.
data
.
data
.
now_price
,
nowPrice
:
res
.
data
.
data
.
data
.
now_price
,
...
@@ -194,23 +192,23 @@ class Single extends Component {
...
@@ -194,23 +192,23 @@ class Single extends Component {
clearInterval
(
_this
.
intervalPayStatus
);
clearInterval
(
_this
.
intervalPayStatus
);
_this
.
intervalPayStatus
=
null
;
_this
.
intervalPayStatus
=
null
;
// 获取课程类型
// 获取课程类型
http
.
get
(
`
${
API
[
'base-api'
]}
/
sys/orderS
tatus/
${
getParam
(
'oid'
)}
`
).
then
((
res
)
=>
{
http
.
get
(
`
${
API
[
'base-api'
]}
/
class_order_s
tatus/
${
getParam
(
'oid'
)}
`
).
then
((
res
)
=>
{
if
(
res
.
data
.
data
.
errno
==
'200'
)
{
if
(
Number
(
res
.
data
.
data
.
errno
)
===
200
)
{
// 正常购买单集成功
// 正常购买单集成功
this
.
setState
({
this
.
setState
({
status
:
6
status
:
6
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'201'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
201
)
{
// 0元参团
// 0元参团
this
.
setState
({
this
.
setState
({
status
:
4
status
:
4
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'202'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
202
)
{
// 0元购
// 0元购
this
.
setState
({
this
.
setState
({
status
:
3
status
:
3
})
})
}
else
if
(
res
.
data
.
data
.
errno
==
'203'
)
{
}
else
if
(
Number
(
res
.
data
.
data
.
errno
)
===
203
)
{
// 三天内特价
// 三天内特价
this
.
setState
({
this
.
setState
({
nowPrice
:
res
.
data
.
data
.
data
.
now_price
,
nowPrice
:
res
.
data
.
data
.
data
.
now_price
,
...
...
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