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
4ad6faf6
Commit
4ad6faf6
authored
Apr 03, 2020
by
王昆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
fed88914
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
5 deletions
+21
-5
xggsve-trade/app/base/api/impl/op/action.js
+3
-0
xggsve-trade/app/base/db/impl/trade/storderitemDao.js
+8
-5
xggsve-trade/app/base/service/impl/trade/storderSve.js
+10
-0
No files found.
xggsve-trade/app/base/api/impl/op/action.js
View file @
4ad6faf6
...
...
@@ -44,6 +44,9 @@ class ActionAPI extends APIBase {
case
"orderAdd"
:
opResult
=
await
this
.
storderSve
.
saveOrder
(
action_body
);
break
;
case
"orderInfo"
:
opResult
=
await
this
.
storderSve
.
info
(
action_body
);
break
;
case
"orderPay"
:
opResult
=
await
this
.
storderSve
.
pay
(
action_body
);
break
;
...
...
xggsve-trade/app/base/db/impl/trade/storderitemDao.js
View file @
4ad6faf6
...
...
@@ -8,7 +8,7 @@ class StOrderItemDao extends Dao {
if
(
!
ids
||
ids
.
length
==
0
)
{
return
[];
}
var
sql
=
[];
let
sql
=
[];
sql
.
push
(
"SELECT"
);
sql
.
push
(
attrs
||
"*"
);
sql
.
push
(
"FROM"
);
...
...
@@ -20,11 +20,11 @@ class StOrderItemDao extends Dao {
}
async
mapByIds
(
ids
,
attrs
)
{
var
result
=
{};
let
result
=
{};
if
(
!
ids
||
ids
.
length
==
0
)
{
return
result
;
}
var
list
=
await
this
.
findListByIds
(
ids
,
attrs
);
let
list
=
await
this
.
findListByIds
(
ids
,
attrs
);
if
(
!
list
||
list
.
length
==
0
)
{
return
result
;
}
...
...
@@ -48,7 +48,7 @@ class StOrderItemDao extends Dao {
this
.
setCondition
(
sql
,
params
);
var
list
=
await
this
.
customQuery
(
sql
.
join
(
" "
),
params
);
let
list
=
await
this
.
customQuery
(
sql
.
join
(
" "
),
params
);
if
(
!
list
||
list
.
length
==
0
)
{
return
0
;
}
...
...
@@ -58,7 +58,7 @@ class StOrderItemDao extends Dao {
async
listByCondition
(
params
)
{
params
.
startRow
=
Number
(
params
.
startRow
||
0
);
params
.
pageSize
=
Number
(
params
.
pageSize
||
10
);
var
sql
=
[];
let
sql
=
[];
sql
.
push
(
"SELECT"
);
sql
.
push
(
params
.
attrs
||
"*"
);
sql
.
push
(
"FROM"
);
...
...
@@ -82,6 +82,9 @@ class StOrderItemDao extends Dao {
if
(
params
.
saas_merchant_id
)
{
sql
.
push
(
"AND saas_merchant_id = :saas_merchant_id"
);
}
if
(
params
.
order_id
)
{
sql
.
push
(
"AND order_id = :order_id"
);
}
if
(
params
.
saas_merchant_ids
)
{
sql
.
push
(
"AND saas_merchant_id IN (:saas_merchant_ids)"
);
}
...
...
xggsve-trade/app/base/service/impl/trade/storderSve.js
View file @
4ad6faf6
...
...
@@ -37,6 +37,16 @@ class StOrderService extends ServiceBase {
return
system
.
getResultSuccess
(
page
);
}
async
info
(
params
)
{
let
order
=
await
this
.
dao
.
getById
(
params
.
id
);
if
(
!
order
)
{
return
system
.
getResult
(
null
,
"订单不存在"
);
}
this
.
handleDate
(
order
,
[
"created_at"
],
null
);
this
.
dictionary
.
setRowName
(
"ORDER"
,
order
,
[
"order_type"
,
"acc_type"
,
"trade_mode"
,
"trade_status"
,
"check_status"
]);
return
system
.
getResultSuccess
(
order
);
}
// 保存打款信息
async
saveOrder
(
order
)
{
if
(
!
order
)
{
...
...
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