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
77c11b9b
Commit
77c11b9b
authored
May 08, 2020
by
王昆
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
fb66d275
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
3 deletions
+14
-3
xgg-saas-merchant/app/base/service/impl/trade/tradeSve.js
+14
-3
No files found.
xgg-saas-merchant/app/base/service/impl/trade/tradeSve.js
View file @
77c11b9b
...
...
@@ -73,6 +73,8 @@ class TradeService extends ServiceBase {
let
result
=
await
this
.
countAmt
(
itemList
,
info
,
params
);
let
current
=
new
Date
();
let
projectName
;
for
(
let
item
of
itemList
)
{
item
.
amt
=
system
.
y2f
(
item
.
actual_amt
);
item
.
actual_amt
=
system
.
y2f
(
item
.
actual_amt
);
...
...
@@ -85,6 +87,7 @@ class TradeService extends ServiceBase {
item
.
trade_status
=
"00"
;
item
.
trade_desc
=
"商户自行交易"
;
}
projectName
=
item
.
project_name
;
}
let
out_trade_no
=
await
this
.
redisClient
.
genrateId
(
"gsb_out_trade_no"
);
...
...
@@ -102,6 +105,7 @@ class TradeService extends ServiceBase {
acc_type
:
params
.
acc_type
,
order_file
:
params
.
fileUrl
,
order_type
:
order_type
,
project_name
:
projectName
,
// 付款凭证信息
pay_voucher
:
""
,
pay_bank_account
:
main
.
bank_account
,
...
...
@@ -224,6 +228,9 @@ class TradeService extends ServiceBase {
return
system
.
getResult
(
null
,
"打款文件无数据"
)
}
let
rows
=
sheet
.
data
;
let
projectRow
=
rows
[
2
];
let
projectName
=
projectRow
.
length
>=
2
?
projectRow
[
1
]
:
""
;
let
itemList
=
[];
for
(
let
idx
=
6
;
idx
<
rows
.
length
;
idx
++
)
{
var
data
=
{
...
...
@@ -232,20 +239,24 @@ class TradeService extends ServiceBase {
let
cells
=
rows
[
idx
];
let
cellLength
=
cells
.
length
;
if
(
cellLength
==
0
)
{
continue
;
}
if
(
cellLength
<
7
)
{
if
(
cellLength
<
6
)
{
data
.
errors
.
push
(
"缺少数据, 列数不全"
);
continue
;
}
data
.
project_name
=
projectName
;
data
.
acc_name
=
this
.
trim
(
cells
[
1
]);
data
.
credit_code
=
this
.
trim
(
cells
[
2
]).
toUpperCase
();
data
.
acc_no
=
this
.
trim
(
cells
[
3
]);
data
.
open_bank
=
this
.
trim
(
cells
[
4
]);
data
.
amt
=
this
.
trim
(
cells
[
5
]);
data
.
remark
=
this
.
trim
(
cells
[
6
]);
if
(
cellLength
==
6
)
{
data
.
remark
=
""
;
}
else
{
data
.
remark
=
this
.
trim
(
cells
[
6
]);
}
itemList
.
push
(
data
);
}
...
...
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