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
dae5f1e6
Commit
dae5f1e6
authored
Nov 12, 2020
by
wangyong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: (servicebill) 磐农项目 服务单字段切换
parent
db107f24
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
20 deletions
+20
-20
icp-deliver/app/base/db/models/agriculture/servicebill.js
+8
-6
icp-deliver/app/base/service/impl/agriculture/servicebillSve.js
+10
-12
icp-deliver/app/base/utils/ydzClient.js
+2
-2
No files found.
icp-deliver/app/base/db/models/agriculture/servicebill.js
View file @
dae5f1e6
...
@@ -65,13 +65,15 @@ module.exports = (db, DataTypes) => {
...
@@ -65,13 +65,15 @@ module.exports = (db, DataTypes) => {
}
}
// companyInfo: { // 对象
// companyInfo: { // 对象
// co
mpany
Name // 公司名称
// co
rp
Name // 公司名称
// taxpayerType // 纳税性质 NORMAL_TAXPAYER 一般纳税人; SMALL_TAXPAYER 小规模纳税人
// taxpayerType
Enum
// 纳税性质 NORMAL_TAXPAYER 一般纳税人; SMALL_TAXPAYER 小规模纳税人
// acctgSystemId // 会计制度 10001=2013 小企业会计准 则;10002=2007 企业会计准 则;10003=民间非营利组织会 计制度; 10004=工会会计制度
// acctgSystemId // 会计制度 10001=2013 小企业会计准 则;10002=2007 企业会计准 则;10003=民间非营利组织会 计制度; 10004=工会会计制度
// companyForm // 企业形式 1 公司; 2 合伙企业; 3 个独; 4 个体工商户
// enterpriseFormEnum // 企业形式:CORPORATION 公司;PARTNERSHIP_OR_SOLE 合伙企业/个独/个体工商户;OTHERS 其他企业"
// industry //所属行业
// taxIndustryId //所属行业
// taxpayerNumber // 税号
// taxNo // 税号
// companyArea // 公司区域
// taxiationArea // 公司区域
// serviceTypeEnum //"服务类型:枚举型,包括ACCOUTING-记账服务、INDUSTRY_COMMERCE-工商服务、BOTH-记账与工商服务"
// taxClaimMethodEnum //申报方式:TAX_DECLARATION-税款申报;ZERO_DECLARATION-零申报;
// }
// }
},
{
},
{
...
...
icp-deliver/app/base/service/impl/agriculture/servicebillSve.js
View file @
dae5f1e6
...
@@ -5,7 +5,6 @@ const System = require("../../../system");
...
@@ -5,7 +5,6 @@ const System = require("../../../system");
const
moment
=
require
(
"moment"
);
const
moment
=
require
(
"moment"
);
const
TOQFT
=
require
(
"../../../utils/toQft"
);
const
TOQFT
=
require
(
"../../../utils/toQft"
);
class
ServicebillService
extends
ServiceBase
{
class
ServicebillService
extends
ServiceBase
{
constructor
()
{
constructor
()
{
super
(
"agriculture"
,
ServiceBase
.
getDaoName
(
ServicebillService
));
super
(
"agriculture"
,
ServiceBase
.
getDaoName
(
ServicebillService
));
...
@@ -58,7 +57,7 @@ class ServicebillService extends ServiceBase {
...
@@ -58,7 +57,7 @@ class ServicebillService extends ServiceBase {
const
res
=
await
this
.
dao
.
update
(
obj
);
const
res
=
await
this
.
dao
.
update
(
obj
);
const
findOne
=
await
this
.
dao
.
findOne
({
id
:
obj
.
id
});
const
findOne
=
await
this
.
dao
.
findOne
({
id
:
obj
.
id
});
let
backData
=
{};
let
backData
=
{};
if
(
findOne
)
{
if
(
res
&&
findOne
)
{
backData
.
bizId
=
findOne
.
bizId
;
backData
.
bizId
=
findOne
.
bizId
;
backData
.
auditResult
=
findOne
.
status
;
backData
.
auditResult
=
findOne
.
status
;
backData
.
orderNo
=
findOne
.
orderNo
;
backData
.
orderNo
=
findOne
.
orderNo
;
...
@@ -94,20 +93,19 @@ class ServicebillService extends ServiceBase {
...
@@ -94,20 +93,19 @@ class ServicebillService extends ServiceBase {
mappingYDZ
(
findService
)
{
mappingYDZ
(
findService
)
{
let
setData
=
{
let
setData
=
{
custName
:
findService
.
contactName
,
//客户名称
custName
:
findService
.
contactName
,
//客户名称
corpName
:
findService
.
companyInfo
.
companyName
,
//企业名称
corpName
:
findService
.
companyInfo
.
corpName
,
//企业名称
taxiationArea
:
findService
.
companyInfo
.
companyArea
,
//报税地区
serviceTypeEnum
:
findService
.
companyInfo
.
serviceTypeEnum
,
// 服务类型:枚举型,包括ACCOUTING-记账服务、INDUSTRY_COMMERCE-工商服务、BOTH-记账与工商服务。
taxIndustryId
:
findService
.
companyInfo
.
industry
,
//行业
// taxiationArea: findService.companyInfo.taxiationArea, //报税地区
serviceTypeEnum
:
"ACCOUTING"
,
// 服务类型:枚举型,包括ACCOUTING-记账服务、INDUSTRY_COMMERCE-工商服务、BOTH-记账与工商服务。
taxIndustryId
:
findService
.
companyInfo
.
taxIndustryId
,
//行业
taxNo
:
findService
.
companyInfo
.
taxpayerNumber
,
// 税号
taxNo
:
findService
.
companyInfo
.
taxNo
,
// 税号
taxClaimMethodEnum
:
findService
.
companyInfo
.
taxClaimMethodEnum
,
//申报方式:TAX_DECLARATION-税款申报;ZERO_DECLARATION-零申报;
accountantEmployeeId
:
findService
.
accountantAgentAccountId
,
//所属会计 易代账ID
accountantEmployeeId
:
findService
.
accountantAgentAccountId
,
//所属会计 易代账ID
taxClaimMethodEnum
:
"TAX_DECLARATION"
,
//申报方式:TAX_DECLARATION-税款申报;ZERO_DECLARATION-零申报;
isBuild
:
true
,
//是否建账
isBuild
:
true
,
//是否建账
accountBook
:
{
accountBook
:
{
name
:
findService
.
companyInfo
.
co
mpany
Name
,
//账套名称
name
:
findService
.
companyInfo
.
co
rp
Name
,
//账套名称
acctgSystemId
:
findService
.
companyInfo
.
acctgSystemId
,
//会计制度;包括:10001=2013小企业会计准则;10002=2007企业会计准则;10003=民间非营利组织会计制度;10004=工会会计制度
acctgSystemId
:
findService
.
companyInfo
.
acctgSystemId
,
//会计制度;包括:10001=2013小企业会计准则;10002=2007企业会计准则;10003=民间非营利组织会计制度;10004=工会会计制度
openingPeriod
:
`
${
moment
().
year
()}
+
${
moment
().
month
()}
`
,
//开账期间 当年当月,格式是 “YYYYMM”
openingPeriod
:
`
${
moment
().
year
()}${
moment
().
month
()}
`
,
//开账期间 当年当月,格式是 “YYYYMM”
taxpayerTypeEnum
:
findService
.
taxpayerType
,
//纳税性质,枚举包括:NORMAL_TAXPAYER=一般纳税人;SMALL_TAXPAYER=小规模纳税人
taxpayerTypeEnum
:
findService
.
companyInfo
.
taxpayerTypeEnum
,
//纳税性质,枚举包括:NORMAL_TAXPAYER=一般纳税人;SMALL_TAXPAYER=小规模纳税人
acctgTransGroupEnum
:
'ACCTG'
//凭证类别,枚举包括:ACCTG=记账凭证等;RECEIPT_PAYMENT_TRANSFER=收付转凭证
}
}
}
}
return
setData
;
return
setData
;
...
...
icp-deliver/app/base/utils/ydzClient.js
View file @
dae5f1e6
...
@@ -63,7 +63,7 @@ const postRequest = async(url, data, headers = {}) => {
...
@@ -63,7 +63,7 @@ const postRequest = async(url, data, headers = {}) => {
}
}
}
catch
(
err
)
{
}
catch
(
err
)
{
console
.
log
(
`
${
url
}
: 返回错误信息 ------- `
);
console
.
log
(
`
${
url
}
: 返回错误信息 ------- `
);
console
.
log
(
err
)
console
.
log
(
err
)
;
throw
(
err
)
throw
(
err
)
}
}
}
}
...
@@ -79,7 +79,7 @@ const getRequest = async(url, data, headers = {}) => {
...
@@ -79,7 +79,7 @@ const getRequest = async(url, data, headers = {}) => {
return
res
.
data
;
return
res
.
data
;
}
catch
(
err
)
{
}
catch
(
err
)
{
console
.
log
(
`
${
url
}
: 返回错误信息 ------- `
);
console
.
log
(
`
${
url
}
: 返回错误信息 ------- `
);
console
.
log
(
err
)
console
.
log
(
err
)
;
throw
(
err
)
throw
(
err
)
}
}
}
}
...
...
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