Commit 597a7296 authored by hongguangwu's avatar hongguangwu

MVP1.6.9-社保自动化日志

parent 25810a1f
......@@ -60,7 +60,7 @@ public class TSocialDeadlineInfo extends BaseEntity {
/**
* 省
*/
@ExcelAttribute(name = "省", isNotEmpty = true, errorInfo = "省不能为空", maxLength = 10)
@ExcelAttribute(name = "省", isNotEmpty = true, errorInfo = "省不能为空", maxLength = 10,isArea = true)
@NotBlank(message = "省不能为空")
@Length(max = 10, message = "省不能超过10个字符")
@ExcelProperty("省")
......@@ -69,7 +69,7 @@ public class TSocialDeadlineInfo extends BaseEntity {
/**
* 市
*/
@ExcelAttribute(name = "市", maxLength = 10)
@ExcelAttribute(name = "市", maxLength = 10,isArea = true, parentField = "province")
@Length(max = 10, message = "市不能超过10个字符")
@ExcelProperty("市")
@Schema(description = "市")
......@@ -78,7 +78,7 @@ public class TSocialDeadlineInfo extends BaseEntity {
/**
* 县
*/
@ExcelAttribute(name = "县", maxLength = 10)
@ExcelAttribute(name = "县", maxLength = 10,isArea = true, parentField = "city")
@Length(max = 10, message = "县不能超过10个字符")
@ExcelProperty("县")
@Schema(description = "县")
......
......@@ -170,7 +170,6 @@ public class TSocialSoldierPushServiceImpl extends ServiceImpl<TSocialSoldierMap
**/
@Override
public R<String> pushSoldier(List<String> dispatchIdList) {
log.info("dispatchIdList=" + dispatchIdList);
// 获取时间限制配置(获取 当月启用 的配置)
Map<String, TSocialDeadlineInfo> socialsetMap = tSocialDeadlineInfoService.getSocialSet();
......@@ -235,7 +234,6 @@ public class TSocialSoldierPushServiceImpl extends ServiceImpl<TSocialSoldierMap
ygsAddlistCopy.add(vo);
remark = "提交成功!";
} else {
ygsAddlist.remove(vo);
if (0 == canPushType) {
remark = "未到时间,不推送!";
} else {
......@@ -303,7 +301,6 @@ public class TSocialSoldierPushServiceImpl extends ServiceImpl<TSocialSoldierMap
ysdAddlistCopy.add(vo);
remark = "提交成功!";
} else {
ysdAddlist.remove(vo);
if (0 == canPushType) {
remark = "未到时间,不推送!";
} else {
......
......@@ -2386,7 +2386,7 @@ public class TSocialSoldierServiceImpl extends ServiceImpl<TSocialSoldierMapper,
if (leftRes.length>1) {
String result = null;
for (int i=1; i < leftRes.length; i++) {
if (leftRes[i].contains("】")) {
if (leftRes[i].contains(configTemp.getReplaceRight())) {
String[] rightRes = leftRes[i].split(configTemp.getReplaceRight());
result = rightRes[0];
break;
......
......@@ -589,6 +589,8 @@
<select id="getSocialSoldierYgsAll" resultMap="tSocialInfoMap">
SELECT
a.ID,
a.EMP_NAME,
a.SOCIAL_HOUSEHOLD_NAME,
a.EMP_IDCARD,
a.YGS_ADD_ID,
a.HANDLE_STATUS,
......@@ -610,6 +612,8 @@ if((sd.id is not null and NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE) or ( sd.id
<select id="getSocialSoldierYsdAll" resultMap="tSocialInfoMap">
SELECT
a.ID,
a.EMP_NAME,
a.SOCIAL_HOUSEHOLD_NAME,
a.EMP_IDCARD,
a.YSD_ADD_ID,
a.HANDLE_STATUS,
......@@ -631,6 +635,8 @@ if((sd.id is not null and NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE) or ( sd.id
<select id="getSocialSoldierYgsByAudit" resultMap="tSocialInfoMap">
SELECT
a.ID,
a.EMP_NAME,
a.SOCIAL_HOUSEHOLD_NAME,
a.EMP_IDCARD,
a.YGS_ADD_ID,
a.HANDLE_STATUS,
......@@ -649,6 +655,8 @@ if((sd.id is not null and NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE) or ( sd.id
<select id="getSocialSoldierYsdByAudit" resultMap="tSocialInfoMap">
SELECT
a.ID,
a.EMP_NAME,
a.SOCIAL_HOUSEHOLD_NAME,
a.EMP_IDCARD,
a.YSD_ADD_ID,
a.HANDLE_STATUS,
......@@ -667,6 +675,8 @@ if((sd.id is not null and NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE) or ( sd.id
<select id="getSocialSoldierByAddId" resultMap="tSocialInfoMap">
SELECT
a.ID,
a.EMP_NAME,
a.SOCIAL_HOUSEHOLD_NAME,
a.EMP_IDCARD,
a.YGS_ADD_ID,
a.YSD_ADD_ID,
......
......@@ -98,8 +98,7 @@
left join sys_area sc2 on sc2.id = s.SOCIAL_CITY
left join sys_area st1 on st1.id = h.SOCIAL_TOWN
left join sys_area st2 on st2.id = s.SOCIAL_TOWN
left join t_social_deadline_info sd on sd.MONTH = DATE_FORMAT(a.AUDIT_TIME,'%Y%m') and sd.STATUS = '0'
and sd.PROVINCE=s.SOCIAL_PROVINCE and sd.CITY=a.SOCIAL_CITY and ( (s.SOCIAL_TOWN is null and sd.TOWN is null) or (sd.TOWN=s.SOCIAL_TOWN))
<include refid="where_getSocialSoldier_base_handler"/>
and DATE_FORMAT(a.AUDIT_TIME,'%Y%m') = DATE_FORMAT(now(),'%Y%m')
</sql>
......@@ -115,7 +114,6 @@
if(ifnull(h.id,0) != '0',h.WORK_INJURY_HANDLE,s.WORK_INJURY_HANDLE) = '0' or
if(ifnull(h.id,0) != '0',h.UNEMPLOY_HANDLE,s.UNEMPLOY_HANDLE) = '0'
)
and (sd.id is null or NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE)
group by s.id
</select>
......@@ -149,7 +147,6 @@
if(ifnull(h.id,0) != '0',h.WORK_INJURY_HANDLE,s.WORK_INJURY_HANDLE) = '5' or
if(ifnull(h.id,0) != '0',h.UNEMPLOY_HANDLE,s.UNEMPLOY_HANDLE) = '5'
)
and (sd.id is null or NOW() <![CDATA[ <= ]]> sd.SOCIAL_END_DATE)
group by a.id
</select>
......@@ -164,7 +161,6 @@
if(ifnull(h.id,0) != '0',h.BIRTH_HANDLE,s.BIRTH_HANDLE) = '0' or
if(ifnull(h.id,0) != '0',h.BIGAILMENT_HANDLE,s.BIGAILMENT_HANDLE) = '0'
)
and (sd.id is null or NOW() <![CDATA[ <= ]]> sd.MEDICAL_END_DATE)
group by s.id
</select>
......@@ -179,7 +175,6 @@
if(ifnull(h.id,0) != '0',h.BIRTH_HANDLE,s.BIRTH_HANDLE) = '5' or
if(ifnull(h.id,0) != '0',h.BIGAILMENT_HANDLE,s.BIGAILMENT_HANDLE) = '5'
)
and (sd.id is null or NOW() <![CDATA[ <= ]]> sd.MEDICAL_END_DATE)
group by s.id
</select>
......@@ -288,60 +283,33 @@
<!-- 工资申报 -->
<select id="getSoldierSalaryByShenBaoList" resultType="com.yifu.cloud.plus.v1.yifu.social.vo.SocialSoldierSalaryShenBaoVo">
select
a.companyNo,a.companyName,a.empName,a.empIdCardType,a.empIdCard,a.fenZu,a.oldSalary
,a.newSalary,a.yangLao,a.shiYe,a.yiLiao,a.daBing,a.gongShang,a.shenBaoType,a.returnInfo
from (
select
'' companyNo,s.SOCIAL_HOUSEHOLD_NAME companyName,s.EMP_NAME empName,'201 - 居民身份证' empIdCardType
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao,s.UNIT_BIGAILMENT_CARDINAL daBing
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'1' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS in ('1','5','6','7') and d.type = '0' and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(now(),'%Y%m')
union all
select
'' companyNo,s.SOCIAL_HOUSEHOLD_NAME companyName,s.EMP_NAME empName,'201 - 居民身份证' empIdCardType
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao,s.UNIT_BIGAILMENT_CARDINAL daBing
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'2' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS = '3' and d.type = '1' and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(now(),'%Y%m')
) a GROUP BY a.empIdCard
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao,s.UNIT_BIGAILMENT_CARDINAL daBing
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'1' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
LEFT JOIN sys_house_hold_info h on h.id=s.SOCIAL_HOUSEHOLD
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS in ('1','5','6','7') and d.type = '0' and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(now(),'%Y%m')
and h.DEL_FLAG='0' and h.TYPE = '0' and h.AUTO_STATUS = '0'
GROUP BY s.EMP_IDCARD
</select>
<!-- 工资调整 -->
<select id="getSoldierSalaryByTiaoZhengList" resultType="com.yifu.cloud.plus.v1.yifu.social.vo.SocialSoldierSalaryTiaoZhengVo">
select
a.companyNo,a.companyName,a.shengXiaoYear,a.empName,a.empIdCardType,a.empIdCard,a.fenZu,a.oldSalary
,a.newSalary,a.yangLao,a.shiYe,a.yiLiao,a.gongShang,a.shenBaoType,a.returnInfo
from (
select
'' companyNo,s.SOCIAL_HOUSEHOLD_NAME companyName,'' shengXiaoYear,s.EMP_NAME empName,'201 - 居民身份证' empIdCardType
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'1' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS in ('1','5','6','7') and d.type = '0'
and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 YEAR),'%Y12')
union all
select
'' companyNo,s.SOCIAL_HOUSEHOLD_NAME companyName,'' shengXiaoYear,s.EMP_NAME empName,'201 - 居民身份证' empIdCardType
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'2' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS = '3' and d.type = '1'
and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 YEAR),'%Y12')
) a GROUP BY a.empIdCard
,s.EMP_IDCARD empIdCard,'' fenZu,'' oldSalary,s.RECORD_BASE newSalary,s.UNIT_PENSION_CARDINAL yangLao
,s.UNIT_UNEMPLOYMENT_CARDINAL shiYe,s.UNIT_MEDICAL_CARDINAL yiLiao
,s.UNIT_WORK_INJURY_CARDINAL gongShang,'按人申报' shenBaoType,'1' returnInfo
from t_social_info s
left join t_dispatch_info d on s.id=d.SOCIAL_ID
LEFT JOIN sys_house_hold_info h on h.id=s.SOCIAL_HOUSEHOLD
where DATE_FORMAT(d.CREATE_TIME,'%Y%m') = DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 MONTH),'%Y%m')
and s.HANDLE_STATUS in ('1','5','6','7') and d.type = '0'
and DATE_FORMAT(s.SOCIAL_START_DATE,'%Y%m') <![CDATA[ < ]]> DATE_FORMAT(DATE_SUB(NOW(),INTERVAL 1 YEAR),'%Y12')
and h.DEL_FLAG='0' and h.TYPE = '0' and h.AUTO_STATUS = '0'
GROUP BY s.EMP_IDCARD
</select>
<!-- 社保士兵实缴3张表查询1_合肥-社保费管理客户端-日常申报导出 -->
......
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