Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Y
yifu-mvp
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fangxinjiang
yifu-mvp
Commits
a4dab651
Commit
a4dab651
authored
Sep 05, 2022
by
hongguangwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
收入推送接口
parent
ce90551c
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
174 additions
and
216 deletions
+174
-216
EkpIncomeProperties.java
...fu.cloud.plus.v1/yifu/ekp/config/EkpIncomeProperties.java
+7
-3
EkpIncomeUtil.java
...a/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpIncomeUtil.java
+17
-3
EkpIncomeParam.java
...va/com/yifu/cloud/plus/v1/yifu/ekp/vo/EkpIncomeParam.java
+25
-194
ekpIncomeConfig.properties
...-common-ekp/src/main/resources/ekpIncomeConfig.properties
+6
-4
TSalaryStandardServiceImpl.java
.../yifu/salary/service/impl/TSalaryStandardServiceImpl.java
+8
-4
TSalaryAccountMapper.xml
...ry-biz/src/main/resources/mapper/TSalaryAccountMapper.xml
+2
-2
TIncome.java
...va/com/yifu/cloud/plus/v1/yifu/social/entity/TIncome.java
+13
-1
TIncomeServiceImpl.java
.../plus/v1/yifu/social/service/impl/TIncomeServiceImpl.java
+88
-2
TIncomeMapper.xml
...fu-social-biz/src/main/resources/mapper/TIncomeMapper.xml
+8
-3
No files found.
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/config/EkpIncomeProperties.java
View file @
a4dab651
...
@@ -20,13 +20,17 @@ public class EkpIncomeProperties {
...
@@ -20,13 +20,17 @@ public class EkpIncomeProperties {
String
url
;
String
url
;
String
fdModelId
;
String
fdModelId
Manage
;
String
fdFlowId
;
String
fdFlowIdManage
;
String
fdModelIdRisk
;
String
fdFlowIdRisk
;
String
docStatus
;
String
docStatus
;
String
L
oginName
;
String
l
oginName
;
String
docSubject
;
String
docSubject
;
...
...
yifu-common/yifu-common-ekp/src/main/java/com/yifu.cloud.plus.v1/yifu/ekp/util/EkpIncomeUtil.java
View file @
a4dab651
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
package
com
.
yifu
.
cloud
.
plus
.
v1
.
yifu
.
ekp
.
util
;
import
cn.hutool.json.JSONObject
;
import
cn.hutool.json.JSONObject
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpIncomeProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.config.EkpIncomeProperties
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.constant.EkpConstants
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpIncomeParam
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpIncomeParam
;
...
@@ -26,7 +27,15 @@ public class EkpIncomeUtil {
...
@@ -26,7 +27,15 @@ public class EkpIncomeUtil {
@Autowired
@Autowired
private
EkpIncomeProperties
ekpProperties
;
private
EkpIncomeProperties
ekpProperties
;
public
String
sendToEKP
(
EkpIncomeParam
param
)
{
/**
* @param param 内容传参
* @param type 1:管理费2:风险金
* @Description:
* @Author: hgw
* @Date: 2022/9/5 16:12
* @return: java.lang.String
**/
public
String
sendToEKP
(
EkpIncomeParam
param
,
String
type
)
{
log
.
info
(
"推送EKP开始--收入明细数据"
);
log
.
info
(
"推送EKP开始--收入明细数据"
);
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
RestTemplate
yourRestTemplate
=
new
RestTemplate
();
try
{
try
{
...
@@ -39,8 +48,13 @@ public class EkpIncomeUtil {
...
@@ -39,8 +48,13 @@ public class EkpIncomeUtil {
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docSubject"
,
ekpProperties
.
getDocSubject
());
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docCreator"
,
"{\"LoginName\":\"admin\"}"
);
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"docStatus"
,
ekpProperties
.
getDocStatus
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelId
());
if
(
CommonConstants
.
ONE_STRING
.
equals
(
type
))
{
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowId
());
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelIdManage
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowIdManage
());
}
else
{
wholeForm
.
add
(
"fdModelId"
,
ekpProperties
.
getFdModelIdRisk
());
wholeForm
.
add
(
"fdFlowId"
,
ekpProperties
.
getFdFlowIdRisk
());
}
wholeForm
.
add
(
"formValues"
,
formValues
);
wholeForm
.
add
(
"formValues"
,
formValues
);
HttpHeaders
headers
=
new
HttpHeaders
();
HttpHeaders
headers
=
new
HttpHeaders
();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
...
...
yifu-common/yifu-common-ekp/src/main/java/com/yifu/cloud/plus/v1/yifu/ekp/vo/EkpIncomeParam.java
View file @
a4dab651
...
@@ -12,241 +12,72 @@ import java.io.Serializable;
...
@@ -12,241 +12,72 @@ import java.io.Serializable;
*/
*/
@Data
@Data
public
class
EkpIncomeParam
implements
Serializable
{
public
class
EkpIncomeParam
implements
Serializable
{
/**
/**
* 项目编码
* 项目编码
**/
**/
private
String
fd_3adfe
df98ccba2
;
private
String
fd_3adfe
f5e5b9d34
;
/**
/**
* 项目名称
* 项目名称
**/
**/
private
String
fd_3adfe
df9d2bf
1c
;
private
String
fd_3adfe
f5eb669
1c
;
/**
/**
* 单号
* 单号
**/
**/
private
String
fd_3adfe
dfa4410aa
;
private
String
fd_3adfe
f7f5d2b52
;
/**
/**
* 客户编码
* 客户编码
**/
**/
private
String
fd_3adfe
dfacd65d6
;
private
String
fd_3adfe
f80202ab2
;
/**
/**
* 客户名称
* 客户名称
**/
**/
private
String
fd_3adfedfb174068
;
private
String
fd_3adfef7fc1c886
;
/**
* 姓名
**/
private
String
fd_3adfedfb5a68a2
;
/**
/**
*
身份证号
*
类型:单选(人,人次,比例,固定值,总额)
**/
**/
private
String
fd_3ad
fedfb8f76d4
;
private
String
fd_3ad
da3037e3bda
;
/**
/**
*
手机号
*
产生来源:单选(社保,工资,商险)
**/
**/
private
String
fd_3ad
fedfbd23ab8
;
private
String
fd_3ad
da320daef5a
;
/**
/**
*
银行卡号
*
姓名
**/
**/
private
String
fd_3adfe
dfcb17f1e
;
private
String
fd_3adfe
f948da848
;
/**
/**
*
开户行
*
身份证号
**/
**/
private
String
fd_3adfe
dfc453cc
4
;
private
String
fd_3adfe
f94dcdbb
4
;
/**
/**
*
工资
月份
*
生成
月份
**/
**/
private
String
fd_3a
dfee063acff0
;
private
String
fd_3a
e0c3032cffc8
;
/**
/**
* 结算月份
* 结算月份
**/
**/
private
String
fd_3adfee0690737c
;
private
String
fd_3ae0c3044e5958
;
/**
* 是否薪资扣税
**/
private
String
fd_3adfee01668666
;
/**
* 社保优先级
**/
private
String
fd_3adfedfed8bb28
;
/**
* 公积金优先级
**/
private
String
fd_3adfedff3a7430
;
/**
* 是否自有员工
**/
private
String
fd_3adfee0009d070
;
/**
* 年终奖扣税方案
**/
private
String
fd_3adfee01dea2fa
;
/**
* 应发工资
**/
private
String
fd_3adfee12cb8840
;
/**
* 个人代扣
**/
private
String
fd_3adfee1374ed7a
;
/**
* 单位社保
**/
private
String
fd_3adfee1e2b2f78
;
/**
/**
*
个人社保
*
管理费、风险金金额
**/
**/
private
String
fd_3adfee1e88723e
;
private
String
fd_3adfef963bae28
;
/**
* 单位公积金
**/
private
String
fd_3adfee1ee24680
;
/**
* 个人公积金
**/
private
String
fd_3adfee1f32fa24
;
/**
* 个税
**/
private
String
fd_3adfee1f901c46
;
/**
* 企业年金单位
**/
private
String
fd_3adfee1ff1ca6a
;
/**
* 企业年金个人
**/
private
String
fd_3adfee203f86b2
;
/**
* 实发合计
**/
private
String
fd_3adfee20fe5ba4
;
/**
/**
* 应收
* 应收
**/
**/
private
String
fd_3adfe
e21802434
;
private
String
fd_3adfe
fa3daae72
;
/**
/**
*
收入
结算状态
* 结算状态
**/
**/
private
String
fd_3adfe
e4ba5ad36
;
private
String
fd_3adfe
faaa3bbd0
;
/**
/**
* 收款状态
* 收款状态
**/
**/
private
String
fd_3adfe
e4c0c59e
e
;
private
String
fd_3adfe
faaef583
e
;
/**
/**
*
收入
结算单号
* 结算单号
**/
**/
private
String
fd_3a
dfee5dd14866
;
private
String
fd_3a
ead7204bb594
;
/**
/**
* 收款单号
* 收款单号
**/
**/
private
String
fd_3adfee5e3d1638
;
private
String
fd_3aeae59b70fe5a
;
/**
* 代扣费用应支出
**/
private
String
fd_3adfeeb34ea0ea
;
/**
* 代扣费用结算状态
**/
private
String
fd_3adfeededfb5a6
;
/**
* 代扣费用付款状态
**/
private
String
fd_3adfeed3a20598
;
/**
* 代扣费用结算单号
**/
private
String
fd_3aea30866d0c30
;
/**
* 代扣费用付款单号
**/
private
String
fd_3aea309696d32e
;
/**
* 个税应支出
**/
private
String
fd_3adfeec6db8766
;
/**
* 个税结算状态
**/
private
String
fd_3adfeef8ef38fc
;
/**
* 个税付款状态
**/
private
String
fd_3adfeedd08222c
;
/**
* 个税支出结算单号
**/
private
String
fd_3aeadede4cea84
;
/**
* 个税支出付款单号
**/
private
String
fd_3aeadee1cf1266
;
/**
* 实发合计应支出
**/
private
String
fd_3adfeec730ec44
;
/**
* 工资实发结算状态
**/
private
String
fd_3adfeef9440ab2
;
/**
* 实发合计付款状态
**/
private
String
fd_3adfeedd5f3cb2
;
/**
* 实发结算单号
**/
private
String
fd_3aeadf17522642
;
/**
* 实发付款单号
**/
private
String
fd_3aeadf17b7d03a
;
/**
* 企业年金单位应支出
**/
private
String
fd_3adfeec782070a
;
/**
* 企业年金单位应结算状态
**/
private
String
fd_3adfeef9b9fb3e
;
/**
* 企业年金单位付款状态
**/
private
String
fd_3adfeeddacf6d4
;
/**
* 年金单位结算单号
**/
private
String
fd_3aeadf182ef6a2
;
/**
* 年金单位付款单号
**/
private
String
fd_3aeadf1892fdb2
;
/**
* 企业年金个人应支出
**/
private
String
fd_3adfeec7ccdd1c
;
/**
* 企业年金个人结算状态
**/
private
String
fd_3adfeefa1eba32
;
/**
* 企业年金个人付款状态
**/
private
String
fd_3adfeede08d430
;
/**
* 年金个人结算单号
**/
private
String
fd_3aeadf191c62a0
;
/**
* 年金个人付款单号
**/
private
String
fd_3aeadf1992544c
;
/**
* 暂停发
**/
private
String
fd_3af9d49d165e90
;
/**
* 税务主体
**/
private
String
fd_3afab1895feea2
;
}
}
yifu-common/yifu-common-ekp/src/main/resources/ekpIncomeConfig.properties
View file @
a4dab651
ekp.url
=
http://119.96.227.251:8080/api/sys-modeling/appModelRestService/addModel
ekp.url
=
http://119.96.227.251.8080/api/sys-modeling/appModelRestService/addModel
ekp.fdModelId
=
181d7633ff8bc797276d0d3a54e80ad6
ekp.fdModelIdManage
=
181d76db26e419a88dba97b0c406689e
ekp.fdFlowId
=
182b40249c1bc940d7226b941c7a4183
ekp.fdFlowIdManage
=
182d3b6e522b2690119e70d4ff082136
ekp.fdModelIdRisk
=
181d76db26e419a88dba97b0c406689e
ekp.fdFlowIdRisk
=
182d3b6e522b2690119e70d4ff082136
ekp.docStatus
=
20
ekp.docStatus
=
20
ekp.
L
oginName
=
admin
ekp.
l
oginName
=
admin
ekp.docSubject
=
\u6536\u5165\u
660E
\u
7EC6
\u6570\u
636E
\u
63A5
\u
53E3
ekp.docSubject
=
\u6536\u5165\u
660E
\u
7EC6
\u6570\u
636E
\u
63A5
\u
53E3
yifu-salary/yifu-salary-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/salary/service/impl/TSalaryStandardServiceImpl.java
View file @
a4dab651
...
@@ -48,7 +48,6 @@ import com.yifu.cloud.plus.v1.yifu.salary.service.TSalaryStandardService;
...
@@ -48,7 +48,6 @@ import com.yifu.cloud.plus.v1.yifu.salary.service.TSalaryStandardService;
import
com.yifu.cloud.plus.v1.yifu.salary.util.SalaryConstants
;
import
com.yifu.cloud.plus.v1.yifu.salary.util.SalaryConstants
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryStandardExportVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryStandardExportVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryStandardSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryStandardSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncome
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncomeDetail
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncomeDetail
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeDetailReturnVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeDetailReturnVo
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
...
@@ -268,7 +267,8 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
...
@@ -268,7 +267,8 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
TIncomeDetailReturnVo
vo
=
detailR
.
getData
();
TIncomeDetailReturnVo
vo
=
detailR
.
getData
();
List
<
TIncomeDetail
>
detailList
=
vo
.
getDetailList
();
List
<
TIncomeDetail
>
detailList
=
vo
.
getDetailList
();
for
(
TIncomeDetail
incomeDetail
:
detailList
)
{
for
(
TIncomeDetail
incomeDetail
:
detailList
)
{
value
=
detailMap
.
get
(
incomeDetail
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getFeeType
());
value
=
detailMap
.
get
(
incomeDetail
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getFeeType
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getSourceType
());
if
(
Common
.
isEmpty
(
value
))
{
if
(
Common
.
isEmpty
(
value
))
{
value
=
CommonConstants
.
ZERO_INT
;
value
=
CommonConstants
.
ZERO_INT
;
}
}
...
@@ -277,7 +277,9 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
...
@@ -277,7 +277,9 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
}
else
{
}
else
{
value
--;
value
--;
}
}
detailMap
.
put
(
incomeDetail
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getFeeType
(),
value
);
detailMap
.
put
(
incomeDetail
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getFeeType
()
+
CommonConstants
.
DOWN_LINE_STRING
+
incomeDetail
.
getSourceType
(),
value
);
}
}
}
}
}
else
{
}
else
{
...
@@ -355,7 +357,9 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
...
@@ -355,7 +357,9 @@ public class TSalaryStandardServiceImpl extends ServiceImpl<TSalaryStandardMappe
if
(
salaryAccountList
!=
null
&&
!
salaryAccountList
.
isEmpty
())
{
if
(
salaryAccountList
!=
null
&&
!
salaryAccountList
.
isEmpty
())
{
BigDecimal
money
;
BigDecimal
money
;
for
(
TSalaryAccount
account
:
salaryAccountList
)
{
for
(
TSalaryAccount
account
:
salaryAccountList
)
{
value
=
detailMap
.
get
(
account
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
isManage
);
value
=
detailMap
.
get
(
account
.
getEmpIdcard
()
+
CommonConstants
.
DOWN_LINE_STRING
+
isManage
+
CommonConstants
.
DOWN_LINE_STRING
+
CommonConstants
.
FOUR_STRING
);
if
(
Common
.
isEmpty
(
value
)
||
value
==
0
)
{
if
(
Common
.
isEmpty
(
value
)
||
value
==
0
)
{
detail
=
new
TIncomeDetail
();
detail
=
new
TIncomeDetail
();
detail
.
setPayMonth
(
account
.
getSalaryMonth
());
detail
.
setPayMonth
(
account
.
getSalaryMonth
());
...
...
yifu-salary/yifu-salary-biz/src/main/resources/mapper/TSalaryAccountMapper.xml
View file @
a4dab651
...
@@ -455,8 +455,8 @@
...
@@ -455,8 +455,8 @@
,ifnull(a.EMP_PHONE,'') fd_3adfedfbd23ab8
,ifnull(a.EMP_PHONE,'') fd_3adfedfbd23ab8
,ifnull(a.BANK_NO,'') fd_3adfedfcb17f1e
,ifnull(a.BANK_NO,'') fd_3adfedfcb17f1e
,ifnull(a.BANK_NAME,'') fd_3adfedfc453cc4
,ifnull(a.BANK_NAME,'') fd_3adfedfc453cc4
,
ifnull(a.SALARY_MONTH,''
) fd_3adfee063acff0
,
concat(left(ifnull(a.SALARY_MONTH,'1970'),4),'-',right(ifnull(a.SALARY_MONTH,'02'),2)
) fd_3adfee063acff0
,
ifnull(a.SETTLEMENT_MONTH,''
) fd_3adfee0690737c
,
concat(left(ifnull(a.SETTLEMENT_MONTH,'1970'),4),'-',right(ifnull(a.SETTLEMENT_MONTH,'02'),2)
) fd_3adfee0690737c
,'是' fd_3adfee01668666
,'是' fd_3adfee01668666
,if(a.SOCIAL_PRIORITY='1','缴纳月','生成月') fd_3adfedfed8bb28
,if(a.SOCIAL_PRIORITY='1','缴纳月','生成月') fd_3adfedfed8bb28
,if(a.FUND_PRIORITY='1','缴纳月','生成月') fd_3adfedff3a7430
,if(a.FUND_PRIORITY='1','缴纳月','生成月') fd_3adfedff3a7430
...
...
yifu-social/yifu-social-api/src/main/java/com/yifu/cloud/plus/v1/yifu/social/entity/TIncome.java
View file @
a4dab651
...
@@ -183,6 +183,18 @@ public class TIncome {
...
@@ -183,6 +183,18 @@ public class TIncome {
@ExcelAttribute
(
name
=
"推送状态:0未推送1已推送"
,
maxLength
=
1
)
@ExcelAttribute
(
name
=
"推送状态:0未推送1已推送"
,
maxLength
=
1
)
@Length
(
max
=
1
,
message
=
"推送状态:0未推送1已推送不能超过1个字符"
)
@Length
(
max
=
1
,
message
=
"推送状态:0未推送1已推送不能超过1个字符"
)
@ExcelProperty
(
"推送状态:0未推送1已推送"
)
@ExcelProperty
(
"推送状态:0未推送1已推送"
)
private
String
pushStatus
;
private
String
sendStatus
;
@ExcelAttribute
(
name
=
"发送月份"
)
@ExcelProperty
(
"发送月份"
)
private
String
sendMonth
;
@ExcelAttribute
(
name
=
"发送时间"
)
@ExcelProperty
(
"发送时间"
)
private
Date
sendTime
;
@ExcelAttribute
(
name
=
"发送返回的EKPID"
)
@ExcelProperty
(
"发送返回的EKPID"
)
private
String
ekpId
;
}
}
yifu-social/yifu-social-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/social/service/impl/TIncomeServiceImpl.java
View file @
a4dab651
...
@@ -19,6 +19,7 @@ package com.yifu.cloud.plus.v1.yifu.social.service.impl;
...
@@ -19,6 +19,7 @@ package com.yifu.cloud.plus.v1.yifu.social.service.impl;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.bean.BeanUtil
;
import
com.alibaba.excel.EasyExcel
;
import
com.alibaba.excel.EasyExcel
;
import
com.alibaba.excel.ExcelWriter
;
import
com.alibaba.excel.ExcelWriter
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.alibaba.excel.context.AnalysisContext
;
import
com.alibaba.excel.context.AnalysisContext
;
import
com.alibaba.excel.read.listener.ReadListener
;
import
com.alibaba.excel.read.listener.ReadListener
;
import
com.alibaba.excel.read.metadata.holder.ReadRowHolder
;
import
com.alibaba.excel.read.metadata.holder.ReadRowHolder
;
...
@@ -29,6 +30,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...
@@ -29,6 +30,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
com.yifu.cloud.plus.v1.yifu.common.core.util.*
;
import
com.yifu.cloud.plus.v1.yifu.ekp.util.EkpIncomeUtil
;
import
com.yifu.cloud.plus.v1.yifu.ekp.vo.EkpIncomeParam
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncome
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncome
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncomeDetail
;
import
com.yifu.cloud.plus.v1.yifu.social.entity.TIncomeDetail
;
import
com.yifu.cloud.plus.v1.yifu.social.mapper.TIncomeMapper
;
import
com.yifu.cloud.plus.v1.yifu.social.mapper.TIncomeMapper
;
...
@@ -38,6 +41,7 @@ import com.yifu.cloud.plus.v1.yifu.social.vo.IncomeExportVo;
...
@@ -38,6 +41,7 @@ import com.yifu.cloud.plus.v1.yifu.social.vo.IncomeExportVo;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeSearchVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeVo
;
import
com.yifu.cloud.plus.v1.yifu.social.vo.TIncomeVo
;
import
lombok.extern.log4j.Log4j2
;
import
lombok.extern.log4j.Log4j2
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
@@ -61,6 +65,9 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -61,6 +65,9 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
@Autowired
@Autowired
private
TIncomeDetailService
tIncomeDetailService
;
private
TIncomeDetailService
tIncomeDetailService
;
@Autowired
private
EkpIncomeUtil
ekpIncomeUtil
;
/**
/**
* 收入明细表简单分页查询
* 收入明细表简单分页查询
*
*
...
@@ -269,8 +276,87 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
...
@@ -269,8 +276,87 @@ public class TIncomeServiceImpl extends ServiceImpl<TIncomeMapper, TIncome> impl
private
boolean
saveIncome
(
TIncomeDetail
tIncomeDetail
)
{
private
boolean
saveIncome
(
TIncomeDetail
tIncomeDetail
)
{
TIncome
income
=
new
TIncome
();
TIncome
income
=
new
TIncome
();
BeanUtil
.
copyProperties
(
tIncomeDetail
,
income
);
BeanUtil
.
copyProperties
(
tIncomeDetail
,
income
);
income
.
setPushStatus
(
CommonConstants
.
ZERO_STRING
);
income
.
setSendStatus
(
CommonConstants
.
ZERO_STRING
);
return
this
.
save
(
income
);
this
.
save
(
income
);
EkpIncomeParam
sendParam
=
new
EkpIncomeParam
();
this
.
copyToEkp
(
income
,
sendParam
);
String
sendBack
=
ekpIncomeUtil
.
sendToEKP
(
sendParam
,
income
.
getFeeType
());
income
.
setSendTime
(
new
Date
());
if
(
Common
.
isNotNull
(
sendBack
)
&&
sendBack
.
length
()
==
32
)
{
income
.
setSendStatus
(
CommonConstants
.
ONE_STRING
);
income
.
setSendMonth
(
DateUtil
.
addMonth
(
0
));
income
.
setEkpId
(
sendBack
);
}
return
this
.
updateById
(
income
);
}
/**
* @param income 收入
* @param sendParam 目标格式
* @Description: 转化格式,传到EKP
* @Author: hgw
* @Date: 2022/9/5 16:57
* @return: void
**/
private
void
copyToEkp
(
TIncome
income
,
EkpIncomeParam
sendParam
)
{
// 项目编码
sendParam
.
setFd_3adfef5e5b9d34
(
income
.
getDeptNo
());
// 项目名称
sendParam
.
setFd_3adfef5eb6691c
(
income
.
getDeptName
());
// 单号
sendParam
.
setFd_3adfef7f5d2b52
(
""
);
// 客户编码
sendParam
.
setFd_3adfef80202ab2
(
income
.
getUnitNo
());
// 客户名称
sendParam
.
setFd_3adfef7fc1c886
(
income
.
getUnitName
());
// 类型:单选(人,人次,比例,固定值,总额)
// feeMode收费方式:1按比例2金额-人数3金额-人次
if
(
CommonConstants
.
ONE_STRING
.
equals
(
income
.
getFeeMode
()))
{
sendParam
.
setFd_3adda3037e3bda
(
"比例"
);
}
else
if
(
CommonConstants
.
TWO_STRING
.
equals
(
income
.
getFeeMode
()))
{
sendParam
.
setFd_3adda3037e3bda
(
"人"
);
}
else
{
sendParam
.
setFd_3adda3037e3bda
(
"人次"
);
}
// 产生来源:单选(社保,工资,商险)
// sourceType1社保2公积金3商险4薪资
if
(
CommonConstants
.
THREE_STRING
.
equals
(
income
.
getSourceType
()))
{
sendParam
.
setFd_3adda320daef5a
(
"商险"
);
}
else
if
(
CommonConstants
.
FOUR_STRING
.
equals
(
income
.
getSourceType
()))
{
sendParam
.
setFd_3adda320daef5a
(
"工资"
);
}
else
{
sendParam
.
setFd_3adda320daef5a
(
"社保"
);
}
// 姓名
sendParam
.
setFd_3adfef948da848
(
income
.
getEmpName
());
// 身份证号
sendParam
.
setFd_3adfef94dcdbb4
(
income
.
getEmpIdcard
());
// 生成月份
if
(
Common
.
isEmpty
(
income
.
getCreateMonth
())
||
income
.
getCreateMonth
().
length
()
!=
6
)
{
sendParam
.
setFd_3ae0c3032cffc8
(
"1970-02"
);
}
else
{
sendParam
.
setFd_3ae0c3032cffc8
(
income
.
getCreateMonth
().
substring
(
0
,
4
)
+
CommonConstants
.
CENTER_SPLIT_LINE_STRING
+
income
.
getCreateMonth
().
substring
(
4
,
6
));
}
// 结算月份
if
(
Common
.
isEmpty
(
income
.
getPayMonth
())
||
income
.
getPayMonth
().
length
()
!=
6
)
{
sendParam
.
setFd_3ae0c3044e5958
(
"1970-02"
);
}
else
{
sendParam
.
setFd_3ae0c3044e5958
(
income
.
getPayMonth
().
substring
(
0
,
4
)
+
CommonConstants
.
CENTER_SPLIT_LINE_STRING
+
income
.
getPayMonth
().
substring
(
4
,
6
));
}
// 管理费、风险金金额
sendParam
.
setFd_3adfef963bae28
(
String
.
valueOf
(
income
.
getMoney
()));
// 应收
sendParam
.
setFd_3adfefa3daae72
(
String
.
valueOf
(
income
.
getMoney
()));
// 结算状态
sendParam
.
setFd_3adfefaaa3bbd0
(
"未结算"
);
// 收款状态
sendParam
.
setFd_3adfefaaef583e
(
"未收"
);
// 结算单号
sendParam
.
setFd_3aead7204bb594
(
""
);
// 收款单号
sendParam
.
setFd_3aeae59b70fe5a
(
""
);
}
}
/**
/**
...
...
yifu-social/yifu-social-biz/src/main/resources/mapper/TIncomeMapper.xml
View file @
a4dab651
...
@@ -42,8 +42,11 @@
...
@@ -42,8 +42,11 @@
<result
property=
"payMonth"
column=
"PAY_MONTH"
/>
<result
property=
"payMonth"
column=
"PAY_MONTH"
/>
<result
property=
"createTime"
column=
"CREATE_TIME"
/>
<result
property=
"createTime"
column=
"CREATE_TIME"
/>
<result
property=
"dataCreateMonth"
column=
"DATA_CREATE_MONTH"
/>
<result
property=
"dataCreateMonth"
column=
"DATA_CREATE_MONTH"
/>
<result
property=
"
push
Status"
column=
"PUSH_STATUS"
/>
<result
property=
"
send
Status"
column=
"PUSH_STATUS"
/>
<result
property=
"redData"
column=
"RED_DATA"
/>
<result
property=
"redData"
column=
"RED_DATA"
/>
<result
property=
"sendStatus"
column=
"SEND_STATUS"
/>
<result
property=
"sendTime"
column=
"SEND_TIME"
/>
<result
property=
"sendMonth"
column=
"SEND_MONTH"
/>
</resultMap>
</resultMap>
<resultMap
id=
"incomeExportMap"
type=
"com.yifu.cloud.plus.v1.yifu.social.vo.IncomeExportVo"
>
<resultMap
id=
"incomeExportMap"
type=
"com.yifu.cloud.plus.v1.yifu.social.vo.IncomeExportVo"
>
<result
property=
"empName"
column=
"EMP_NAME"
/>
<result
property=
"empName"
column=
"EMP_NAME"
/>
...
@@ -81,8 +84,10 @@
...
@@ -81,8 +84,10 @@
a.PAY_MONTH,
a.PAY_MONTH,
a.CREATE_TIME,
a.CREATE_TIME,
a.DATA_CREATE_MONTH,
a.DATA_CREATE_MONTH,
a.PUSH_STATUS,
a.RED_DATA,
a.RED_DATA
a.SEND_STATUS,
a.SEND_TIME,
a.SEND_MONTH
</sql>
</sql>
<sql
id=
"tIncome_where"
>
<sql
id=
"tIncome_where"
>
<if
test=
"tIncome != null"
>
<if
test=
"tIncome != null"
>
...
...
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