Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zhichan
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
蒋勇
zhichan
Commits
3f5cbd63
Commit
3f5cbd63
authored
Jan 09, 2020
by
王昆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
97f621a6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
6 deletions
+16
-6
xggsve-order/app/base/service/impl/order/oorderstatusSve.js
+16
-6
No files found.
xggsve-order/app/base/service/impl/order/oorderstatusSve.js
View file @
3f5cbd63
...
...
@@ -36,17 +36,27 @@ class OorderstatusService extends ServiceBase {
return
system
.
getResult
(
null
,
`订单不存在`
);
}
let
_orderStatus
=
await
this
.
getOrderProcessStatus
(
_order
.
id
,
_order
.
status
);
let
nextStatus
=
JSON
.
parse
(
_orderStatus
.
next_status
);
var
statuses
=
[];
for
(
var
ns
of
nextStatus
)
{
statuses
.
push
(
ns
.
next_status
);
let
nextList
=
JSON
.
parse
(
_orderStatus
.
next_status
);
let
flag
=
false
;
let
nextNames
=
[];
for
(
var
nextItem
of
nextList
)
{
nextNames
.
push
(
nextItem
.
next_name
);
if
(
nextItem
.
next_status
==
params
.
status
)
{
flag
=
true
;
break
;
}
}
if
(
statuses
.
indexOf
(
params
.
status
)
==
-
1
)
{
return
system
.
getResult
(
null
,
`订单状态错误,下一订单状态应该是
${
nextStatus
.
next_name
}
`
);
if
(
!
flag
)
{
nextNames
=
nextNames
.
join
(
"或"
);
return
system
.
getResult
(
null
,
`订单状态错误,下一订单状态应该是
${
nextNames
}
`
);
}
let
nextStatus
=
await
this
.
oorderprocessDao
.
findByOrderIdAndStatus
(
_order
.
id
,
params
.
status
);
params
.
_order
=
_order
;
//调用对应的方法 TODO SOMETHING .....
// 调用func
// await this[nextStatus.func](params);
}
catch
(
error
)
{
...
...
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