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
390e125e
Commit
390e125e
authored
May 09, 2020
by
孙亚楠
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'xgg-saas-platform' of gitlab.gongsibao.com:jiangyong/zhichan into xgg-saas-platform
parents
79b74139
d403a0fc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
1 deletions
+22
-1
xgg-saas-platform/app/base/controller/impl/saas/invoiceCtl.js
+17
-1
xgg-saas-platform/app/base/service/impl/trade/tradeSve.js
+5
-0
No files found.
xgg-saas-platform/app/base/controller/impl/saas/invoiceCtl.js
View file @
390e125e
...
...
@@ -142,8 +142,10 @@ class InvoiceCtl extends CtlBase {
let
businessmen
=
businessmenMap
[
creditCode
];
let
itemList
=
bmMap
[
creditCode
];
let
amount
=
0
;
let
data_ids
=
[];
for
(
let
item
of
itemList
)
{
amount
=
amount
+
Number
(
item
.
amt
||
0
);
data_ids
.
push
(
item
.
id
);
// TODO 总统测试
}
let
service_tax
=
parseFloat
((
Number
(
amount
)
*
Number
(
invoice_service_rate
)
/
100
).
toFixed
(
2
));
if
(
!
businessmen
.
is_bank
)
{
...
...
@@ -169,7 +171,8 @@ class InvoiceCtl extends CtlBase {
"unit"
:
""
,
"quantity"
:
""
,
"price"
:
""
,
"remark"
:
""
"remark"
:
""
,
"data_ids"
:
data_ids
.
join
(
","
)
// TODO 总统测试
});
}
...
...
@@ -303,6 +306,7 @@ class InvoiceCtl extends CtlBase {
mail_addr
:
this
.
trim
(
params
.
mail_addr
),
mail_mobile
:
this
.
trim
(
params
.
mail_mobile
),
mail_to
:
this
.
trim
(
params
.
mail_to
),
data_ids
:
this
.
trim
(
params
.
data_ids
),
// TODO 总统测试
personal_invoice_tax
:
system
.
y2f
(
invoice
.
personal_invoice_tax
),
additional_tax
:
system
.
y2f
(
invoice
.
additional_tax
),
...
...
@@ -325,6 +329,18 @@ class InvoiceCtl extends CtlBase {
status
:
"1060"
,
}
});
// TODO 总统测试 begin
if
(
rs
&&
rs
.
data
&&
rs
.
data
.
length
>
0
)
{
for
(
let
d
of
rs
.
data
)
{
console
.
log
(
d
.
id
,
d
.
data_ids
);
if
(
!
d
.
data_ids
)
{
continue
;
}
let
tradeIds
=
d
.
data_ids
.
split
(
","
);
await
this
.
tradeSve
.
updateInvoice
({
ids
:
tradeIds
,
saas_invoice_id
:
d
.
id
});
}
}
// TODO 总统测试 end
return
system
.
getResultSuccess
(
rs
);
}
catch
(
error
)
{
let
msg
=
error
.
message
;
...
...
xgg-saas-platform/app/base/service/impl/trade/tradeSve.js
View file @
390e125e
...
...
@@ -36,6 +36,11 @@ class TradeService extends ServiceBase {
return
rs
;
}
async
updateInvoice
(
params
)
{
let
rs
=
await
this
.
callms
(
"trade"
,
"updateItemInvoice"
,
params
);
return
rs
;
}
async
setMerchantIdsByName
(
params
)
{
let
merchantName
=
this
.
trim
(
params
.
merchant_name
);
if
(
merchantName
)
{
...
...
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