Commit a268cfa0 authored by fangxinjiang's avatar fangxinjiang

Merge remote-tracking branch 'origin/MVP1.6.10' into MVP1.6.10

parents 959f9289 e3ebc638
......@@ -159,7 +159,7 @@
and a.EMP_NAME = #{completeMonitorInfoVo.empName}
</if>
<if test="completeMonitorInfoVo.phone != null and completeMonitorInfoVo.phone.trim() != ''">
and a.EMP_PHONE = #{completeMonitorInfoVo.phone}
and b.EMP_PHONE = #{completeMonitorInfoVo.phone}
</if>
<if test="completeMonitorInfoVo.isComplete != null and completeMonitorInfoVo.isComplete.trim() != ''">
and a.IS_COMPLETE = #{completeMonitorInfoVo.isComplete}
......
......@@ -17,6 +17,9 @@
package com.yifu.cloud.plus.v1.yifu.common.core.constant;
import java.math.BigDecimal;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* @author lengleng
......@@ -622,4 +625,8 @@ public interface CommonConstants {
Integer TEN_INTEGER = 10;
Integer ELEVEN_INTEGER =11;
List<String> socialStatus = Stream.of("3","4","6","7","9","11","12").collect(Collectors.toList());
List<String> socialInfoStatus = Stream.of("1","5","7").collect(Collectors.toList());
}
......@@ -14,7 +14,6 @@ import com.icbc.api.response.JftApiB2bpayTransqueryResponseV1;
import com.icbc.api.response.JftApiPayB2bpayGenpreorderResponseV1;
import com.icbc.api.response.MybankEnterpriseAccountQuerybankinfoResponseV1;
import com.icbc.api.response.MybankEnterpriseTradeQhisdResponseV1;
import com.icbc.api.utils.IcbcSignature;
import com.yifu.cloud.plus.v1.ekp.config.EkpEntryProperties;
import com.yifu.cloud.plus.v1.ekp.config.IcbcConfigProperties;
import com.yifu.cloud.plus.v1.ekp.entity.EkpSocialInfo;
......@@ -118,6 +117,10 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
public R getIcbcTransactionFlowNew() throws IcbcApiException {
//从9月12号开始执行定时任务
if (DateUtil.getCurrentDateString().compareTo("2024-09-12") < 0 ) {
return R.ok();
}
DefaultIcbcClient client = new DefaultIcbcClient(icbcConfigProperties.getAppId(), IcbcConstants.SIGN_TYPE_CA_SM_ICBC,
icbcConfigProperties.getAppPrivateKey(), IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null,
null, null, icbcConfigProperties.getCaSm(), null);
......@@ -177,6 +180,10 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
public R getIcbcTransactionFlowYesterdayInner() throws IcbcApiException {
//从9月13号开始执行定时任务
if (DateUtil.getCurrentDateString().compareTo("2024-09-13") <0 ) {
return R.ok();
}
DefaultIcbcClient client = new DefaultIcbcClient(icbcConfigProperties.getAppId(), IcbcConstants.SIGN_TYPE_CA_SM_ICBC,
icbcConfigProperties.getAppPrivateKey(), IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null,
null, null, icbcConfigProperties.getCaSm(), null);
......@@ -273,12 +280,6 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
}
public R querybankinfo() {
String ca_sm_path = "D:/icbcFile/ahwx_y_1302.cer";
String ca_sm_icbc_path = "D:/icbcFile/API_GATEWAY_ICBC_SM_REAL.cer";
String ca_sm = IcbcSignature.getCAInfoStr(ca_sm_path);
String ca_sm_icbc = IcbcSignature.getCAInfoStr(ca_sm_icbc_path);
String privateKey = "4d931f6ad4331158fcc4dea23f0d71393328146e40b5f63f197b9f6ad3732f44";
......@@ -287,8 +288,8 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
// DefaultIcbcClient client = new DefaultIcbcClient("11000000000000019038", IcbcConstants.SIGN_TYPE_CA_SM_ICBC,privateKey, APIGW_PUBLIC_KEY);
DefaultIcbcClient client = new DefaultIcbcClient("11000000000000019038", IcbcConstants.SIGN_TYPE_CA_SM_ICBC, privateKey,
IcbcConstants.CHARSET_UTF8, IcbcConstants.FORMAT_JSON, null,
null, null, ca_sm, null);
client.setIcbc_ca(ca_sm_icbc);
null, null, icbcConfigProperties.getCaSm(), null);
client.setIcbc_ca(icbcConfigProperties.getCaSmIcbc());
try {
MybankEnterpriseAccountQuerybankinfoRequestV1.MybankEnterpriseAccountQuerybankinfoRequestBizV1 bizContent =
new MybankEnterpriseAccountQuerybankinfoRequestV1.MybankEnterpriseAccountQuerybankinfoRequestBizV1();
......@@ -299,7 +300,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
bizContent.setTranTime("103231001");
bizContent.setLanguage("zh_CN");
bizContent.setfSeqNo("AHWX"+ System.currentTimeMillis());
bizContent.setCardNo("6222620250010165293");
bizContent.setCardNo("6217752510002149161");
request.setServiceUrl("https://gw.open.icbc.com.cn/api/mybank/enterprise/account/querybankinfo/V1");
request.setBizContent(bizContent);
MybankEnterpriseAccountQuerybankinfoResponseV1 response = client.execute(request);
......@@ -433,7 +434,7 @@ public class IcbcTransactionFlowQueryServiceImpl extends ServiceImpl<EkpSocialIn
pushParam.setFd_recipName(entry.getRecipName());
pushParam.setFd_recipAccountNo(entry.getRecipAccountNo());
pushParam.setFd_recipBkName(entry.getRecipBkName());
pushParam.setFd_date(entry.getBusiDate() + " " + entry.getBusiTime());
pushParam.setFd_date(entry.getBusiDate() + " " + entry.getBusiTime().replace(".",":"));
pushParam.setFd_receiveBkName(bankName);
pushParam.setFd_receiveBkNo(bankNo);
pushParam.setFd_remark(entry.getSummary());
......
......@@ -7932,6 +7932,12 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
if (Common.isNotNull(idstr)){
searchVo.setIdList(Common.getList(idstr));
}
YifuUser user = SecurityUtils.getUser();
if ("许瑞玲".equals(user.getNickname()) || "1".equals(user.getId())) {
searchVo.setCreateBy(null);
} else {
searchVo.setCreateBy(user.getId());
}
long count = noPageCountDiy(searchVo);
ServletOutputStream out = null;
try {
......@@ -8040,7 +8046,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
@Override
public R<Integer> getUserInsuranceMessageWarnCount(String userName) {
InsuranceSearchVo searchVo = new InsuranceSearchVo();
searchVo.setCreateName(userName);
searchVo.setCreateBy(SecurityUtils.getUser().getId());
searchVo.setExpireIgnoreFlag(CommonConstants.ONE_STRING);
return R.ok(baseMapper.noPageCountDiy(searchVo));
}
......
......@@ -77,7 +77,7 @@
a.DIE_DISABLE_QUOTA,
a.DEPT_ID,
a.POLICY_NO,
if(a.POLICY_END >= curdate(),0,1) IS_OVERDUE,
IF( a.POLICY_END >= curdate(), 0, 1 ) IS_OVERDUE,
a.REMARK,
a.CREATE_BY,
a.DELETE_FLAG,
......@@ -89,10 +89,11 @@
a.CREATE_USER_DEPT_NAME
FROM
t_insurance_detail a
WHERE
a.id IN (
INNER JOIN (
SELECT
l.id
h.endTime,
max( l.POLICY_START ) POLICY_START,
l.EMP_IDCARD_NO
FROM
(
SELECT
......@@ -101,8 +102,10 @@
FROM
t_insurance_detail b
WHERE
b.POLICY_START >= date_sub( date_add( curdate(), INTERVAL 1 DAY ), INTERVAL 1 YEAR )
b.POLICY_START BETWEEN date_sub( date_add( curdate(), INTERVAL 1 DAY ), INTERVAL 1 YEAR )
AND curdate()
AND b.IS_EFFECT = 0
AND b.DELETE_FLAG = '0'
AND NOT EXISTS (
SELECT
1
......@@ -111,8 +114,11 @@
WHERE
ea.POLICY_START >= date_sub( date_add( curdate(), INTERVAL 1 DAY ), INTERVAL 1 YEAR )
AND ea.IS_EFFECT = 0
AND ea.DELETE_FLAG = '0'
AND ea.POLICY_END >= date_add( curdate(), INTERVAL 1 MONTH )
AND ea.EMP_IDCARD_NO = b.EMP_IDCARD_NO
AND ea.INSURANCE_COMPANY_NAME = b.INSURANCE_COMPANY_NAME
AND ea.INSURANCE_TYPE_NAME = b.INSURANCE_TYPE_NAME
)
GROUP BY
b.EMP_IDCARD_NO,
......@@ -120,9 +126,20 @@
b.INSURANCE_TYPE_NAME
) h
INNER JOIN t_insurance_detail l ON h.EMP_IDCARD_NO = l.EMP_IDCARD_NO
AND l.DELETE_FLAG = '0'
AND h.endTime = l.POLICY_END
AND l.POLICY_START BETWEEN date_sub( date_add( curdate(), INTERVAL 1 DAY ), INTERVAL 1 YEAR )
AND curdate()
WHERE
l.EXPIRE_IGNORE_FLAG = '1'
)
GROUP BY
l.EMP_IDCARD_NO,
l.INSURANCE_COMPANY_NAME,
l.INSURANCE_TYPE_NAME,
l.POLICY_END
) ll ON ll.EMP_IDCARD_NO = a.EMP_IDCARD_NO
AND ll.POLICY_START = a.POLICY_START
AND ll.endTime = a.POLICY_END
where a.DELETE_FLAG = '0'
</select>
</mapper>
......@@ -68,4 +68,8 @@ public class TSalaryAccountSumVo {
private BigDecimal pdeduction;
@ExcelProperty("免个税个人代扣合计")
private BigDecimal exemptionPersionTax;
@ExcelProperty("工资月份")
private String salaryMonth;
@ExcelProperty("发薪人数")
private Integer num;
}
......@@ -1373,6 +1373,8 @@
,sum(ifnull(enterpriseAnnuityUnit.SALARY_MONEY,0)) enterprise_Annuity_Unit
,sum(ifnull(pdeduction.SALARY_MONEY,0)) pdeduction
,sum(ifnull(exemptionPersionTax.SALARY_MONEY,0)) exemptionPersionTax
,a.SALARY_MONTH salaryMonth
,count(1) num
from t_salary_account a
left join t_salary_account_item annualBonus on annualBonus.SALARY_ACCOUNT_ID = a.id and annualBonus.JAVA_FIED_NAME = 'annualBonus'
left join t_salary_account_item enterpriseAnnuity on enterpriseAnnuity.SALARY_ACCOUNT_ID = a.id and enterpriseAnnuity.JAVA_FIED_NAME='enterpriseAnnuity'
......
......@@ -227,6 +227,7 @@ public class TSocialFundInfo extends BaseEntity {
@Schema(description = "缴纳地-县" )
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("缴纳地-县" )
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String socialTown;
/**
* 公积金户
......
......@@ -138,6 +138,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
private final TDispatchSocialFundInfoService infoService;
private final SysHouseHoldInfoMapper houseHoldInfoMapper;
/**
* 派单信息记录表简单分页查询
*
......@@ -3940,6 +3942,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
boolean auditFlag = true;
boolean partSuccess = false;
TDispatchSocialFundInfo socialFundInfo;
SysHouseHoldInfo info;
for (TDispatchInfo dis : disList) {
auditFlag = true;
if (CommonConstants.ZERO_STRING.equals(typeSub)) {
......@@ -4022,6 +4025,15 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
// 社保办理状态补充判断:
this.setSocialHandleStatus(handleStatus, socialType, flag, socialInfo, dis,sf, isAutoHandle);
info = houseHoldInfoMapper.selectOne(Wrappers.<SysHouseHoldInfo>query().lambda()
.eq(SysHouseHoldInfo::getType,CommonConstants.ZERO_STRING)
.eq(SysHouseHoldInfo::getName,dis.getSocialHouseholdName())
.last(CommonConstants.LAST_ONE_SQL));
sf.setSocialHouseholdName(dis.getSocialHouseholdName());
sf.setSocialHousehold(info == null ? "" : info.getId());
sf.setSocialProvince(dis.getSocialProvince());
sf.setSocialCity(dis.getSocialCity());
sf.setSocialTown(dis.getSocialTown());
socialMapper.updateById(socialInfo);
dis.setSocialHandleRemark(ServiceUtil.ifNullToEmpty(handleRemark));
......@@ -4116,6 +4128,16 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isNotNull(socialInfo) && Common.isNotNull(socialInfo.getId())) {
// 社保办理状态补充判断:
this.setSocialHandleStatus(handleStatus, socialType, flag, socialInfo, dis,sf, isAutoHandle);
info = houseHoldInfoMapper.selectOne(Wrappers.<SysHouseHoldInfo>query().lambda()
.eq(SysHouseHoldInfo::getType,CommonConstants.ZERO_STRING)
.eq(SysHouseHoldInfo::getName,dis.getSocialHouseholdName())
.last(CommonConstants.LAST_ONE_SQL));
sf.setSocialHouseholdName(dis.getSocialHouseholdName());
sf.setSocialHousehold(info == null ? "" : info.getId());
sf.setSocialProvince(dis.getSocialProvince());
sf.setSocialCity(dis.getSocialCity());
sf.setSocialTown(dis.getSocialTown());
socialInfo.setReduceHandleUser(user.getId());
socialInfo.setReduceHandleTime(now);
//社保派减办理成功才变更社保的办理状态
......@@ -4249,6 +4271,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
auditInfoMapper.insert(auditInfo);
}
baseMapper.updateById(dis);
//v1.8.9更新社保公积金缴纳地和户数据
socialFundMapper.updateById(sf);
//派减的申请审核完更新社保公积金查询快照表
if (CommonConstants.ONE_STRING.equals(dis.getType())) {
......
......@@ -1154,8 +1154,10 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
List<TSocialInfo> socialist;
TSettleDomain domain;
List<TSocialFundInfo> socialInfoList = socialFundInfoMapper.selectList(Wrappers.<TSocialFundInfo>query().lambda()
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD)));
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD))
.in(TSocialFundInfo::getSocialStatus,CommonConstants.socialStatus));
//已存在的社保数据
HashMap<String, TSocialFundInfo> socialMap = new HashMap<>();
......@@ -1213,7 +1215,9 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
socialist = socialInfoMapper.selectList(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard())
.eq(TSocialInfo::getSocialProvince, infoVo.getSocialProvince())
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity()));
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity())
.in(TSocialInfo::getHandleStatus,CommonConstants.socialInfoStatus)
);
if (CollectionUtils.isNotEmpty(socialist)) {
for (TSocialInfo socialInfo1 : socialist) {
if ((Common.isEmpty(infoVo.getSocialTown()) || (Common.isNotNull(infoVo.getSocialTown()) &&
......@@ -1485,6 +1489,7 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
if (Common.isEmpty(tSocialInfo)) {
tSocialInfo = socialInfoMapper.selectOne(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard()).groupBy(TSocialInfo::getCreateTime)
.in(TSocialInfo::getHandleStatus,CommonConstants.socialInfoStatus)
.last(CommonConstants.LAST_ONE_SQL));
}
......@@ -2820,7 +2825,8 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
TSettleDomain domain;
List<TSocialFundInfo> socialInfoList = socialFundInfoMapper.selectList(Wrappers.<TSocialFundInfo>query().lambda()
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD)));
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD))
.in(TSocialFundInfo::getSocialStatus,CommonConstants.socialStatus));
//已存在的社保数据
HashMap<String, TSocialFundInfo> socialMap = new HashMap<>();
......@@ -2874,7 +2880,9 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
socialist = socialInfoMapper.selectList(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard())
.eq(TSocialInfo::getSocialProvince, infoVo.getSocialProvince().toString())
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity().toString()));
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity().toString())
.in(TSocialInfo::getHandleStatus,CommonConstants.socialInfoStatus)
);
if (CollectionUtils.isNotEmpty(socialist)) {
for (TSocialInfo socialInfo1 : socialist) {
if ((Common.isEmpty(infoVo.getSocialTown()) || (Common.isNotNull(infoVo.getSocialTown()) &&
......@@ -3093,6 +3101,7 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
if (Common.isEmpty(tSocialInfo)) {
tSocialInfo = socialInfoMapper.selectOne(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard()).groupBy(TSocialInfo::getCreateTime)
.in(TSocialInfo::getHandleStatus,CommonConstants.socialInfoStatus)
.last(CommonConstants.LAST_ONE_SQL));
}
......@@ -3286,7 +3295,8 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
TSettleDomain domain;
List<TSocialFundInfo> socialInfoList = socialFundInfoMapper.selectList(Wrappers.<TSocialFundInfo>query().lambda()
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD)));
.in(TSocialFundInfo::getEmpIdcard, Common.listObjectToStrList(list, ExcelAttributeConstants.EMPIDCARD))
.in(TSocialFundInfo::getSocialStatus, CommonConstants.socialStatus));
//已存在的社保数据
HashMap<String, TSocialFundInfo> socialMap = new HashMap<>();
......@@ -3342,7 +3352,8 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
socialist = socialInfoMapper.selectList(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard())
.eq(TSocialInfo::getSocialProvince, infoVo.getSocialProvince().toString())
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity().toString()));
.eq(TSocialInfo::getSocialCity, infoVo.getSocialCity().toString())
.in(TSocialInfo::getHandleStatus, CommonConstants.socialInfoStatus));
if (CollectionUtils.isNotEmpty(socialist)) {
for (TSocialInfo socialInfo1 : socialist) {
if ((Common.isEmpty(infoVo.getSocialTown()) || (Common.isNotNull(infoVo.getSocialTown()) &&
......@@ -3369,6 +3380,7 @@ public class TPaymentInfoServiceImpl extends ServiceImpl<TPaymentInfoMapper, TPa
if (Common.isEmpty(tSocialInfo)) {
tSocialInfo = socialInfoMapper.selectOne(Wrappers.<TSocialInfo>query().lambda()
.eq(TSocialInfo::getEmpIdcard, infoVo.getEmpIdcard()).groupBy(TSocialInfo::getCreateTime)
.in(TSocialInfo::getHandleStatus, CommonConstants.socialInfoStatus)
.last(CommonConstants.LAST_ONE_SQL));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment