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
6412071d
Commit
6412071d
authored
Apr 09, 2020
by
zhaoxiqing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gsb
parent
a767ed72
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
12 deletions
+13
-12
xggsve-invoice/app/base/api/impl/op/action.js
+1
-1
xggsve-invoice/app/base/service/impl/invoice/saasinvoiceSve.js
+3
-2
xggsve-invoice/app/base/utils/dictionary.js
+9
-9
No files found.
xggsve-invoice/app/base/api/impl/op/action.js
View file @
6412071d
...
...
@@ -60,7 +60,7 @@ class ActionAPI extends APIBase {
opResult
=
await
this
.
saasinvoiceSve
.
merchantinvoicePage
(
action_body
);
break
;
case
"platforminvoicePage"
:
//发票列表(平台)
opResult
=
await
this
.
saasinvoiceSve
.
merchant
invoicePage
(
action_body
);
opResult
=
await
this
.
saasinvoiceSve
.
platform
invoicePage
(
action_body
);
break
;
...
...
xggsve-invoice/app/base/service/impl/invoice/saasinvoiceSve.js
View file @
6412071d
...
...
@@ -8,8 +8,7 @@ const moment = require('moment');
class
SaasinvoiceService
extends
ServiceBase
{
constructor
()
{
super
(
"invoice"
,
ServiceBase
.
getDaoName
(
SaasinvoiceService
));
this
.
dictionary
=
system
.
getObject
(
"util.dictionary"
);
}
async
merchantinvoicePage
(
params
)
{
...
...
@@ -27,6 +26,7 @@ class SaasinvoiceService extends ServiceBase {
for
(
var
item
of
list
)
{
this
.
handleDate
(
item
,
[
'updated_at'
,
'created_at'
],
'YYYY-MM-DD HH:mm:ss'
);
this
.
handleDate
(
item
,
[
'invoice_time'
],
'YYYY-MM-DD'
);
this
.
dictionary
.
setRowName
(
"SAAS_INTEVOICE"
,
item
,[
"owner_type"
,
"fee_type"
,
"invoice_type"
,
"invoice_join"
]);
}
}
return
system
.
getResultSuccess
({
count
:
total
,
rows
:
list
});
...
...
@@ -47,6 +47,7 @@ class SaasinvoiceService extends ServiceBase {
for
(
var
item
of
list
)
{
this
.
handleDate
(
item
,
[
'updated_at'
,
'created_at'
],
'YYYY-MM-DD HH:mm:ss'
);
this
.
handleDate
(
item
,
[
'invoice_time'
],
'YYYY-MM-DD'
);
this
.
dictionary
.
setRowName
(
"SAAS_INTEVOICE"
,
item
,[
"owner_type"
,
"fee_type"
,
"invoice_type"
,
"invoice_join"
]);
}
}
return
system
.
getResultSuccess
({
count
:
total
,
rows
:
list
});
...
...
xggsve-invoice/app/base/utils/dictionary.js
View file @
6412071d
...
...
@@ -2,14 +2,15 @@ const system = require("../system");
class
Dictionary
{
constructor
()
{
// 交易字典
this
.
SAAS_INTEVOICE
=
{
order_type
:
{
"00"
:
"未设置"
,
"10"
:
"平台交易"
,
"20"
:
"商户交易"
},
acc_type
:
{
"00"
:
"银行"
,
"01"
:
"支付宝"
,
"02"
:
"微信"
},
owner_type
:
{
"00"
:
"商户发票"
,
"10"
:
"平台发票"
},
fee_type
:
{
"00"
:
"注册订单费用"
,
"10"
:
"平台转账费用"
,
"20"
:
"商户转账费用"
},
invoice_type
:{
"10"
:
"增值税专用发票"
,
"20"
:
" 增值税普通发票"
,
"30"
:
"普通发票"
},
invoice_join
:
{
"10"
:
"记账联"
,
"20"
:
"发票联"
,
"30"
:
"抵扣联"
,
"40"
:
"销售方次"
},
};
this
.
SAAS_INVOICE_APPLY
=
{
trade_status
:
{
"00"
:
"成功"
,
"01"
:
"待处理"
,
"02"
:
"失败"
}
}
//
this.SAAS_INVOICE_APPLY = {
//
trade_status: {"00": "成功", "01": "待处理", "02": "失败"}
//
}
}
getDict
(
module
,
field
)
{
...
...
@@ -17,13 +18,12 @@ class Dictionary {
}
// setRowName("ORDER", order, ["order_type", "acc_type", "trade_mode", "trade_status", "check_status"]);
setRowName
(
module
,
row
,
fields
,
concat
)
{
setRowName
(
module
,
row
,
fields
)
{
if
(
!
module
||
!
row
||
!
fields
||
fields
.
length
==
0
)
{
return
;
}
concat
=
concat
||
"_"
;
for
(
let
field
of
fields
)
{
row
[
field
+
concat
+
"name"
]
=
this
.
getDict
(
module
,
field
)[
row
[
field
]
||
""
]
||
""
;
row
[
field
]
=
this
.
getDict
(
module
,
field
)[
row
[
field
]
||
""
]
||
""
;
}
}
...
...
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