Commit bf64c509 authored by hongguangwu's avatar hongguangwu

Merge branch 'develop' into MVP1.7.2

# Conflicts:
#	yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/controller/IcbcTransactionFlowIssueController.java
#	yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/IcbcTransactionFlowIssueService.java
#	yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/IcbcTransactionFlowQueryService.java
#	yifu-ekp/yifu-ekp-biz/src/main/java/com/yifu/cloud/plus/v1/ekp/service/impl/IcbcTransactionFlowIssueServiceImpl.java
parents 1e1b4ff2 1805cdb5
...@@ -455,6 +455,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -455,6 +455,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行总行不能超过50个字符") @Length(max = 50, message = "开户行总行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行总行") @ExcelProperty("开户行总行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankName; private String bankName;
/** /**
* 开户行省 * 开户行省
...@@ -462,6 +463,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -462,6 +463,7 @@ public class TEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行省",isArea = true) @ExcelAttribute(name = "开户行省",isArea = true)
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行省") @ExcelProperty("开户行省")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankProvince; private String bankProvince;
/** /**
* 开户行市 * 开户行市
...@@ -469,6 +471,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -469,6 +471,7 @@ public class TEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince") @ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行市") @ExcelProperty("开户行市")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankCity; private String bankCity;
/** /**
* 开户行支行 * 开户行支行
...@@ -477,6 +480,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -477,6 +480,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行支行不能超过50个字符") @Length(max = 50, message = "开户行支行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行支行") @ExcelProperty("开户行支行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankSubName; private String bankSubName;
/** /**
* 银行卡号 * 银行卡号
...@@ -485,6 +489,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -485,6 +489,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "银行卡号不能超过50个字符") @Length(max = 50, message = "银行卡号不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("银行卡号") @ExcelProperty("银行卡号")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankNo; private String bankNo;
/** /**
* 计税月份 * 计税月份
...@@ -493,6 +498,7 @@ public class TEmployeeInfo extends BaseEntity { ...@@ -493,6 +498,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 6, message = "计税月份不能超过6个字符") @Length(max = 6, message = "计税月份不能超过6个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("计税月份") @ExcelProperty("计税月份")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String taxMonth; private String taxMonth;
/** /**
* 通信地址省 * 通信地址省
......
...@@ -420,6 +420,7 @@ public class TPreEmployeeInfo extends BaseEntity { ...@@ -420,6 +420,7 @@ public class TPreEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行总行不能超过50个字符") @Length(max = 50, message = "开户行总行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行总行") @ExcelProperty("开户行总行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankName; private String bankName;
/** /**
* 开户行省 * 开户行省
...@@ -427,6 +428,7 @@ public class TPreEmployeeInfo extends BaseEntity { ...@@ -427,6 +428,7 @@ public class TPreEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行省",isArea = true) @ExcelAttribute(name = "开户行省",isArea = true)
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行省") @ExcelProperty("开户行省")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankProvince; private String bankProvince;
/** /**
* 开户行市 * 开户行市
...@@ -434,6 +436,7 @@ public class TPreEmployeeInfo extends BaseEntity { ...@@ -434,6 +436,7 @@ public class TPreEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince") @ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行市") @ExcelProperty("开户行市")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankCity; private String bankCity;
/** /**
* 开户行支行 * 开户行支行
...@@ -442,6 +445,7 @@ public class TPreEmployeeInfo extends BaseEntity { ...@@ -442,6 +445,7 @@ public class TPreEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行支行不能超过50个字符") @Length(max = 50, message = "开户行支行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行支行") @ExcelProperty("开户行支行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankSubName; private String bankSubName;
/** /**
* 银行卡号 * 银行卡号
...@@ -450,6 +454,7 @@ public class TPreEmployeeInfo extends BaseEntity { ...@@ -450,6 +454,7 @@ public class TPreEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "银行卡号不能超过50个字符") @Length(max = 50, message = "银行卡号不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("银行卡号") @ExcelProperty("银行卡号")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankNo; private String bankNo;
/** /**
* 计税月份 * 计税月份
......
...@@ -220,6 +220,17 @@ public class EmpContractDispatchVo implements Serializable { ...@@ -220,6 +220,17 @@ public class EmpContractDispatchVo implements Serializable {
@Schema(description = "客户名称", name = "subjectUnit") @Schema(description = "客户名称", name = "subjectUnit")
private String subjectUnit; private String subjectUnit;
/**
* 试用期(单位月)
*/
@Length(max = 4, message = "试用期 不能超过4 个字符" )
@ExcelAttribute(name = "试用期", maxLength = 32)
@Schema(description = "试用期" )
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("试用期" )
@ExcelIgnore
private String tryPeriod;
/** /**
* 合同年限 * 合同年限
*/ */
......
...@@ -100,28 +100,28 @@ public class TCompleteMonitorVo implements Serializable { ...@@ -100,28 +100,28 @@ public class TCompleteMonitorVo implements Serializable {
private String completePer; private String completePer;
/** /**
* 6月及后入职人数 * 10月及后入职人数
*/ */
@ExcelAttribute(name = "6月及后入职人数") @ExcelAttribute(name = "10月及后入职人数")
@Schema(description = "6月及后入职人数") @Schema(description = "10月及后入职人数")
@ExcelProperty("6月及后入职人数") @ExcelProperty("10月及后入职人数")
private Integer afterEmployment; private Integer afterEmployment;
/** /**
* 6月及后入职信息是否完整 * 10月及后入职信息是否完整
*/ */
@Length(max = 1, message = "6月及后入职信息是否完整 不能超过1 个字符") @Length(max = 1, message = "10月及后入职信息是否完整 不能超过1 个字符")
@ExcelAttribute(name = "6月及后入职信息是否完整", maxLength = 1, readConverterExp = "0=是,1=否") @ExcelAttribute(name = "10月及后入职信息是否完整", maxLength = 1, readConverterExp = "0=是,1=否")
@Schema(description = "6月及后入职信息是否完整") @Schema(description = "10月及后入职信息是否完整")
@ExcelProperty("6月及后入职信息是否完整") @ExcelProperty("10月及后入职信息是否完整")
private String afterIsComplete; private String afterIsComplete;
/** /**
* 6月及后入职信息不完整人数 * 10月及后入职信息不完整人数
*/ */
@ExcelAttribute(name = "6月及后入职信息不完整人数") @ExcelAttribute(name = "10月及后入职信息不完整人数")
@Schema(description = "6月及后入职信息不完整人数") @Schema(description = "10月及后入职信息不完整人数")
@ExcelProperty("6月及后入职信息不完整人数") @ExcelProperty("10月及后入职信息不完整人数")
private Integer afterIncompleteNum; private Integer afterIncompleteNum;
/** /**
......
...@@ -441,7 +441,7 @@ public class TEmployeeInfoController { ...@@ -441,7 +441,7 @@ public class TEmployeeInfoController {
@Operation(summary = "通过EMP_ID查询人员档案变更日志", description = "通过EMP_ID查询人员档案变更日志") @Operation(summary = "通过EMP_ID查询人员档案变更日志", description = "通过EMP_ID查询人员档案变更日志")
@Inner @Inner
@PostMapping("/inner/updateEmpInfo") @PostMapping("/inner/updateEmpInfo")
public Boolean updateEmpInfo(@RequestBody UpdateEmpVo vo) { public Boolean updateEmpInfo(@RequestBody UpdateEmpVo vo) throws IllegalAccessException {
return tEmployeeInfoService.updateEmpInfo(vo); return tEmployeeInfoService.updateEmpInfo(vo);
} }
......
...@@ -195,7 +195,7 @@ public interface TEmployeeInfoService extends IService<TEmployeeInfo> { ...@@ -195,7 +195,7 @@ public interface TEmployeeInfoService extends IService<TEmployeeInfo> {
EmpDispatchAddVo addDispatchInfo(EmpDispatchAddVo addVo); EmpDispatchAddVo addDispatchInfo(EmpDispatchAddVo addVo);
Boolean updateEmpInfo(UpdateEmpVo vo); Boolean updateEmpInfo(UpdateEmpVo vo) throws IllegalAccessException;
Boolean checkMobile(String mobile); Boolean checkMobile(String mobile);
......
...@@ -10,10 +10,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -10,10 +10,7 @@ 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.admin.api.vo.AreaMap; import com.yifu.cloud.plus.v1.yifu.admin.api.vo.AreaMap;
import com.yifu.cloud.plus.v1.yifu.archives.entity.*; import com.yifu.cloud.plus.v1.yifu.archives.entity.*;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TArchivesExportLimitMapper; import com.yifu.cloud.plus.v1.yifu.archives.mapper.*;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TArchivesLimitMapper;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TCompleteMonitorMapper;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeProjectMapper;
import com.yifu.cloud.plus.v1.yifu.archives.service.*; import com.yifu.cloud.plus.v1.yifu.archives.service.*;
import com.yifu.cloud.plus.v1.yifu.archives.utils.ExcelStyle; import com.yifu.cloud.plus.v1.yifu.archives.utils.ExcelStyle;
import com.yifu.cloud.plus.v1.yifu.archives.vo.*; import com.yifu.cloud.plus.v1.yifu.archives.vo.*;
...@@ -69,7 +66,7 @@ public class TCompleteMonitorServiceImpl extends ServiceImpl<TCompleteMonitorMap ...@@ -69,7 +66,7 @@ public class TCompleteMonitorServiceImpl extends ServiceImpl<TCompleteMonitorMap
// 员工家庭信息表 // 员工家庭信息表
private final TEmpFamilyService tEmpFamilyService; private final TEmpFamilyService tEmpFamilyService;
// 人员档案表 // 人员档案表
private final TEmployeeInfoService tEmployeeInfoService; private final TEmployeeInfoMapper tEmployeeInfoMapper;
// 项目档案表 // 项目档案表
private final TEmployeeProjectService tEmployeeProjectService; private final TEmployeeProjectService tEmployeeProjectService;
// 员工职业资格信息表 // 员工职业资格信息表
...@@ -756,7 +753,7 @@ public class TCompleteMonitorServiceImpl extends ServiceImpl<TCompleteMonitorMap ...@@ -756,7 +753,7 @@ public class TCompleteMonitorServiceImpl extends ServiceImpl<TCompleteMonitorMap
List<TEmpFamily> tEmpFamily = tEmpFamilyService.getListByEmpId(id); List<TEmpFamily> tEmpFamily = tEmpFamilyService.getListByEmpId(id);
vo.setTEmpFamilyList(tEmpFamily); vo.setTEmpFamilyList(tEmpFamily);
// 人员档案表 // 人员档案表
TEmployeeInfo tEmployeeInfo = tEmployeeInfoService.getById(id); TEmployeeInfo tEmployeeInfo = tEmployeeInfoMapper.selectById(id);
vo.setTEmployeeInfo(tEmployeeInfo); vo.setTEmployeeInfo(tEmployeeInfo);
// 项目档案表 // 项目档案表
TEmployeeProject tEmployeeProject = tEmployeeProjectService.getByEmpIdAndDeptId(id,deptId); TEmployeeProject tEmployeeProject = tEmployeeProjectService.getByEmpIdAndDeptId(id,deptId);
......
...@@ -85,6 +85,7 @@ import java.lang.reflect.Field; ...@@ -85,6 +85,7 @@ import java.lang.reflect.Field;
import java.net.URL; import java.net.URL;
import java.net.URLEncoder; import java.net.URLEncoder;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.ZoneId;
import java.util.*; import java.util.*;
import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicInteger;
...@@ -129,9 +130,13 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T ...@@ -129,9 +130,13 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
private final TArchivesLimitMapper tArchivesLimitMapper; private final TArchivesLimitMapper tArchivesLimitMapper;
private final AtomicInteger updateAtomicInteger = new AtomicInteger(0); private final AtomicInteger updateAtomicInteger = new AtomicInteger(0);
private final TCompleteMonitorService completeMonitorService;
@Autowired @Autowired
private OSSUtil ossUtil; private OSSUtil ossUtil;
ExcelUtil<Object> excelUtil = new ExcelUtil<>(Object.class);
@Override @Override
public IPage<TEmployeeInfo> getPage(Page<TEmployeeInfo> page, TEmployeeInfo employeeInfo) { public IPage<TEmployeeInfo> getPage(Page<TEmployeeInfo> page, TEmployeeInfo employeeInfo) {
return baseMapper.getPage(page, employeeInfo); return baseMapper.getPage(page, employeeInfo);
...@@ -2517,7 +2522,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T ...@@ -2517,7 +2522,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
* @Param * @Param
**/ **/
@Override @Override
public Boolean updateEmpInfo(UpdateEmpVo vo) { public Boolean updateEmpInfo(UpdateEmpVo vo) throws IllegalAccessException {
if (Common.isNotNull(vo)) { if (Common.isNotNull(vo)) {
TEmployeeInfo employeeInfo = null; TEmployeeInfo employeeInfo = null;
TEmployeeProject p = null; TEmployeeProject p = null;
...@@ -2544,7 +2549,6 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T ...@@ -2544,7 +2549,6 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
.last(CommonConstants.LAST_ONE_SQL)); .last(CommonConstants.LAST_ONE_SQL));
if (Common.isNotNull(p)) { if (Common.isNotNull(p)) {
p.setStatus(CommonConstants.ONE_INT); p.setStatus(CommonConstants.ONE_INT);
tEmployeeProjectService.updateById(p);
} }
} }
} }
...@@ -2583,9 +2587,31 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T ...@@ -2583,9 +2587,31 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
} }
contractAuditMapper.insert(contractAudit); contractAuditMapper.insert(contractAudit);
contractServicer.updateById(c); contractServicer.updateById(c);
if (Common.isNotNull(p)) {
//审核通过更新项目档案合同信息
if (Common.isEmpty(p.getContractType())) {
p.setContractType(excelUtil.getDicValueByDataType(c.getContractName(), ExcelAttributeConstants.PERSONNEL_TYPE));
}
if (Common.isEmpty(p.getPost())) {
p.setPost(c.getPost());
}
if (Common.isEmpty(p.getWorkingHours())) {
p.setWorkingHours(c.getWorkingHours());
}
if (Common.isEmpty(p.getTryPeriod())) {
p.setTryPeriod(null == c.getTryPeriod() ? "无" : c.getTryPeriod());
}
if (Common.isEmpty(p.getEnjoinDate())) {
p.setEnjoinDate(null != c.getContractStart() ? c.getContractStart().toInstant().atZone(ZoneId.systemDefault()).toLocalDate() : null);
}
}
} }
} }
if (Common.isNotNull(p)) {
tEmployeeProjectService.updateById(p);
}
} }
} }
return true; return true;
......
...@@ -203,9 +203,9 @@ ...@@ -203,9 +203,9 @@
if(sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)) > 0,1,0) as IS_COMPLETE, if(sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)) > 0,1,0) as IS_COMPLETE,
sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)) as INCOMPLETE_NUM, sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)) as INCOMPLETE_NUM,
concat(ROUND((sum(if(PROJECT_STATUS = 0,1,0)) - sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)))*100/sum(if(PROJECT_STATUS = 0,1,0)),2),'%') as COMPLETE_PER, concat(ROUND((sum(if(PROJECT_STATUS = 0,1,0)) - sum(if((PROJECT_STATUS = 0 and IS_COMPLETE = '0') or PROJECT_STATUS = 1,0,1)))*100/sum(if(PROJECT_STATUS = 0,1,0)),2),'%') as COMPLETE_PER,
sum(if(PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-10-01',1,0)) as AFTER_EMPLOYMENT, sum(if(PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-07-01',1,0)) as AFTER_EMPLOYMENT,
if(sum(if((PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-10-01' and IS_COMPLETE = '0') or '2024-10-01' > DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') or PROJECT_STATUS = 1,0,1)) > 0,1,0) AFTER_IS_COMPLETE, if(sum(if((PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-07-01' and IS_COMPLETE = '0') or '2024-07-01' > DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') or PROJECT_STATUS = 1,0,1)) > 0,1,0) AFTER_IS_COMPLETE,
sum(if(PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-10-01' and IS_COMPLETE = '1',1,0)) as AFTER_INCOMPLETE_NUM sum(if(PROJECT_STATUS = 0 and DATE_FORMAT(CREATE_TIME,'%Y-%m-%d') >= '2024-07-01' and IS_COMPLETE = '1',1,0)) as AFTER_INCOMPLETE_NUM
from t_employee_project where DELETE_FLAG = '0' and PROJECT_STATUS = 0 group by DEPT_NO) a on a.DEPT_NO = b.DEPART_NO from t_employee_project where DELETE_FLAG = '0' and PROJECT_STATUS = 0 group by DEPT_NO) a on a.DEPT_NO = b.DEPART_NO
where b.DELETE_FLAG = '0' where b.DELETE_FLAG = '0'
<if test="deptNo != null and deptNo.trim() != ''"> <if test="deptNo != null and deptNo.trim() != ''">
......
...@@ -397,5 +397,11 @@ public class TInsuranceDetail extends BaseEntity { ...@@ -397,5 +397,11 @@ public class TInsuranceDetail extends BaseEntity {
@Schema(description = "消息提醒备注") @Schema(description = "消息提醒备注")
private String expireRemark; private String expireRemark;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
} }
\ No newline at end of file
...@@ -79,4 +79,10 @@ public class TInsuranceType extends BaseEntity { ...@@ -79,4 +79,10 @@ public class TInsuranceType extends BaseEntity {
@Schema(description = "是否删除 0否/1是") @Schema(description = "是否删除 0否/1是")
private Integer deleteFlag; private Integer deleteFlag;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
\ No newline at end of file
...@@ -196,4 +196,10 @@ public class InsuranceAddParam implements Serializable { ...@@ -196,4 +196,10 @@ public class InsuranceAddParam implements Serializable {
@Schema(description ="客户编码") @Schema(description ="客户编码")
private String unitNo; private String unitNo;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -203,4 +203,10 @@ public class InsuranceBatchParam implements Serializable { ...@@ -203,4 +203,10 @@ public class InsuranceBatchParam implements Serializable {
@Schema(description ="客户编码") @Schema(description ="客户编码")
private String unitNo; private String unitNo;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -406,4 +406,10 @@ public class InsuranceDetailVO implements Serializable { ...@@ -406,4 +406,10 @@ public class InsuranceDetailVO implements Serializable {
*/ */
@Schema(description = "消息提醒备注") @Schema(description = "消息提醒备注")
private String expireRemark; private String expireRemark;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -176,4 +176,9 @@ public class InsuranceExportListOneVO implements Serializable { ...@@ -176,4 +176,9 @@ public class InsuranceExportListOneVO implements Serializable {
@Schema(description = "封面抬头") @Schema(description = "封面抬头")
private String invoiceTitle; private String invoiceTitle;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -92,4 +92,10 @@ public class InsuranceExportListParam extends BaseEntity implements Serializable ...@@ -92,4 +92,10 @@ public class InsuranceExportListParam extends BaseEntity implements Serializable
*/ */
@Schema(description = "购买标准结束") @Schema(description = "购买标准结束")
private Integer buyStandardMax; private Integer buyStandardMax;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -188,4 +188,10 @@ public class InsuranceExportListVO implements Serializable { ...@@ -188,4 +188,10 @@ public class InsuranceExportListVO implements Serializable {
@Schema(description = "封面抬头") @Schema(description = "封面抬头")
private String invoiceTitle; private String invoiceTitle;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
package com.yifu.cloud.plus.v1.yifu.insurances.vo; package com.yifu.cloud.plus.v1.yifu.insurances.vo;
import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity; import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
...@@ -120,4 +118,10 @@ public class InsuranceListParam extends BaseEntity { ...@@ -120,4 +118,10 @@ public class InsuranceListParam extends BaseEntity {
@Schema(description = "是否有效 0有效 1无效") @Schema(description = "是否有效 0有效 1无效")
private Integer isEffect; private Integer isEffect;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -2,8 +2,6 @@ package com.yifu.cloud.plus.v1.yifu.insurances.vo; ...@@ -2,8 +2,6 @@ package com.yifu.cloud.plus.v1.yifu.insurances.vo;
import com.alibaba.excel.annotation.ExcelProperty; import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle; import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
...@@ -171,4 +169,10 @@ public class InsuranceListVO implements Serializable { ...@@ -171,4 +169,10 @@ public class InsuranceListVO implements Serializable {
*/ */
@Schema(description = "是否有效 0有效 1无效") @Schema(description = "是否有效 0有效 1无效")
private Integer isEffect; private Integer isEffect;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -120,4 +120,10 @@ public class InsuranceRefundHandlingParam extends BaseEntity implements Serializ ...@@ -120,4 +120,10 @@ public class InsuranceRefundHandlingParam extends BaseEntity implements Serializ
@Schema(description = "购买标准区间最大值") @Schema(description = "购买标准区间最大值")
private String buyStandardMax; private String buyStandardMax;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -215,4 +215,10 @@ public class InsuranceRefundListVo implements Serializable { ...@@ -215,4 +215,10 @@ public class InsuranceRefundListVo implements Serializable {
*/ */
@Schema(description = "是否有效 0有效 1无效") @Schema(description = "是否有效 0有效 1无效")
private Integer isEffect; private Integer isEffect;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -103,4 +103,10 @@ public class InsuranceRefundParam extends BaseEntity implements Serializable { ...@@ -103,4 +103,10 @@ public class InsuranceRefundParam extends BaseEntity implements Serializable {
*/ */
@Schema(description = "是否有效 0有效 1无效") @Schema(description = "是否有效 0有效 1无效")
private Integer isEffect; private Integer isEffect;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -133,4 +133,10 @@ public class InsuranceReplaceParam implements Serializable { ...@@ -133,4 +133,10 @@ public class InsuranceReplaceParam implements Serializable {
@Schema(description ="客户编码") @Schema(description ="客户编码")
private String unitNo; private String unitNo;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
package com.yifu.cloud.plus.v1.yifu.insurances.vo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
* @author huych
* @description 险种信息返回类
* @date 2024-10-30 10:26:33
*/
@Data
public class InsuranceTypeExportVo {
private static final long serialVersionUID = 1L;
/**
* 险种名称
*/
@Schema(description = "险种名称")
private String name;
/**
* 所属保险公司名称
*/
@Schema(description = "所属保险公司名称")
private String insuranceCompanyName;
/**
* 收款银行名称
*/
@Schema(description = "收款银行名称")
private String bankName;
/**
* 收款银行账号
*/
@Schema(description = "收款银行账号")
private String bankNo;
/**
* 收款单位名称
*/
@Schema(description = "收款单位名称")
private String receiptUnitName;
/**
* 购买年龄限制 0 限制 1 不限制
*/
@Schema(description = "购买年龄限制")
private String ageLimit;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
}
...@@ -15,6 +15,8 @@ import java.io.Serializable; ...@@ -15,6 +15,8 @@ import java.io.Serializable;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.time.LocalDate; import java.time.LocalDate;
/** /**
* @author zhaji * @author zhaji
* @description 已投保查询返回类 * @description 已投保查询返回类
...@@ -400,4 +402,12 @@ public class InsuredListVo implements Serializable { ...@@ -400,4 +402,12 @@ public class InsuredListVo implements Serializable {
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "替换人封面抬头") @ExcelProperty(value = "替换人封面抬头")
private String replaceInvoiceTitle; private String replaceInvoiceTitle;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "是否地市自购")
private String isAdress;
} }
package com.yifu.cloud.plus.v1.yifu.insurances.vo; package com.yifu.cloud.plus.v1.yifu.insurances.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity; import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag; import io.swagger.v3.oas.annotations.tags.Tag;
...@@ -148,4 +150,10 @@ public class InsuredParam extends BaseEntity implements Serializable { ...@@ -148,4 +150,10 @@ public class InsuredParam extends BaseEntity implements Serializable {
@Schema(description ="客户编码") @Schema(description ="客户编码")
private String unitNo; private String unitNo;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -75,4 +75,10 @@ public class RefundExportListParam extends BaseEntity implements Serializable { ...@@ -75,4 +75,10 @@ public class RefundExportListParam extends BaseEntity implements Serializable {
@Schema(description = "购买标准结束") @Schema(description = "购买标准结束")
private String buyStandardMax; private String buyStandardMax;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -222,4 +222,10 @@ public class RefundExportListVo implements Serializable { ...@@ -222,4 +222,10 @@ public class RefundExportListVo implements Serializable {
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm:ss") @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm:ss")
@Schema(description = "派单日期") @Schema(description = "派单日期")
private LocalDateTime createTime; private LocalDateTime createTime;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -8,6 +8,7 @@ import lombok.Data; ...@@ -8,6 +8,7 @@ import lombok.Data;
import java.io.Serializable; import java.io.Serializable;
import java.time.LocalDate; import java.time.LocalDate;
/** /**
* @author zhangyun * @author zhangyun
* @description 退保成功列表 * @description 退保成功列表
...@@ -107,4 +108,10 @@ public class RefundListVo implements Serializable { ...@@ -107,4 +108,10 @@ public class RefundListVo implements Serializable {
*/ */
@Schema(description = "退至员工身份证号") @Schema(description = "退至员工身份证号")
private String returnEmpIdcardNo; private String returnEmpIdcardNo;
/**
* 是否地市自购0是 1 否
*/
@Schema(description = "是否地市自购")
private String isAdress;
} }
...@@ -43,6 +43,17 @@ public class TInsuranceTypeController { ...@@ -43,6 +43,17 @@ public class TInsuranceTypeController {
return R.ok(insuranceTypeService.pageDiy(page, insuranceType)); return R.ok(insuranceTypeService.pageDiy(page, insuranceType));
} }
/**
* 导出查询
* @param insuranceType 险种
* @return
*/
@Operation(summary = "导出查询", description = "导出查询")
@PostMapping("/export" )
public R exportInsuranceType(@RequestBody InsuranceTypeVo insuranceType) {
return insuranceTypeService.selectInsuranceType(insuranceType);
}
/** /**
* 新增险种 * 新增险种
* @param insuranceType 险种明细 * @param insuranceType 险种明细
......
...@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceType; import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceType;
import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeRate; import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeRate;
import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeStandard; import com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeStandard;
import com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeExportVo;
import com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeVo; import com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeVo;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
...@@ -48,6 +49,8 @@ public interface TInsuranceTypeMapper extends BaseMapper<TInsuranceType> { ...@@ -48,6 +49,8 @@ public interface TInsuranceTypeMapper extends BaseMapper<TInsuranceType> {
*/ */
IPage<InsuranceTypeVo> selectInsuranceTypePage(Page page, @Param("insuranceType") InsuranceTypeVo insuranceType); IPage<InsuranceTypeVo> selectInsuranceTypePage(Page page, @Param("insuranceType") InsuranceTypeVo insuranceType);
List<InsuranceTypeExportVo> selectInsuranceType(@Param("insuranceType") InsuranceTypeVo insuranceType);
InsuranceTypeVo getInsuranceTypeDetailById(String id); InsuranceTypeVo getInsuranceTypeDetailById(String id);
} }
...@@ -26,6 +26,13 @@ public interface TInsuranceTypeService extends IService<TInsuranceType> { ...@@ -26,6 +26,13 @@ public interface TInsuranceTypeService extends IService<TInsuranceType> {
*/ */
IPage<InsuranceTypeVo> pageDiy(Page<InsuranceTypeVo> page,InsuranceTypeVo insuranceType); IPage<InsuranceTypeVo> pageDiy(Page<InsuranceTypeVo> page,InsuranceTypeVo insuranceType);
/**
* 险种批量导出
* @author huych
* @param insuranceType 查询参数
*/
R selectInsuranceType(InsuranceTypeVo insuranceType);
/** /**
* 新增险种信息 * 新增险种信息
* *
......
...@@ -469,6 +469,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -469,6 +469,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
//保存到数据库中的结果 //保存到数据库中的结果
List<InsuranceReplaceParam> listSuccess = map.get("listSuccess"); List<InsuranceReplaceParam> listSuccess = map.get("listSuccess");
List<TInsuranceDetail> detailList = new ArrayList<>(); List<TInsuranceDetail> detailList = new ArrayList<>();
TInsuranceType insuranceType;
TInsuranceCompany insuranceCompany;
if (CollectionUtils.isNotEmpty(listSuccess)){ if (CollectionUtils.isNotEmpty(listSuccess)){
for (InsuranceReplaceParam success : listSuccess) { for (InsuranceReplaceParam success : listSuccess) {
//替换 //替换
...@@ -480,6 +482,23 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -480,6 +482,23 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
detail.setIsOverdue(null); detail.setIsOverdue(null);
detail.setUpdateTime(LocalDateTime.now()); detail.setUpdateTime(LocalDateTime.now());
this.updateById(detail); this.updateById(detail);
// 保险公司-险种-购买标准 是否存在
insuranceCompany = tInsuranceCompanyService.getOne(Wrappers.<TInsuranceCompany>query().lambda()
.eq(TInsuranceCompany::getCompanyName, detail.getInsuranceCompanyName())
.eq(TInsuranceCompany::getDeleteFlag, CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL)
);
if (Optional.ofNullable(insuranceCompany).isPresent()) {
insuranceType = tInsuranceTypeService.getOne(Wrappers.<TInsuranceType>query().lambda()
.eq(TInsuranceType::getName, detail.getInsuranceTypeName())
.eq(TInsuranceType::getInsuranceCompanyId, insuranceCompany.getId())
.eq(TInsuranceType::getDeleteFlag, CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL)
);
if (Optional.ofNullable(insuranceType).isPresent()) {
newDetail.setIsAdress(insuranceType.getIsAdress());
}
}
//新数据置为待办理 //新数据置为待办理
newDetail.setId(null); newDetail.setId(null);
newDetail.setOrderNo(orderNo); newDetail.setOrderNo(orderNo);
...@@ -1393,7 +1412,24 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -1393,7 +1412,24 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
TInsuranceSettle settle; TInsuranceSettle settle;
SettleVo settleVo; SettleVo settleVo;
R<TIncomeDetailReturnVo> incomeDetailList; R<TIncomeDetailReturnVo> incomeDetailList;
// TInsuranceCompany insuranceCompany;
// TInsuranceType insuranceType;
for (TInsuranceDetail detail : successList) { for (TInsuranceDetail detail : successList) {
// // 是否地市自购
// insuranceCompany = tInsuranceCompanyService.getOne(Wrappers.<TInsuranceCompany>query().lambda()
// .eq(TInsuranceCompany::getCompanyName, detail.getInsuranceCompanyName())
// .eq(TInsuranceCompany::getDeleteFlag, CommonConstants.ZERO_INT)
// .last(CommonConstants.LAST_ONE_SQL));
// if (Optional.ofNullable(insuranceCompany).isPresent()) {
// insuranceType = tInsuranceTypeService.getOne(Wrappers.<TInsuranceType>query().lambda()
// .eq(TInsuranceType::getName, detail.getInsuranceTypeName())
// .eq(TInsuranceType::getInsuranceCompanyId, insuranceCompany.getId())
// .eq(TInsuranceType::getDeleteFlag, CommonConstants.ZERO_INT)
// .last(CommonConstants.LAST_ONE_SQL)
// );
// detail.setIsAdress(insuranceType.getIsAdress());
// }
if (StringUtils.isNotBlank(detail.getDefaultSettleId())){ if (StringUtils.isNotBlank(detail.getDefaultSettleId())){
settle = tInsuranceSettleService.getById(detail.getDefaultSettleId()); settle = tInsuranceSettleService.getById(detail.getDefaultSettleId());
if (Optional.ofNullable(settle).isPresent()){ if (Optional.ofNullable(settle).isPresent()){
...@@ -2846,6 +2882,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -2846,6 +2882,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
listResult.add(param); listResult.add(param);
continue; continue;
} }
param.setIsAdress(insuranceType.getIsAdress());
//购买标准 //购买标准
TInsuranceTypeStandard typeStandard = tInsuranceTypeStandardService.getOne(Wrappers.<TInsuranceTypeStandard>query().lambda() TInsuranceTypeStandard typeStandard = tInsuranceTypeStandardService.getOne(Wrappers.<TInsuranceTypeStandard>query().lambda()
.eq(TInsuranceTypeStandard::getBuyStandard, param.getBuyStandard()) .eq(TInsuranceTypeStandard::getBuyStandard, param.getBuyStandard())
...@@ -3216,6 +3253,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -3216,6 +3253,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
listResult.add(param); listResult.add(param);
continue; continue;
} }
param.setIsAdress(insuranceType.getIsAdress());
//购买标准 //购买标准
TInsuranceTypeStandard typeStandard = tInsuranceTypeStandardService.getOne(Wrappers.<TInsuranceTypeStandard>query().lambda() TInsuranceTypeStandard typeStandard = tInsuranceTypeStandardService.getOne(Wrappers.<TInsuranceTypeStandard>query().lambda()
.eq(TInsuranceTypeStandard::getBuyStandard, param.getBuyStandard()) .eq(TInsuranceTypeStandard::getBuyStandard, param.getBuyStandard())
...@@ -3420,7 +3458,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -3420,7 +3458,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
.eq(TInsuranceType::getDeleteFlag, CommonConstants.ZERO_INT) .eq(TInsuranceType::getDeleteFlag, CommonConstants.ZERO_INT)
.last(CommonConstants.LAST_ONE_SQL) .last(CommonConstants.LAST_ONE_SQL)
); );
if (Optional.ofNullable(insuranceType).isPresent() && CommonConstants.ZERO_STRING.equals( if (Optional.ofNullable(insuranceType).isPresent()) {
// param.setIsAdress(insuranceType.getIsAdress());
if (CommonConstants.ZERO_STRING.equals(
insuranceType.getAgeLimit()) && (IdCardUtil.getFullAge(param.getEmpIdcardNo()) insuranceType.getAgeLimit()) && (IdCardUtil.getFullAge(param.getEmpIdcardNo())
< CommonConstants.SIXTEEN_INT || IdCardUtil.getFullAge(param.getEmpIdcardNo()) < CommonConstants.SIXTEEN_INT || IdCardUtil.getFullAge(param.getEmpIdcardNo())
> CommonConstants.SEVENTY)) { > CommonConstants.SEVENTY)) {
...@@ -3429,6 +3469,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -3429,6 +3469,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
continue; continue;
} }
} }
}
if(!LocalDateUtil.isDate(param.getPolicyStart(),LocalDateUtil.NORM_DATE_PATTERN)){ if(!LocalDateUtil.isDate(param.getPolicyStart(),LocalDateUtil.NORM_DATE_PATTERN)){
param.setErrorMessage(InsurancesConstants.POLICY_START_PARSE_ERROR); param.setErrorMessage(InsurancesConstants.POLICY_START_PARSE_ERROR);
......
...@@ -53,6 +53,16 @@ public class TInsuranceTypeServiceImpl extends ServiceImpl<TInsuranceTypeMapper, ...@@ -53,6 +53,16 @@ public class TInsuranceTypeServiceImpl extends ServiceImpl<TInsuranceTypeMapper,
return this.baseMapper.selectInsuranceTypePage(page,insuranceType); return this.baseMapper.selectInsuranceTypePage(page,insuranceType);
} }
/**
* 险种批量导出
* @author huych
* @param insuranceType 查询参数
*/
@Override
public R selectInsuranceType(InsuranceTypeVo insuranceType) {
return R.ok(baseMapper.selectInsuranceType(insuranceType));
}
/** /**
* 新增险种信息 * 新增险种信息
* *
......
...@@ -17,13 +17,14 @@ ...@@ -17,13 +17,14 @@
<result property="createTime" column="CREATE_TIME" jdbcType="TIMESTAMP"/> <result property="createTime" column="CREATE_TIME" jdbcType="TIMESTAMP"/>
<result property="updateBy" column="UPDATE_BY" jdbcType="VARCHAR"/> <result property="updateBy" column="UPDATE_BY" jdbcType="VARCHAR"/>
<result property="updateTime" column="UPDATE_TIME" jdbcType="TIMESTAMP"/> <result property="updateTime" column="UPDATE_TIME" jdbcType="TIMESTAMP"/>
<result property="isAdress" column="IS_ADRESS" jdbcType="VARCHAR"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
ID,NAME,INSURANCE_COMPANY_ID, ID,NAME,INSURANCE_COMPANY_ID,
RECEIPT_UNIT_NAME,BANK_NAME,BANK_NO, RECEIPT_UNIT_NAME,BANK_NAME,BANK_NO,
DELETE_FLAG,CREATE_BY,CREATE_NAME, DELETE_FLAG,CREATE_BY,CREATE_NAME,
CREATE_TIME,UPDATE_BY,UPDATE_TIME CREATE_TIME,UPDATE_BY,UPDATE_TIME,IS_ADRESS
</sql> </sql>
<select id="selectInsuranceTypeRateList" resultType="com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeRate"> <select id="selectInsuranceTypeRateList" resultType="com.yifu.cloud.plus.v1.yifu.insurances.entity.TInsuranceTypeRate">
select select
...@@ -64,7 +65,8 @@ ...@@ -64,7 +65,8 @@
a.RECEIPT_UNIT_NAME as receiptUnitName, a.RECEIPT_UNIT_NAME as receiptUnitName,
a.BANK_NAME as bankName, a.BANK_NAME as bankName,
a.BANK_NO as bankNo, a.BANK_NO as bankNo,
a.AGE_LIMIT as ageLimit a.AGE_LIMIT as ageLimit,
a.IS_ADRESS as isAdress
from from
t_insurance_type a, t_insurance_type a,
t_insurance_company b t_insurance_company b
...@@ -78,8 +80,41 @@ ...@@ -78,8 +80,41 @@
<if test="insuranceType.name != null and insuranceType.name.trim() != ''"> <if test="insuranceType.name != null and insuranceType.name.trim() != ''">
and a.NAME like concat('%',replace(replace(#{insuranceType.name},'_','\_'),'%','\%'),'%') and a.NAME like concat('%',replace(replace(#{insuranceType.name},'_','\_'),'%','\%'),'%')
</if> </if>
<if test="insuranceType.isAdress != null and insuranceType.isAdress.trim() != ''">
and a.IS_ADRESS = #{insuranceType.isAdress}
</if>
ORDER BY a.CREATE_TIME DESC
</select>
<select id="selectInsuranceType" resultType="com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeExportVo">
select
a.NAME as name ,
b.COMPANY_NAME as insuranceCompanyName,
a.BANK_NAME as bankName,
a.BANK_NO as bankNo,
a.RECEIPT_UNIT_NAME as receiptUnitName,
if(a.AGE_LIMIT = '0','限制(16-70岁)','无') as ageLimit,
if(a.IS_ADRESS = '0','是',if(ifnull(a.IS_ADRESS,3) = 3,'','否')) as isAdress
from
t_insurance_type a,
t_insurance_company b
where
a.INSURANCE_COMPANY_ID = b.ID
and
a.DELETE_FLAG = 0
<if test="insuranceType.insuranceCompanyName != null and insuranceType.insuranceCompanyName.trim() != ''">
and b.COMPANY_NAME = #{insuranceType.insuranceCompanyName}
</if>
<if test="insuranceType.name != null and insuranceType.name.trim() != ''">
and a.NAME like concat('%',replace(replace(#{insuranceType.name},'_','\_'),'%','\%'),'%')
</if>
<if test="insuranceType.isAdress != null and insuranceType.isAdress.trim() != ''">
and a.IS_ADRESS = #{insuranceType.isAdress}
</if>
ORDER BY a.CREATE_TIME DESC ORDER BY a.CREATE_TIME DESC
</select> </select>
<select id="getInsuranceTypeDetailById" resultType="com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeVo"> <select id="getInsuranceTypeDetailById" resultType="com.yifu.cloud.plus.v1.yifu.insurances.vo.InsuranceTypeVo">
select select
a.ID as id, a.ID as id,
...@@ -89,7 +124,8 @@ ...@@ -89,7 +124,8 @@
a.RECEIPT_UNIT_NAME as receiptUnitName, a.RECEIPT_UNIT_NAME as receiptUnitName,
a.BANK_NAME as bankName, a.BANK_NAME as bankName,
a.BANK_NO as bankNo, a.BANK_NO as bankNo,
a.AGE_LIMIT as ageLimit a.AGE_LIMIT as ageLimit,
a.IS_ADRESS as isAdress
from from
t_insurance_type a, t_insurance_type a,
t_insurance_company b t_insurance_company b
......
...@@ -20,10 +20,7 @@ package com.yifu.cloud.plus.v1.yifu.salary.entity; ...@@ -20,10 +20,7 @@ package com.yifu.cloud.plus.v1.yifu.salary.entity;
import com.alibaba.excel.annotation.ExcelIgnore; import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty; import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle; import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute; import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity; import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
...@@ -138,6 +135,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -138,6 +135,7 @@ public class TSalaryEmployee extends BaseEntity {
@Length(max = 50, message = "开户行总行不能超过50个字符") @Length(max = 50, message = "开户行总行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行总行") @ExcelProperty("开户行总行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankName; private String bankName;
/** /**
* 开户行省 * 开户行省
...@@ -145,6 +143,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -145,6 +143,7 @@ public class TSalaryEmployee extends BaseEntity {
@ExcelAttribute(name = "开户行省",isArea = true) @ExcelAttribute(name = "开户行省",isArea = true)
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行省") @ExcelProperty("开户行省")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankProvince; private String bankProvince;
/** /**
* 开户行市 * 开户行市
...@@ -152,6 +151,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -152,6 +151,7 @@ public class TSalaryEmployee extends BaseEntity {
@ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince") @ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行市") @ExcelProperty("开户行市")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankCity; private String bankCity;
/** /**
* 开户行支行 * 开户行支行
...@@ -160,6 +160,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -160,6 +160,7 @@ public class TSalaryEmployee extends BaseEntity {
@Length(max = 50, message = "开户行支行不能超过50个字符") @Length(max = 50, message = "开户行支行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行支行") @ExcelProperty("开户行支行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankSubName; private String bankSubName;
/** /**
* 银行卡号 * 银行卡号
...@@ -168,6 +169,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -168,6 +169,7 @@ public class TSalaryEmployee extends BaseEntity {
@Length(max = 50, message = "银行卡号不能超过50个字符") @Length(max = 50, message = "银行卡号不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("银行卡号") @ExcelProperty("银行卡号")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankNo; private String bankNo;
/** /**
* 手机号码 * 手机号码
...@@ -184,6 +186,7 @@ public class TSalaryEmployee extends BaseEntity { ...@@ -184,6 +186,7 @@ public class TSalaryEmployee extends BaseEntity {
@Length(max = 6, message = "计税月份不能超过6个字符") @Length(max = 6, message = "计税月份不能超过6个字符")
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("计税月份") @ExcelProperty("计税月份")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String taxMonth; private String taxMonth;
/** /**
* 在职状态(0在职;1离职) * 在职状态(0在职;1离职)
......
package com.yifu.cloud.plus.v1.yifu.salary.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import java.math.BigDecimal;
/**
* @Author fxj
* @Date 2024/10/31
* @Description 员工报账查询审核导出明细项2
* @Version 1.0
*/
@Schema(description = " 员工报账查询审核导出明细项2")
@Data
public class TAuditExportItemVo {
private String salaryAccountId;
@ExcelProperty("通讯补贴(不计税)")
private BigDecimal phoneSubsidy;
@ExcelProperty("年终奖")
private BigDecimal annualBonus;
@ExcelProperty("免个税个人代扣")
private BigDecimal exemptionPersionTax;
@ExcelProperty("企业(职业)年金")
private BigDecimal enterpriseAnnuity;
}
package com.yifu.cloud.plus.v1.yifu.salary.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
/**
* @Author fxj
* @Date 2024/10/31
* @Description 员工报账查询审核导出明细项1
* @Version 1.0
*/
@Schema(description = " 员工报账查询审核导出明细项1")
@Data
@HeadFontStyle(fontHeightInPoints = 11)
public class TAuditExportStandardVo {
//关键关联字段
private String salaryFormId;
@ExcelProperty("薪酬状态")
private String status;
private String businessPrimaryTyp;
private String businessSecondType;
private String businessThirdType;
}
...@@ -35,6 +35,8 @@ import java.math.BigDecimal; ...@@ -35,6 +35,8 @@ import java.math.BigDecimal;
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
public class TSalaryAccountExportVo { public class TSalaryAccountExportVo {
private String id; private String id;
private String salaryFormId;
// 是否劳务费 手机号 计税月份 发放时间 结算月份 工资月份 出账单位 结算单位 结算单位编码 // 是否劳务费 手机号 计税月份 发放时间 结算月份 工资月份 出账单位 结算单位 结算单位编码
// 结算部门 部门编码 人员类型 在职状态 员工姓名 身份证号 工资应发 实发工资合计 // 结算部门 部门编码 人员类型 在职状态 员工姓名 身份证号 工资应发 实发工资合计
// 年终奖 薪资个税 年终奖扣税 代扣个人社保 代扣个人公积金 个人社保 个人公积金 // 年终奖 薪资个税 年终奖扣税 代扣个人社保 代扣个人公积金 个人社保 个人公积金
......
...@@ -120,6 +120,17 @@ public interface TSalaryAccountMapper extends BaseMapper<TSalaryAccount> { ...@@ -120,6 +120,17 @@ public interface TSalaryAccountMapper extends BaseMapper<TSalaryAccount> {
List<TSalaryAccountItemExportVo> auditExportSelectItems(@Param("idList") List<String> idList); List<TSalaryAccountItemExportVo> auditExportSelectItems(@Param("idList") List<String> idList);
List<TAuditExportStandardVo> auditExportStandard(@Param("idList") List<String> idList);
List<TAuditExportItemVo> auditExportAnnualBonus(@Param("idList") List<String> idList);
List<TAuditExportItemVo> auditExportExemptionPersionTax(@Param("idList") List<String> idList);
List<TAuditExportItemVo> auditExportEnterpriseAnnuity(@Param("idList") List<String> idList);
List<TAuditExportItemVo> auditExportPhoneSubsidy(@Param("idList") List<String> idList);
List<TSalaryAccount> getAccountListBySalaryId(@Param("searchVo") TSalaryAccountSearchVo searchVo); List<TSalaryAccount> getAccountListBySalaryId(@Param("searchVo") TSalaryAccountSearchVo searchVo);
// 导出报账专用hgw // 导出报账专用hgw
......
...@@ -115,6 +115,7 @@ public class SalaryUploadServiceImpl extends ServiceImpl<TSalaryStandardMapper, ...@@ -115,6 +115,7 @@ public class SalaryUploadServiceImpl extends ServiceImpl<TSalaryStandardMapper,
return this.salaryUploadCore(vo); return this.salaryUploadCore(vo);
} catch (Exception e){ } catch (Exception e){
log.error("薪资导入异常:",e); log.error("薪资导入异常:",e);
return R.failed("薪资导入异常,请检查表数据");
} finally { } finally {
importTwoAtomicInteger.decrementAndGet(); importTwoAtomicInteger.decrementAndGet();
} }
...@@ -124,7 +125,7 @@ public class SalaryUploadServiceImpl extends ServiceImpl<TSalaryStandardMapper, ...@@ -124,7 +125,7 @@ public class SalaryUploadServiceImpl extends ServiceImpl<TSalaryStandardMapper,
log.error("超出阈值:"+ ResultConstants.IMPORT_DOWN_LOAD_DATA); log.error("超出阈值:"+ ResultConstants.IMPORT_DOWN_LOAD_DATA);
return R.failed("薪资导入," + ResultConstants.IMPORT_DOWN_LOAD_DATA); return R.failed("薪资导入," + ResultConstants.IMPORT_DOWN_LOAD_DATA);
} }
return R.failed("薪资导入," + ResultConstants.IMPORT_DOWN_LOAD_DATA);
} }
private R<List<ErrorMessage>> salaryUploadCore(SalaryUploadParamVo vo) { private R<List<ErrorMessage>> salaryUploadCore(SalaryUploadParamVo vo) {
......
...@@ -39,6 +39,7 @@ import com.yifu.cloud.plus.v1.yifu.salary.service.TSalaryAccountService; ...@@ -39,6 +39,7 @@ import com.yifu.cloud.plus.v1.yifu.salary.service.TSalaryAccountService;
import com.yifu.cloud.plus.v1.yifu.salary.vo.*; import com.yifu.cloud.plus.v1.yifu.salary.vo.*;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import lombok.extern.log4j.Log4j2; import lombok.extern.log4j.Log4j2;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -207,23 +208,65 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper, ...@@ -207,23 +208,65 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper,
if (count > CommonConstants.ZERO_INT) { if (count > CommonConstants.ZERO_INT) {
Map<String,TSalaryAccountItemExportVo> itemExportVoMap = new HashMap<>(); Map<String,TSalaryAccountItemExportVo> itemExportVoMap = new HashMap<>();
List<String> idList = null; List<String> idList = null;
List<String> idStandardList = null;
List<TAuditExportStandardVo> standardItems = null;
Map<String,TAuditExportStandardVo> itemStandardMap = new HashMap<>();
Map<String,TAuditExportItemVo> itemAnnualBonusMap = new HashMap<>();
Map<String,TAuditExportItemVo> itemPersionTaxMap = new HashMap<>();
Map<String,TAuditExportItemVo> itemAnnuityMap = new HashMap<>();
Map<String,TAuditExportItemVo> itemSubsidyMap = new HashMap<>();
List<TSalaryAccountItemExportVo> items = null; List<TSalaryAccountItemExportVo> items = null;
for (int i = 0; i <= count; i += CommonConstants.EXCEL_EXPORT_LIMIT_2) { List<TAuditExportItemVo> annualBonusItems;
List<TAuditExportItemVo> exemptionPersionTaxItems;
List<TAuditExportItemVo> enterpriseAnnuityItems;
List<TAuditExportItemVo> phoneSubsidyItems;
for (int i = 0; i <= count; i += CommonConstants.EXCEL_EXPORT_LIMIT_1) {
// 获取实际记录 // 获取实际记录
searchVo.setLimitStart(i); searchVo.setLimitStart(i);
searchVo.setLimitEnd(CommonConstants.EXCEL_EXPORT_LIMIT_2); searchVo.setLimitEnd(CommonConstants.EXCEL_EXPORT_LIMIT_1);
list = baseMapper.auditExportDiy(searchVo, searchVo.getIdList()); list = baseMapper.auditExportDiy(searchVo, searchVo.getIdList());
if (Common.isNotNull(list)) { if (Common.isNotNull(list)) {
//先把数据封装完成 //先把数据封装完成
idList = list.stream().map(TSalaryAccountExportVo::getId).collect(Collectors.toList()); idList = list.stream().map(TSalaryAccountExportVo::getId).collect(Collectors.toList());
idStandardList = list.stream().map(TSalaryAccountExportVo::getSalaryFormId).collect(Collectors.toList());
//初始化明细数据MAP
if (Common.isNotNull(idList)){ if (Common.isNotNull(idList)){
items = baseMapper.auditExportSelectItems(idList); items = baseMapper.auditExportSelectItems(idList);
}
if (Common.isNotNull(items)){ if (Common.isNotNull(items)){
itemExportVoMap = items.stream().collect(Collectors.toMap(TSalaryAccountItemExportVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1)); itemExportVoMap = items.stream().collect(Collectors.toMap(TSalaryAccountItemExportVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1));
} }
items.clear();
annualBonusItems = baseMapper.auditExportAnnualBonus(idList);
if (Common.isNotNull(annualBonusItems)){
itemAnnualBonusMap = annualBonusItems.stream().collect(Collectors.toMap(TAuditExportItemVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1));
}
annualBonusItems.clear();
exemptionPersionTaxItems = baseMapper.auditExportExemptionPersionTax(idList);
if (Common.isNotNull(exemptionPersionTaxItems)){
itemPersionTaxMap = exemptionPersionTaxItems.stream().collect(Collectors.toMap(TAuditExportItemVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1));
}
exemptionPersionTaxItems.clear();
enterpriseAnnuityItems = baseMapper.auditExportEnterpriseAnnuity(idList);
if (Common.isNotNull(enterpriseAnnuityItems)){
itemAnnuityMap = enterpriseAnnuityItems.stream().collect(Collectors.toMap(TAuditExportItemVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1));
}
enterpriseAnnuityItems.clear();
phoneSubsidyItems = baseMapper.auditExportPhoneSubsidy(idList);
if (Common.isNotNull(phoneSubsidyItems)){
itemSubsidyMap = phoneSubsidyItems.stream().collect(Collectors.toMap(TAuditExportItemVo::getSalaryAccountId,vo -> vo,(k1,k2) -> k1));
}
phoneSubsidyItems.clear();
}
if (Common.isNotNull(idStandardList)){
standardItems = baseMapper.auditExportStandard(idStandardList);
if (Common.isNotNull(standardItems)){
itemStandardMap = standardItems.stream().collect(Collectors.toMap(TAuditExportStandardVo::getSalaryFormId,vo -> vo,(k1,k2) -> k1));
standardItems.clear();
}
}
//封装信息 //封装信息
initResult(list, itemExportVoMap); initResult(list, itemExportVoMap,itemStandardMap,itemAnnualBonusMap,itemPersionTaxMap,itemAnnuityMap,itemSubsidyMap);
if (i%CommonConstants.EXCEL_EXPORT_LIMIT==0){ if (i%CommonConstants.EXCEL_EXPORT_LIMIT==0){
writeSheet = EasyExcelFactory.writerSheet("工资报账" + index).build(); writeSheet = EasyExcelFactory.writerSheet("工资报账" + index).build();
index++; index++;
...@@ -231,12 +274,7 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper, ...@@ -231,12 +274,7 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper,
excelWriter.write(list, writeSheet); excelWriter.write(list, writeSheet);
list.clear(); list.clear();
} }
if (Common.isNotNull(idList)){ clearMap(itemExportVoMap, idList, idStandardList, itemStandardMap, itemAnnualBonusMap, itemPersionTaxMap, itemAnnuityMap, itemSubsidyMap);
idList.clear();
}
if (Common.isNotNull(itemExportVoMap)){
itemExportVoMap.clear();
}
} }
} else { } else {
writeSheet = EasyExcelFactory.writerSheet("工资报账" + index).build(); writeSheet = EasyExcelFactory.writerSheet("工资报账" + index).build();
...@@ -261,14 +299,72 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper, ...@@ -261,14 +299,72 @@ public class TSalaryAccountServiceImpl extends ServiceImpl<TSalaryAccountMapper,
} }
} }
private void initResult(List<TSalaryAccountExportVo> list, Map<String, TSalaryAccountItemExportVo> itemExportVoMap) { private void clearMap(Map<String, TSalaryAccountItemExportVo> itemExportVoMap, List<String> idList, List<String> idStandardList, Map<String, TAuditExportStandardVo> itemStandardMap, Map<String, TAuditExportItemVo> itemAnnualBonusMap, Map<String, TAuditExportItemVo> itemPersionTaxMap, Map<String, TAuditExportItemVo> itemAnnuityMap, Map<String, TAuditExportItemVo> itemSubsidyMap) {
if (Common.isNotNull(idList)){
idList.clear();
}
if (Common.isNotNull(idStandardList)){
idStandardList.clear();
}
if (Common.isNotNull(itemExportVoMap)){
itemExportVoMap.clear();
}
if (Common.isNotNull(itemStandardMap)){
itemStandardMap.clear();
}
if (Common.isNotNull(itemAnnualBonusMap)){
itemAnnualBonusMap.clear();
}
if (Common.isNotNull(itemPersionTaxMap)){
itemPersionTaxMap.clear();
}
if (Common.isNotNull(itemAnnuityMap)){
itemAnnuityMap.clear();
}
if (Common.isNotNull(itemSubsidyMap)){
itemSubsidyMap.clear();
}
}
private void initResult(List<TSalaryAccountExportVo> list,
Map<String, TSalaryAccountItemExportVo> itemExportVoMap,
Map<String,TAuditExportStandardVo> itemStandardMap,
Map<String,TAuditExportItemVo> itemAnnualBonusMap,
Map<String,TAuditExportItemVo> itemPersionTaxMap,
Map<String,TAuditExportItemVo> itemAnnuityMap,
Map<String,TAuditExportItemVo> itemSubsidyMap) {
TSalaryAccountItemExportVo voTemp; TSalaryAccountItemExportVo voTemp;
TAuditExportStandardVo standardVo;
TAuditExportItemVo itemVo;
for (TSalaryAccountExportVo vo: list){ for (TSalaryAccountExportVo vo: list){
voTemp = itemExportVoMap.get(vo.getId()); voTemp = itemExportVoMap.get(vo.getId());
if (Common.isNotNull(voTemp)){ if (Common.isNotNull(voTemp)){
vo.setPdeductionMoney(voTemp.getPdeductionMoney()); vo.setPdeductionMoney(voTemp.getPdeductionMoney());
vo.setPdeductionDetail(voTemp.getPdeductionDetail()); vo.setPdeductionDetail(voTemp.getPdeductionDetail());
} }
standardVo = itemStandardMap.get(vo.getSalaryFormId());
if (Common.isNotNull(standardVo)){
vo.setStatus(standardVo.getStatus());
vo.setBusinessPrimaryType(standardVo.getBusinessPrimaryTyp());
vo.setBusinessSecondType(standardVo.getBusinessSecondType());
vo.setBusinessThirdType(standardVo.getBusinessThirdType());
}
itemVo = itemAnnualBonusMap.get(vo.getId());
if (Common.isNotNull(itemVo)){
vo.setAnnualBonus(itemVo.getAnnualBonus());
}
itemVo = itemPersionTaxMap.get(vo.getId());
if (Common.isNotNull(itemVo)){
vo.setExemptionPersionTax(itemVo.getExemptionPersionTax());
}
itemVo = itemAnnuityMap.get(vo.getId());
if (Common.isNotNull(itemVo)){
vo.setEnterpriseAnnuity(itemVo.getEnterpriseAnnuity());
}
itemVo = itemSubsidyMap.get(vo.getId());
if (Common.isNotNull(itemVo)){
vo.setPhoneSubsidy(itemVo.getPhoneSubsidy());
}
} }
} }
......
...@@ -804,6 +804,7 @@ public class TSalaryStandardOriginalServiceImpl extends ServiceImpl<TSalaryStand ...@@ -804,6 +804,7 @@ public class TSalaryStandardOriginalServiceImpl extends ServiceImpl<TSalaryStand
return this.getExcelContent(file, excelVo); return this.getExcelContent(file, excelVo);
} catch (Exception e){ } catch (Exception e){
log.error("薪资原表识别异常:",e); log.error("薪资原表识别异常:",e);
return R.failed("薪资原表识别异常,请检查表数据");
} finally { } finally {
importAtomicInteger.decrementAndGet(); importAtomicInteger.decrementAndGet();
} }
...@@ -813,7 +814,6 @@ public class TSalaryStandardOriginalServiceImpl extends ServiceImpl<TSalaryStand ...@@ -813,7 +814,6 @@ public class TSalaryStandardOriginalServiceImpl extends ServiceImpl<TSalaryStand
log.error("超出阈值:"+ ResultConstants.IMPORT_DOWN_LOAD_DATA); log.error("超出阈值:"+ ResultConstants.IMPORT_DOWN_LOAD_DATA);
return R.failed("薪资原表识别," + ResultConstants.IMPORT_DOWN_LOAD_DATA); return R.failed("薪资原表识别," + ResultConstants.IMPORT_DOWN_LOAD_DATA);
} }
return R.failed("薪资原表识别中," + ResultConstants.IMPORT_DOWN_LOAD_DATA);
} }
/** /**
......
...@@ -1583,6 +1583,7 @@ ...@@ -1583,6 +1583,7 @@
<select id="auditExportDiy" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryAccountExportVo" <select id="auditExportDiy" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryAccountExportVo"
parameterType="com.yifu.cloud.plus.v1.yifu.salary.entity.TSalaryAccount"> parameterType="com.yifu.cloud.plus.v1.yifu.salary.entity.TSalaryAccount">
select select
a.SALARY_FORM_ID as salaryFormId,
a.id, a.id,
case a.FORM_TYPE when '0' then '薪资' when '1' then '绩效' when '3' then '劳务费' when '4' then '稿酬' else '其他' end as formType, case a.FORM_TYPE when '0' then '薪资' when '1' then '绩效' when '3' then '劳务费' when '4' then '稿酬' else '其他' end as formType,
a.EMP_PHONE as empPhone, a.EMP_PHONE as empPhone,
...@@ -1598,13 +1599,10 @@ ...@@ -1598,13 +1599,10 @@
a.EMP_IDCARD as empIdcard, a.EMP_IDCARD as empIdcard,
if(a.RELAY_SALARY_UNIT is not null and a.RELAY_SALARY_UNIT != 0, a.RELAY_SALARY_UNIT, ifnull(a.RELAY_SALARY,0)) as relaySalary, if(a.RELAY_SALARY_UNIT is not null and a.RELAY_SALARY_UNIT != 0, a.RELAY_SALARY_UNIT, ifnull(a.RELAY_SALARY,0)) as relaySalary,
a.ACTUAL_SALARY as actualSalary, a.ACTUAL_SALARY as actualSalary,
annualBonus.SALARY_MONEY as annualBonus,
ifnull(a.SALARY_TAX,0) + ifnull(a.SALARY_TAX_UNIT,0) as salaryTax, ifnull(a.SALARY_TAX,0) + ifnull(a.SALARY_TAX_UNIT,0) as salaryTax,
a.ANNUAL_BONUS_TAX as annualBonusTax, a.ANNUAL_BONUS_TAX as annualBonusTax,
a.PERSON_SOCIAL as personSocial, a.PERSON_SOCIAL as personSocial,
a.PERSON_FUND as personFund, a.PERSON_FUND as personFund,
exemptionPersionTax.SALARY_MONEY as exemptionPersionTax,
enterpriseAnnuity.SALARY_MONEY as enterpriseAnnuity,
a.UNIT_SOCIAL as unitSocial, a.UNIT_SOCIAL as unitSocial,
a.UNIT_FUND as unitFund, a.UNIT_FUND as unitFund,
a.SUM_BABY_MONEY as sumBabyMoney, a.SUM_BABY_MONEY as sumBabyMoney,
...@@ -1616,22 +1614,21 @@ ...@@ -1616,22 +1614,21 @@
a.SUM_SUPPORT_ELDERLY_MONEY as sumSupportElderlyMoney, a.SUM_SUPPORT_ELDERLY_MONEY as sumSupportElderlyMoney,
a.COST_REDUCTION as costReduction, a.COST_REDUCTION as costReduction,
a.CREATE_NAME as createName, a.CREATE_NAME as createName,
/*GROUP_CONCAT(pdeduction.CN_NAME,':',pdeduction.SALARY_MONEY SEPARATOR ';') pdeductionDetail, if(a.PAY_SETTLE_FLAG = '0','已结算',if(a.PAY_SETTLE_FLAG = '1','结算中',if(a.PAY_SETTLE_FLAG = '2','未结算','-'))) paySettleFlag
sum(ifnull(pdeduction.SALARY_MONEY,0)) pdeductionMoney,*/ /*
if(a.PAY_SETTLE_FLAG = '0','已结算',if(a.PAY_SETTLE_FLAG = '1','结算中',if(a.PAY_SETTLE_FLAG = '2','未结算','-'))) paySettleFlag,
case s.STATUS when 0 then '待提交' when 1 then '待审核' when 2 then '待推送明细' when 3 then '已推送待发放' when 4 then '已发放' when 5 then '审核不通过' when 6 then '确认不通过' when 7 then '财务退回' when 10 then '推送失败' when 11 then '已审核生成收入中' when 12 then '已审核生成收入失败' else '-' end as status
,phoneSubsidy.SALARY_MONEY as phoneSubsidy ,phoneSubsidy.SALARY_MONEY as phoneSubsidy
,s.BUSINESS_PRIMARY_TYPE as businessPrimaryType annualBonus.SALARY_MONEY as annualBonus,
,s.BUSINESS_SECOND_TYPE as businessSecondType exemptionPersionTax.SALARY_MONEY as exemptionPersionTax,
,s.BUSINESS_THIRD_TYPE as businessThirdType enterpriseAnnuity.SALARY_MONEY as enterpriseAnnuity,
*/
from from
t_salary_account a t_salary_account a
left join t_salary_standard s on a.SALARY_FORM_ID = s.id /*left join t_salary_standard s on a.SALARY_FORM_ID = s.id
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 annualBonus on annualBonus.SALARY_ACCOUNT_ID = a.id and annualBonus.JAVA_FIED_NAME = 'annualBonus'
left join t_salary_account_item exemptionPersionTax on exemptionPersionTax.SALARY_ACCOUNT_ID = a.id and exemptionPersionTax.JAVA_FIED_NAME='exemptionPersionTax' left join t_salary_account_item exemptionPersionTax on exemptionPersionTax.SALARY_ACCOUNT_ID = a.id and exemptionPersionTax.JAVA_FIED_NAME='exemptionPersionTax'
left join t_salary_account_item enterpriseAnnuity on enterpriseAnnuity.SALARY_ACCOUNT_ID = a.id and enterpriseAnnuity.JAVA_FIED_NAME='enterpriseAnnuity' left join t_salary_account_item enterpriseAnnuity on enterpriseAnnuity.SALARY_ACCOUNT_ID = a.id and enterpriseAnnuity.JAVA_FIED_NAME='enterpriseAnnuity'
/*left join t_salary_account_item pdeduction on pdeduction.SALARY_ACCOUNT_ID = a.id and pdeduction.JAVA_FIED_NAME='pdeduction'*/ left join t_salary_account_item pdeduction on pdeduction.SALARY_ACCOUNT_ID = a.id and pdeduction.JAVA_FIED_NAME='pdeduction'
left join t_salary_account_item phoneSubsidy on phoneSubsidy.SALARY_ACCOUNT_ID = a.id and phoneSubsidy.JAVA_FIED_NAME='phoneSubsidy' left join t_salary_account_item phoneSubsidy on phoneSubsidy.SALARY_ACCOUNT_ID = a.id and phoneSubsidy.JAVA_FIED_NAME='phoneSubsidy'*/
<where> <where>
a.DELETE_FLAG = 0 a.DELETE_FLAG = 0
<include refid="where_export"/> <include refid="where_export"/>
...@@ -1645,7 +1642,84 @@ ...@@ -1645,7 +1642,84 @@
</where> </where>
</select> </select>
<select id="auditExportPhoneSubsidy" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TAuditExportItemVo">
select
phoneSubsidy.SALARY_ACCOUNT_ID as salaryAccountId,
phoneSubsidy.SALARY_MONEY as phoneSubsidy
FROM
t_salary_account_item phoneSubsidy
where
phoneSubsidy.JAVA_FIED_NAME='phoneSubsidy'
<if test="idList != null and idList.size>0">
AND phoneSubsidy.SALARY_ACCOUNT_ID in
<foreach item="idStr" index="index" collection="idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</select>
<select id="auditExportEnterpriseAnnuity" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TAuditExportItemVo">
select
enterpriseAnnuity.SALARY_ACCOUNT_ID as salaryAccountId,
enterpriseAnnuity.SALARY_MONEY as enterpriseAnnuity
FROM
t_salary_account_item enterpriseAnnuity
where
enterpriseAnnuity.JAVA_FIED_NAME='enterpriseAnnuity'
<if test="idList != null and idList.size>0">
AND enterpriseAnnuity.SALARY_ACCOUNT_ID in
<foreach item="idStr" index="index" collection="idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</select>
<select id="auditExportExemptionPersionTax" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TAuditExportItemVo">
select
exemptionPersionTax.SALARY_ACCOUNT_ID as salaryAccountId,
exemptionPersionTax.SALARY_MONEY as exemptionPersionTax
FROM
t_salary_account_item exemptionPersionTax
where
exemptionPersionTax.JAVA_FIED_NAME='exemptionPersionTax'
<if test="idList != null and idList.size>0">
AND exemptionPersionTax.SALARY_ACCOUNT_ID in
<foreach item="idStr" index="index" collection="idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</select>
<select id="auditExportAnnualBonus" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TAuditExportItemVo">
select
annualBonus.SALARY_ACCOUNT_ID as salaryAccountId,
annualBonus.SALARY_MONEY as annualBonus
FROM
t_salary_account_item annualBonus
where
annualBonus.JAVA_FIED_NAME = 'annualBonus'
<if test="idList != null and idList.size>0">
AND annualBonus.SALARY_ACCOUNT_ID in
<foreach item="idStr" index="index" collection="idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</select>
<select id="auditExportStandard" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TAuditExportStandardVo">
select
s.id as salaryFormId
,case s.STATUS when 0 then '待提交' when 1 then '待审核' when 2 then '待推送明细' when 3 then '已推送待发放' when 4 then '已发放' when 5 then '审核不通过' when 6 then '确认不通过' when 7 then '财务退回' when 10 then '推送失败' when 11 then '已审核生成收入中' when 12 then '已审核生成收入失败' else '-' end as status
,s.BUSINESS_PRIMARY_TYPE as businessPrimaryType
,s.BUSINESS_SECOND_TYPE as businessSecondType
,s.BUSINESS_THIRD_TYPE as businessThirdType
FROM
t_salary_standard s
where
<if test="idList != null and idList.size>0">
s.id in
<foreach item="idStr" index="index" collection="idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</select>
<select id="auditExportSelectItems" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryAccountItemExportVo"> <select id="auditExportSelectItems" resultType="com.yifu.cloud.plus.v1.yifu.salary.vo.TSalaryAccountItemExportVo">
select select
GROUP_CONCAT(pdeduction.CN_NAME,':',pdeduction.SALARY_MONEY SEPARATOR ';') pdeductionDetail, GROUP_CONCAT(pdeduction.CN_NAME,':',pdeduction.SALARY_MONEY SEPARATOR ';') pdeductionDetail,
......
...@@ -77,7 +77,8 @@ public class SysHouseHoldInfoServiceImpl extends ServiceImpl<SysHouseHoldInfoMap ...@@ -77,7 +77,8 @@ public class SysHouseHoldInfoServiceImpl extends ServiceImpl<SysHouseHoldInfoMap
*/ */
@Override @Override
public R<Boolean> saveInfo(SysHouseHoldInfo sysHouseHoldInfo) { public R<Boolean> saveInfo(SysHouseHoldInfo sysHouseHoldInfo) {
//户名称去空格
sysHouseHoldInfo.setName(sysHouseHoldInfo.getName().replace(" ",""));
SysHouseHoldInfo info = this.getOne(Wrappers.<SysHouseHoldInfo>query().lambda() SysHouseHoldInfo info = this.getOne(Wrappers.<SysHouseHoldInfo>query().lambda()
.eq(SysHouseHoldInfo::getType,sysHouseHoldInfo.getType()) .eq(SysHouseHoldInfo::getType,sysHouseHoldInfo.getType())
.eq(SysHouseHoldInfo::getName,sysHouseHoldInfo.getName()) .eq(SysHouseHoldInfo::getName,sysHouseHoldInfo.getName())
...@@ -131,6 +132,8 @@ public class SysHouseHoldInfoServiceImpl extends ServiceImpl<SysHouseHoldInfoMap ...@@ -131,6 +132,8 @@ public class SysHouseHoldInfoServiceImpl extends ServiceImpl<SysHouseHoldInfoMap
**/ **/
@Override @Override
public R<Boolean> updateByIdAsso(SysHouseHoldInfo hold) { public R<Boolean> updateByIdAsso(SysHouseHoldInfo hold) {
//户名称去空格
hold.setName(hold.getName().replace(" ",""));
if (Common.isEmpty(hold.getId())){ if (Common.isEmpty(hold.getId())){
return R.failed(CommonConstants.PARAM_INFO_ERROR); return R.failed(CommonConstants.PARAM_INFO_ERROR);
} }
......
...@@ -2073,6 +2073,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2073,6 +2073,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
contract.setEmpName(excel.getEmpName()); contract.setEmpName(excel.getEmpName());
contract.setWorkingHours(excel.getWorkingHours()); contract.setWorkingHours(excel.getWorkingHours());
contract.setContractTerm(excel.getContractTerm()); contract.setContractTerm(excel.getContractTerm());
contract.setTryPeriod(excel.getTryPeriod());
if (Common.isNotNull(excel.getSocialHousehold())){ if (Common.isNotNull(excel.getSocialHousehold())){
contract.setContractParty(excel.getSocialHousehold()); contract.setContractParty(excel.getSocialHousehold());
} }
...@@ -3249,6 +3250,22 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3249,6 +3250,22 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_REDUCE_SOCIAL_STATUS_ERROR))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_REDUCE_SOCIAL_STATUS_ERROR)));
return true; return true;
} }
//派减部分办理失败需要额外判断是否有办理成功的项可供派减;明细项办理状态:0待办理1办理成功2办理失败3已派减4派减失败5派减待办理
if (!CommonConstants.ONE_STRING.equals(socialFund.getPensionHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getPensionHandle())
&&!CommonConstants.ONE_STRING.equals(socialFund.getMedicalHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getMedicalHandle())
&&!CommonConstants.ONE_STRING.equals(socialFund.getWorkInjuryHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getWorkInjuryHandle())
&&!CommonConstants.ONE_STRING.equals(socialFund.getBirthHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getBirthHandle())
&&!CommonConstants.ONE_STRING.equals(socialFund.getBigailmentHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getBigailmentHandle())
&&!CommonConstants.ONE_STRING.equals(socialFund.getUnemployHandle())
&&!CommonConstants.FOUR_STRING.equals(socialFund.getUnemployHandle())){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_REDUCE_SOCIAL_STATUS_ERROR)));
return true;
}
if (!excel.getDepartNo().equals(socialFund.getSettleDomainCode())){ if (!excel.getDepartNo().equals(socialFund.getSettleDomainCode())){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_REDUCE_SOCIAL_DEPARTNO_ERROR))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_REDUCE_SOCIAL_DEPARTNO_ERROR)));
return true; return true;
......
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