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
06242d1e
Commit
06242d1e
authored
Jan 10, 2020
by
王昆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
d14817f3
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
57 additions
and
11 deletions
+57
-11
xggsve-order/app/base/api/impl/op/action.js
+19
-7
xggsve-order/app/base/db/impl/product/oproductDao.js
+16
-0
xggsve-order/app/base/service/impl/order/oorderSve.js
+19
-0
xggsve-order/app/base/service/impl/product/oproductSve.js
+3
-4
No files found.
xggsve-order/app/base/api/impl/op/action.js
View file @
06242d1e
...
...
@@ -19,6 +19,7 @@ class ActionAPI extends APIBase {
this
.
oorderdeliverSve
=
system
.
getObject
(
"service.order.oorderdeliverSve"
);
this
.
oorderstatusSve
=
system
.
getObject
(
"service.order.oorderstatusSve"
);
this
.
oprocessSve
=
system
.
getObject
(
"service.product.oprocessSve"
);
this
.
oproductSve
=
system
.
getObject
(
"service.product.oproductSve"
);
}
/**
* 接口跳转
...
...
@@ -45,9 +46,15 @@ class ActionAPI extends APIBase {
async
handleRequest
(
action_process
,
action_type
,
action_body
)
{
var
opResult
=
null
;
try
{
switch
(
action_type
)
{
case
"orderInfo"
:
// 查订单信息
opResult
=
await
this
.
oorderSve
.
info
(
action_body
);
break
;
case
"orderInfoAll"
:
// 查订单信息
opResult
=
await
this
.
oorderSve
.
info
(
action_body
);
break
;
case
"orders"
:
//订单管理(平台)
opResult
=
await
this
.
oorderSve
.
orders
(
action_body
);
break
;
...
...
@@ -64,6 +71,11 @@ class ActionAPI extends APIBase {
opResult
=
await
this
.
oorderSve
.
addSourceOrder
(
action_body
);
break
;
case
"productDics"
:
// 查询产品字典
opResult
=
await
this
.
oproductSve
.
productDics
(
action_body
);
break
;
case
"allProcess"
:
// 查询业务进度
opResult
=
await
this
.
oprocessSve
.
allNames
(
action_body
);
break
;
...
...
@@ -94,12 +106,12 @@ class ActionAPI extends APIBase {
case
"allOrderList"
:
opResult
=
await
this
.
iborderSve
.
apiAllList
(
action_body
);
break
;
case
"orderInfo"
:
opResult
=
await
this
.
iborderSve
.
apiInfo
(
action_body
);
break
;
case
"orderInfoAll"
:
opResult
=
await
this
.
iborderSve
.
apiAllInfo
(
action_body
);
break
;
//
case "orderInfo":
//
opResult = await this.iborderSve.apiInfo(action_body);
//
break;
//
case "orderInfoAll":
//
opResult = await this.iborderSve.apiAllInfo(action_body);
//
break;
case
"byChannelOrderId"
:
opResult
=
await
this
.
iborderSve
.
apiByChannelOrderId
(
action_body
);
break
;
...
...
xggsve-order/app/base/db/impl/product/oproductDao.js
View file @
06242d1e
...
...
@@ -5,6 +5,22 @@ class OproductDao extends Dao {
super
(
Dao
.
getModelName
(
OproductDao
));
}
async
dics
(
params
)
{
let
sql
=
[];
sql
.
push
(
"SELECT"
);
sql
.
push
(
"id, `name`, `desc`, pid"
);
sql
.
push
(
"FROM o_product"
);
sql
.
push
(
"WHERE 1 = 1"
);
if
(
params
.
pid
)
{
sql
.
push
(
"AND pid = :pid"
);
}
if
(
params
.
hasOwnProperty
(
"is_choose"
))
{
sql
.
push
(
"AND is_choose = :is_choose"
);
}
return
this
.
customQuery
(
sql
.
join
(
" "
),
params
);
}
async
findListByPid
(
pid
)
{
let
sql
=
"SELECT * FROM o_product WHERE pid = :pid ORDER BY sort ASC"
;
return
await
this
.
customQuery
(
sql
,
{
pid
:
pid
});
...
...
xggsve-order/app/base/service/impl/order/oorderSve.js
View file @
06242d1e
...
...
@@ -82,6 +82,25 @@ class OorderService extends ServiceBase {
}
/**
* 查询订单信息
* @param {*} params
*/
async
info
(
params
)
{
let
row
=
await
this
.
dao
.
getById
(
params
.
id
);
if
(
!
row
)
{
return
system
.
getResult
(
null
,
"订单不存在"
);
}
await
this
.
dao
.
setRowCodeName
(
row
,
"status"
);
let
statusObj
=
await
this
.
getOrderProcessStatus
(
row
.
id
,
row
.
status
);
row
.
next_status
=
statusObj
.
next_status
||
{};
row
.
status_name
=
statusObj
.
name
;
this
.
handleDate
(
row
,
[
"created_at"
,
"assign_time"
],
null
,
-
8
);
return
system
.
getResultSuccess
(
row
);
}
/**
* 新建进度
* @param params
* @returns {Promise<void>}
...
...
xggsve-order/app/base/service/impl/product/oproductSve.js
View file @
06242d1e
...
...
@@ -9,10 +9,9 @@ class OproductService extends ServiceBase {
this
.
oproductprocessDao
=
system
.
getObject
(
"db.product.oproductprocessDao"
);
}
async
getProcessList
(
productPid
,
productIds
)
{
async
productDics
(
params
)
{
let
list
=
await
this
.
dao
.
dics
(
params
);
return
system
.
getResultSuccess
(
list
);
}
/**
...
...
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