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
f3106832
Commit
f3106832
authored
Apr 08, 2020
by
王昆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
e4e20790
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
6 deletions
+14
-6
xgg-saas-merchant/app/base/service/impl/saas/merchantSve.js
+4
-0
xgg-saas-merchant/app/base/service/impl/trade/tradeSve.js
+9
-5
xgg-saas-merchant/app/base/system.js
+1
-1
No files found.
xgg-saas-merchant/app/base/service/impl/saas/merchantSve.js
View file @
f3106832
...
...
@@ -121,6 +121,9 @@ class MerchantService extends ServiceBase {
if
(
row
.
main_id
)
{
mainIds
.
push
(
row
.
main_id
);
}
if
(
row
.
main_id_trade
)
{
mainIds
.
push
(
row
.
main_id_trade
);
}
}
if
(
mainIds
.
length
==
0
)
{
return
;
...
...
@@ -129,6 +132,7 @@ class MerchantService extends ServiceBase {
map
=
map
.
data
||
{};
for
(
let
row
of
rows
)
{
row
.
main
=
map
[
row
.
main_id
]
||
{};
row
.
main_trade
=
map
[
row
.
main_id_trade
]
||
{};
}
}
...
...
xgg-saas-merchant/app/base/service/impl/trade/tradeSve.js
View file @
f3106832
...
...
@@ -64,7 +64,7 @@ class TradeService extends ServiceBase {
// 获取商户签约信息
let
info
=
await
this
.
merchantSve
.
signInfo
({
id
:
params
.
saas_merchant_id
})
||
{};
info
=
info
.
data
||
{};
let
main
=
info
.
main
||
{};
let
main
=
info
.
main
_trade
||
{};
// 计算预计付款金额
let
result
=
await
this
.
countAmt
(
itemList
,
info
);
...
...
@@ -114,17 +114,21 @@ class TradeService extends ServiceBase {
}
async
parseItems
(
params
)
{
// 获取商户签约信息
let
info
=
await
this
.
merchantSve
.
signInfo
({
id
:
params
.
saas_merchant_id
})
||
{};
info
=
info
.
data
||
{};
if
(
!
info
.
main_trade
||
!
info
.
main_trade
.
id
)
{
return
system
.
getResult
(
null
,
"签约时未设置转账交易签约主体,请联系平台进行设置"
);
}
// 读取excel
let
itemList
=
await
this
.
readItems
(
params
.
fileUrl
,
params
.
fileName
);
// 验证字段
let
error
=
await
this
.
checkItemList
(
itemList
);
// 获取商户签约信息
let
info
=
await
this
.
merchantSve
.
signInfo
({
id
:
params
.
saas_merchant_id
})
||
{};
// 计算预计付款基恩
let
result
=
await
this
.
countAmt
(
itemList
,
(
info
.
data
||
{})
);
let
result
=
await
this
.
countAmt
(
itemList
,
info
);
// 封装返回对象
result
.
error
=
error
;
...
...
xgg-saas-merchant/app/base/system.js
View file @
f3106832
...
...
@@ -190,7 +190,7 @@ class System {
uc
:
dev
+
":3106"
+
path
,
// 交易
trade
:
local
+
":3107"
+
path
,
trade
:
dev
+
":3107"
+
path
,
}
}
else
{
var
odomain
=
"http://123.57.217.203"
...
...
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