Commit 4eb91595 authored by hongguangwu's avatar hongguangwu

Merge branch 'develop'

parents f3f37b88 dd2e76e7
...@@ -567,4 +567,17 @@ public class TSettleDomain extends BaseEntity { ...@@ -567,4 +567,17 @@ public class TSettleDomain extends BaseEntity {
@Schema(description ="登录账号") @Schema(description ="登录账号")
private String csLoginName; private String csLoginName;
/**
* 项目负责人
*/
@Schema(description = "项目负责人",name = "projectManager")
private String projectManager ;
/**
* 项目负责人
*/
@TableField(exist = false)
@Schema(description = "项目负责人姓名")
private String projectManagerName ;
} }
...@@ -463,4 +463,10 @@ public class TSettleDomainEkpVo implements Serializable { ...@@ -463,4 +463,10 @@ public class TSettleDomainEkpVo implements Serializable {
*/ */
@Schema(description = "事业部",name = "division") @Schema(description = "事业部",name = "division")
private String division ; private String division ;
/**
* 项目负责人
*/
@Schema(description = "项目负责人",name = "projectManager")
private String projectManager ;
} }
...@@ -25,4 +25,10 @@ public class TSettleDomainUpServerTeamVo implements Serializable { ...@@ -25,4 +25,10 @@ public class TSettleDomainUpServerTeamVo implements Serializable {
*/ */
@Schema(description = "EKP的服务团队", name = "serviceTeam") @Schema(description = "EKP的服务团队", name = "serviceTeam")
private String serviceTeam; private String serviceTeam;
/**
* 项目负责人
*/
@Schema(description = "项目负责人",name = "projectManager")
private String projectManager ;
} }
...@@ -132,7 +132,7 @@ public class TSettleDomainController { ...@@ -132,7 +132,7 @@ public class TSettleDomainController {
@Operation(summary = "通过id查询", description = "通过id查询") @Operation(summary = "通过id查询", description = "通过id查询")
@GetMapping("/{id}") @GetMapping("/{id}")
public R<TSettleDomain> getById(@PathVariable("id") String id) { public R<TSettleDomain> getById(@PathVariable("id") String id) {
return R.ok(tSettleDomainService.getById(id)); return tSettleDomainService.getByIdAsso(id);
} }
/** /**
......
...@@ -140,4 +140,6 @@ public interface TSettleDomainService extends IService<TSettleDomain> { ...@@ -140,4 +140,6 @@ public interface TSettleDomainService extends IService<TSettleDomain> {
R<Boolean> changeIssueStatus(ChangeIssueStatusVo changeIssueStatusVo); R<Boolean> changeIssueStatus(ChangeIssueStatusVo changeIssueStatusVo);
R<Boolean> updateProjectCsInfo(List<TDomainUpCsVo> list); R<Boolean> updateProjectCsInfo(List<TDomainUpCsVo> list);
R<TSettleDomain> getByIdAsso(String id);
} }
...@@ -531,6 +531,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi ...@@ -531,6 +531,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
@Override @Override
public R batchSendMessage(List<SendMessageUpdateVo> voList,String type) { public R batchSendMessage(List<SendMessageUpdateVo> voList,String type) {
if (Common.isNotNull(voList) && voList.size() >200) {
return R.failed("短信批量发送单次最多两百条");
}
//获取短信待发放和信息待填写的数据 //获取短信待发放和信息待填写的数据
List<String> errorList = new ArrayList<>(); List<String> errorList = new ArrayList<>();
if (CommonConstants.ONE_STRING.equals(type)) { if (CommonConstants.ONE_STRING.equals(type)) {
...@@ -675,6 +678,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi ...@@ -675,6 +678,9 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
public R<EmployeeInfoMsgVo> getEmployeeInfo(String id) { public R<EmployeeInfoMsgVo> getEmployeeInfo(String id) {
//获取人员档案id //获取人员档案id
EmployeeInfoMsgVo msgInfoVo = baseMapper.getEmployeeArchivesInfo(id); EmployeeInfoMsgVo msgInfoVo = baseMapper.getEmployeeArchivesInfo(id);
if (Common.isEmpty(msgInfoVo)) {
return R.failed(CommonConstants.PARAM_IS_NOT_ERROR);
}
//获取预入职信息,如果有的话提示 //获取预入职信息,如果有的话提示
TPreEmpMain empMain = empMainMapper.selectOne(Wrappers.<TPreEmpMain>query().lambda() TPreEmpMain empMain = empMainMapper.selectOne(Wrappers.<TPreEmpMain>query().lambda()
.eq(TPreEmpMain::getEmpIdcard,msgInfoVo.getCard()) .eq(TPreEmpMain::getEmpIdcard,msgInfoVo.getCard())
......
...@@ -767,7 +767,9 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr ...@@ -767,7 +767,9 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
//根据项目编码和身份证号查询预入职列表 //根据项目编码和身份证号查询预入职列表
TPreEmpMain empMain = preEmpMainMapper.selectOne(Wrappers.<TPreEmpMain>query() TPreEmpMain empMain = preEmpMainMapper.selectOne(Wrappers.<TPreEmpMain>query()
.lambda().eq(TPreEmpMain::getEmpIdcard, contractInfo.getEmpIdcard()) .lambda().eq(TPreEmpMain::getEmpIdcard, contractInfo.getEmpIdcard())
.eq(TPreEmpMain::getDeptNo, contractInfo.getDeptNo())); .eq(TPreEmpMain::getDeptNo, contractInfo.getDeptNo())
.ne(TPreEmpMain::getStatus,CommonConstants.FIVE_STRING)
.last(CommonConstants.LAST_ONE_SQL));
if (Optional.ofNullable(empMain).isPresent()) { if (Optional.ofNullable(empMain).isPresent()) {
//查询预入职项目档案表 //查询预入职项目档案表
TPreEmployeeProject preEmployeeProject = preEmployeeProjectMapper.selectOne(Wrappers.<TPreEmployeeProject>query() TPreEmployeeProject preEmployeeProject = preEmployeeProjectMapper.selectOne(Wrappers.<TPreEmployeeProject>query()
...@@ -1675,7 +1677,9 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr ...@@ -1675,7 +1677,9 @@ public class TEmployeeContractInfoServiceImpl extends ServiceImpl<TEmployeeContr
//根据项目编码和身份证号查询预入职列表 //根据项目编码和身份证号查询预入职列表
TPreEmpMain empMain = preEmpMainMapper.selectOne(Wrappers.<TPreEmpMain>query() TPreEmpMain empMain = preEmpMainMapper.selectOne(Wrappers.<TPreEmpMain>query()
.lambda().eq(TPreEmpMain::getEmpIdcard, contract.getEmpIdcard()) .lambda().eq(TPreEmpMain::getEmpIdcard, contract.getEmpIdcard())
.eq(TPreEmpMain::getDeptNo, contract.getDeptNo())); .eq(TPreEmpMain::getDeptNo, contract.getDeptNo())
.ne(TPreEmpMain::getStatus,CommonConstants.FIVE_STRING)
.last(CommonConstants.LAST_ONE_SQL));
if (Optional.ofNullable(empMain).isPresent()) { if (Optional.ofNullable(empMain).isPresent()) {
//查询预入职项目档案表 //查询预入职项目档案表
TPreEmployeeProject preEmployeeProject = preEmployeeProjectMapper.selectOne(Wrappers.<TPreEmployeeProject>query() TPreEmployeeProject preEmployeeProject = preEmployeeProjectMapper.selectOne(Wrappers.<TPreEmployeeProject>query()
......
...@@ -203,7 +203,7 @@ public class TEmployeeProjectBelongDeptServiceImpl extends ServiceImpl<TEmployee ...@@ -203,7 +203,7 @@ public class TEmployeeProjectBelongDeptServiceImpl extends ServiceImpl<TEmployee
dept.setId(vo.getProjectId()); dept.setId(vo.getProjectId());
dept.setEmpDeptid(vo.getDepartId().toString()); dept.setEmpDeptid(vo.getDepartId().toString());
dept.setEmpDeptname(vo.getDepartName()); dept.setEmpDeptname(vo.getDepartName());
this.save(dept); this.saveOrUpdate(dept);
} else { } else {
this.removeById(vo.getProjectId()); this.removeById(vo.getProjectId());
} }
......
...@@ -423,13 +423,13 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T ...@@ -423,13 +423,13 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
* @return * @return
**/ **/
public boolean saveForEkp(List<SysUser> userIds, TSettleDomain domain){ public boolean saveForEkp(List<SysUser> userIds, TSettleDomain domain){
// 1. 先清除现有的这些人的项目权限
permissonMapper.delete(Wrappers.<TCutsomerDataPermisson>query().lambda()
.in(TCutsomerDataPermisson::getUserId,userIds)
.eq(TCutsomerDataPermisson::getSettleDomainId,domain.getId()));
// 2.新增新的项目人员权限 // 2.新增新的项目人员权限
TCutsomerDataPermisson pm; TCutsomerDataPermisson pm;
if (Common.isNotNull(userIds)) { if (Common.isNotNull(userIds)) {
// 1. 先清除现有的这些人的项目权限
permissonMapper.delete(Wrappers.<TCutsomerDataPermisson>query().lambda()
.in(TCutsomerDataPermisson::getUserId,userIds.stream().map(SysUser::getUserId).collect(Collectors.toList()))
.eq(TCutsomerDataPermisson::getSettleDomainId,domain.getId()));
for (SysUser user : userIds){ for (SysUser user : userIds){
pm = new TCutsomerDataPermisson(); pm = new TCutsomerDataPermisson();
pm.setStatus(CommonConstants.ZERO_STRING); pm.setStatus(CommonConstants.ZERO_STRING);
...@@ -507,6 +507,9 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T ...@@ -507,6 +507,9 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
domain.setDepartName(tSettleDomainInfo.getDepartName()); domain.setDepartName(tSettleDomainInfo.getDepartName());
domain.setId(tSettleDomainInfo.getId()); domain.setId(tSettleDomainInfo.getId());
initServerTeamPermission(domain); initServerTeamPermission(domain);
tSettleDomainInfo.setProjectManagerName(domain.getProjectManagerName());
tSettleDomainInfo.setProjectManager(domain.getProjectManager());
baseMapper.updateById(tSettleDomainInfo);
} }
} }
return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS); return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS);
...@@ -518,12 +521,30 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T ...@@ -518,12 +521,30 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS); return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS);
} }
/**
* @Author fxj
* @Description 同步 项目人员权限(服务团队、项目负责人)
* @Date 18:07 2025/3/31
**/
private void initServerTeamPermission(TSettleDomain domain) { private void initServerTeamPermission(TSettleDomain domain) {
R<SysUserListVo> res;
if (Common.isNotNull(domain.getServiceTeam())){ if (Common.isNotNull(domain.getServiceTeam())){
R<SysUserListVo> res = upmsDaprUtils.getUserIdsByUserNames(domain.getServiceTeam()); res = upmsDaprUtils.getUserIdsByUserNames(domain.getServiceTeam());
if (Common.isNotNull(res) && Common.isNotNull(res.getData()) && Common.isNotNull(res.getData().getUserList())){
// 先清理缓存
this.removeSettleCache(null, res.getData().getUserIds());
saveForEkp(res.getData().getUserList(), domain);
}
}
if (Common.isNotNull(domain.getProjectManager())){
res = upmsDaprUtils.getUserIdsByUserNames(domain.getProjectManager());
if (Common.isNotNull(res) && Common.isNotNull(res.getData()) && Common.isNotNull(res.getData().getUserList())){ if (Common.isNotNull(res) && Common.isNotNull(res.getData()) && Common.isNotNull(res.getData().getUserList())){
// 先清理缓存 // 先清理缓存
this.removeSettleCache(null, res.getData().getUserIds()); this.removeSettleCache(null, res.getData().getUserIds());
//项目负责人目前只有一个,如果有多个这个地方需要特殊处理
if (res.getData().getUserList().size() >= CommonConstants.ONE_INT){
domain.setProjectManagerName(res.getData().getUserList().get(0).getNickname());
}
saveForEkp(res.getData().getUserList(), domain); saveForEkp(res.getData().getUserList(), domain);
} }
} }
...@@ -564,6 +585,35 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T ...@@ -564,6 +585,35 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS); return R.ok(Boolean.TRUE,CommonConstants.RESULT_DATA_SUCESS);
} }
/**
* @Author fxj
* @Description 获取项目基本信息,含项目负责人
* @Date 18:05 2025/3/31
**/
@Override
public R<TSettleDomain> getByIdAsso(String id) {
TSettleDomain domain = baseMapper.selectById(id);
if (Common.isNotNull(domain) && Common.isNotNull(domain.getProjectManager())){
if (Common.isNotNull(domain.getProjectManager())){
R<SysUserListVo> res = upmsDaprUtils.getUserIdsByUserNames(domain.getProjectManager());
if (Common.isNotNull(res) && Common.isNotNull(res.getData()) && Common.isNotNull(res.getData().getUserList())){
StringBuilder manager = new StringBuilder();
res.getData().getUserList().forEach(user->{
if (Common.isNotNull(user.getUserId())){
if (Common.isEmpty(manager.toString())){
manager.append(user.getNickname());
}else if (Common.isNotNull(user.getNickname())){
manager.append(",").append(user.getNickname());
}
}
});
domain.setProjectManager(manager.toString());
}
}
}
return R.ok(domain);
}
@Override @Override
public List<String> getAllDeptByCustomerLoginName(String userLoginName) { public List<String> getAllDeptByCustomerLoginName(String userLoginName) {
return baseMapper.getAllDeptByCustomerLoginName(userLoginName); return baseMapper.getAllDeptByCustomerLoginName(userLoginName);
......
...@@ -26,7 +26,7 @@ mybatis-plus: ...@@ -26,7 +26,7 @@ mybatis-plus:
logic-not-delete-value: 0 logic-not-delete-value: 0
configuration: configuration:
map-underscore-to-camel-case: true map-underscore-to-camel-case: true
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
# spring security 配置 # spring security 配置
security: security:
......
...@@ -186,7 +186,7 @@ ...@@ -186,7 +186,7 @@
inner join t_employee_info b on a.EMP_ID = b.id inner join t_employee_info b on a.EMP_ID = b.id
inner join t_settle_domain c on a.DEPT_NO = c.DEPART_NO inner join t_settle_domain c on a.DEPT_NO = c.DEPART_NO
<where> <where>
a.delete_flag = '0' and a.IS_COMPLETE = '1' a.delete_flag = '0' and a.IS_COMPLETE = '1' and a.project_status = 0
<include refid="employeeRegistrationPre_where"/> <include refid="employeeRegistrationPre_where"/>
</where> </where>
order by a.CREATE_TIME desc order by a.CREATE_TIME desc
......
...@@ -636,112 +636,29 @@ ...@@ -636,112 +636,29 @@
<update id="updateExcelEmpProject" parameterType="java.util.List"> <update id="updateExcelEmpProject" parameterType="java.util.List">
update t_employee_project update t_employee_project
<trim prefix="set" suffixOverrides=","> <set>
<trim prefix="EMP_LABEL =case" suffix="end,"> <foreach collection="list" item="i" separator=",">
<foreach collection="list" item="i" index="index"> EMP_LABEL = COALESCE(#{i.empLabel}, EMP_LABEL),
<if test="i.empLabel!=null"> EMP_NATRUE = COALESCE(#{i.empNatrue}, EMP_NATRUE),
when ID=#{i.id} then #{i.empLabel} EMP_IDCARD = COALESCE(#{i.empIdcard}, EMP_IDCARD),
</if> PROJECT_STATUS = 0,
</foreach> UPDATE_TIME = now(),
</trim> UPDATE_BY = COALESCE(#{i.updateBy}, UPDATE_BY),
<trim prefix="EMP_NATRUE =case" suffix="end,"> DEPT_NO = COALESCE(#{i.deptNo}, DEPT_NO),
<foreach collection="list" item="i" index="index"> CONTRACT_TYPE = COALESCE(#{i.contractType}, CONTRACT_TYPE),
<if test="i.empNatrue!=null"> WORKING_HOURS = COALESCE(#{i.workingHours}, WORKING_HOURS),
when ID=#{i.id} then #{i.empNatrue} POST = COALESCE(#{i.post}, POST),
</if> TRY_PERIOD = COALESCE(#{i.tryPeriod}, TRY_PERIOD),
</foreach> ENJOIN_DATE = COALESCE(#{i.enjoinDate}, ENJOIN_DATE),
</trim> BANK_NAME = COALESCE(#{i.bankName}, BANK_NAME),
<trim prefix="EMP_IDCARD =case" suffix="end,"> BANK_NO = COALESCE(#{i.bankNo}, BANK_NO),
<foreach collection="list" item="i" index="index"> BANK_SUB_NAME = COALESCE(#{i.bankSubName}, BANK_SUB_NAME)
<if test="i.empIdcard!=null"> </foreach>
when ID=#{i.id} then #{i.empIdcard} </set>
</if> where id in
</foreach> <foreach item="i" index="index" collection="list" open="("
</trim> separator="," close=")">
<trim prefix="PROJECT_STATUS =case" suffix="end,"> #{i.id}
<foreach collection="list" item="i" index="index">
when ID=#{i.id} then 0
</foreach>
</trim>
<trim prefix="UPDATE_TIME =case" suffix="end,">
<foreach collection="list" item="i" index="index">
when ID=#{i.id} then now()
</foreach>
</trim>
<trim prefix="UPDATE_BY =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.updateBy!=null">
when ID=#{i.id} then #{i.updateBy}
</if>
</foreach>
</trim>
<trim prefix="DEPT_NO =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.deptNo!=null">
when ID=#{i.id} then #{i.deptNo}
</if>
</foreach>
</trim>
<trim prefix="CONTRACT_TYPE =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.contractType!=null">
when ID=#{i.id} then #{i.contractType}
</if>
</foreach>
</trim>
<trim prefix="WORKING_HOURS =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.workingHours!=null">
when ID=#{i.id} then #{i.workingHours}
</if>
</foreach>
</trim>
<trim prefix="POST =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.post!=null">
when ID=#{i.id} then #{i.post}
</if>
</foreach>
</trim>
<trim prefix="TRY_PERIOD =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.tryPeriod!=null">
when ID=#{i.id} then #{i.tryPeriod}
</if>
</foreach>
</trim>
<trim prefix="ENJOIN_DATE =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.enjoinDate!=null">
when ID=#{i.id} then #{i.enjoinDate}
</if>
</foreach>
</trim>
<trim prefix="BANK_NAME =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.bankName!=null">
when ID=#{i.id} then #{i.bankName}
</if>
</foreach>
</trim>
<trim prefix="BANK_NO =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.bankNo!=null">
when ID=#{i.id} then #{i.bankNo}
</if>
</foreach>
</trim>
<trim prefix="BANK_SUB_NAME =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.bankSubName!=null">
when ID=#{i.id} then #{i.bankSubName}
</if>
</foreach>
</trim>
</trim>
where
<foreach collection="list" separator="or" item="i" index="index" >
ID=#{i.id}
</foreach> </foreach>
</update> </update>
<insert id="insertExcelEmpProject" parameterType="java.util.List"> <insert id="insertExcelEmpProject" parameterType="java.util.List">
...@@ -831,9 +748,10 @@ ...@@ -831,9 +748,10 @@
</foreach> </foreach>
</trim> </trim>
</trim> </trim>
where where id in
<foreach collection="list" separator="or" item="i" index="index" > <foreach item="i" index="index" collection="list" open="("
ID=#{i.id} separator="," close=")">
#{i.id}
</foreach> </foreach>
</update> </update>
<!--查询部门编码和最大员工数--> <!--查询部门编码和最大员工数-->
......
...@@ -105,6 +105,9 @@ ...@@ -105,6 +105,9 @@
<result property="csName" column="cs_name"/> <result property="csName" column="cs_name"/>
<result property="csPhone" column="cs_phone"/> <result property="csPhone" column="cs_phone"/>
<result property="csLoginName" column="cs_login_name"/> <result property="csLoginName" column="cs_login_name"/>
<!-- 2025-03-31 FXJ V1.7.9 -->
<result property="projectManager" column="PROJECT_MANAGER"/>
</resultMap> </resultMap>
<resultMap id="tSettleDomainTwoMap" type="com.yifu.cloud.plus.v1.yifu.archives.vo.SecondBelongVo"> <resultMap id="tSettleDomainTwoMap" type="com.yifu.cloud.plus.v1.yifu.archives.vo.SecondBelongVo">
...@@ -194,7 +197,8 @@ ...@@ -194,7 +197,8 @@
a.DIVISION, a.DIVISION,
a.cs_name, a.cs_name,
a.cs_phone, a.cs_phone,
a.cs_login_name a.cs_login_name,
a.PROJECT_MANAGER
</sql> </sql>
<resultMap id="tSettleDomainSelectVoMap" type="com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo"> <resultMap id="tSettleDomainSelectVoMap" type="com.yifu.cloud.plus.v1.yifu.archives.vo.TSettleDomainSelectVo">
...@@ -234,6 +238,9 @@ ...@@ -234,6 +238,9 @@
<result property="csName" column="cs_name"/> <result property="csName" column="cs_name"/>
<result property="csPhone" column="cs_phone"/> <result property="csPhone" column="cs_phone"/>
<result property="csLoginName" column="cs_login_name"/> <result property="csLoginName" column="cs_login_name"/>
<!-- 2025-03-31 FXJ V1.7.9 -->
<result property="projectManager" column="PROJECT_MANAGER"/>
</resultMap> </resultMap>
<select id="getPage" resultMap="tSettleDomainMap"> <select id="getPage" resultMap="tSettleDomainMap">
...@@ -434,7 +441,7 @@ ...@@ -434,7 +441,7 @@
a.DIVISION, a.DIVISION,
a.cs_name, a.cs_name,
a.cs_phone, a.cs_phone,
a.cs_login_name a.cs_login_name,a.PROJECT_MANAGER
FROM FROM
t_settle_domain a t_settle_domain a
<if test="userId != null and userId.trim() != '-999'"> <if test="userId != null and userId.trim() != '-999'">
......
...@@ -622,6 +622,8 @@ public interface ErrorCodes { ...@@ -622,6 +622,8 @@ public interface ErrorCodes {
* 学历不可为空 * 学历不可为空
*/ */
String EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY = "dispatch.emp.education.not.empty"; String EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY = "dispatch.emp.education.not.empty";
// 学历为大专及以上,学校必填
String EMP_DISPATCH_EMP_SCHOOL_NOT_EMPTY = "dispatch.emp.school.not.empty";
/** /**
* 户口性质不可为空 * 户口性质不可为空
*/ */
......
...@@ -46,7 +46,7 @@ public class SmsUtil { ...@@ -46,7 +46,7 @@ public class SmsUtil {
request.putQueryParameter("RegionId", "cn-hangzhou"); request.putQueryParameter("RegionId", "cn-hangzhou");
request.putQueryParameter("PhoneNumbers", phone); request.putQueryParameter("PhoneNumbers", phone);
request.putQueryParameter("SignName", signName); request.putQueryParameter("SignName", signName);
request.putQueryParameter("TemplateCode", "SMS_200465275"); request.putQueryParameter("TemplateCode", "SMS_483630102");
request.putQueryParameter("TemplateParam", "{\"code\":\""+code+"\"}"); request.putQueryParameter("TemplateParam", "{\"code\":\""+code+"\"}");
try { try {
CommonResponse response = client.getCommonResponse(request); CommonResponse response = client.getCommonResponse(request);
...@@ -67,7 +67,7 @@ public class SmsUtil { ...@@ -67,7 +67,7 @@ public class SmsUtil {
* @return 错误示例 {"Message":"模板不合法(不存在或被拉黑)","RequestId":"D7923A5B-AE30-481C-84D4-56BB0F230848","Code":"isv.SMS_TEMPLATE_ILLEGAL"} * @return 错误示例 {"Message":"模板不合法(不存在或被拉黑)","RequestId":"D7923A5B-AE30-481C-84D4-56BB0F230848","Code":"isv.SMS_TEMPLATE_ILLEGAL"}
**/ **/
public static AliSmsResult sendSms(String phone,String code) { public static AliSmsResult sendSms(String phone,String code) {
return sendSms(phone,code,"皖信人力"); return sendSms(phone,code,"皖信人力");
} }
} }
...@@ -240,6 +240,8 @@ emp.work.job.not.empty=\u5DE5\u4F5C\u5C97\u4F4D\u4E0D\u53EF\u4E3A\u7A7A ...@@ -240,6 +240,8 @@ emp.work.job.not.empty=\u5DE5\u4F5C\u5C97\u4F4D\u4E0D\u53EF\u4E3A\u7A7A
dispatch.emp.education.not.empty=\u5DF2\u6709\u6863\u6848\u5B66\u5386\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u5B66\u5386\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u5B66\u5386 dispatch.emp.education.not.empty=\u5DF2\u6709\u6863\u6848\u5B66\u5386\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u5B66\u5386\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u5B66\u5386
dispatch.emp.school.not.empty=\u5B66\u5386\u4E3A\u5927\u4E13\u53CA\u4EE5\u4E0A\uFF0C\u5B66\u6821\u5FC5\u586B
dispatch.emp.registype.not.empty=\u5DF2\u6709\u6863\u6848\u6237\u53E3\u6027\u8D28\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u6237\u53E3\u6027\u8D28\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u6237\u53E3\u6027\u8D28 dispatch.emp.registype.not.empty=\u5DF2\u6709\u6863\u6848\u6237\u53E3\u6027\u8D28\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u6237\u53E3\u6027\u8D28\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u6237\u53E3\u6027\u8D28
dispatch.emp.tryperiod.not.empty=\u5DF2\u6709\u6863\u6848\u8BD5\u7528\u671F\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u8BD5\u7528\u671F\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u8BD5\u7528\u671F dispatch.emp.tryperiod.not.empty=\u5DF2\u6709\u6863\u6848\u8BD5\u7528\u671F\u4E3A\u7A7A\u6216\u65E0\u6863\u6848\uFF0C\u6D3E\u5355\u6A21\u677F\u8BD5\u7528\u671F\u4E0D\u53EF\u4E3A\u7A7A\uFF0C\u8BF7\u8865\u5145\u8BD5\u7528\u671F
......
...@@ -29,6 +29,12 @@ public class InsuranceExportListOneVO implements Serializable { ...@@ -29,6 +29,12 @@ public class InsuranceExportListOneVO implements Serializable {
@Schema(description = "项目名称") @Schema(description = "项目名称")
private String projectName; private String projectName;
/**
* 客户名称
*/
@Schema(description = "客户名称")
private String unitName;
/** /**
* 项目编码 * 项目编码
*/ */
...@@ -181,4 +187,10 @@ public class InsuranceExportListOneVO implements Serializable { ...@@ -181,4 +187,10 @@ public class InsuranceExportListOneVO implements Serializable {
*/ */
@Schema(description = "是否地市自购") @Schema(description = "是否地市自购")
private String isAdress; private String isAdress;
/**
* 派单备注
*/
@Schema(description = "派单备注")
private String remarkDispatch;
} }
...@@ -194,4 +194,10 @@ public class InsuranceExportListVO implements Serializable { ...@@ -194,4 +194,10 @@ public class InsuranceExportListVO implements Serializable {
@Schema(description = "是否地市自购") @Schema(description = "是否地市自购")
private String isAdress; private String isAdress;
/**
* 派单备注
*/
@Schema(description = "派单备注")
private String remarkDispatch;
} }
...@@ -221,4 +221,15 @@ public class InsuranceRefundListVo implements Serializable { ...@@ -221,4 +221,15 @@ public class InsuranceRefundListVo implements Serializable {
*/ */
@Schema(description = "是否地市自购") @Schema(description = "是否地市自购")
private String isAdress; private String isAdress;
/**
* 备注
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("备注")
@Schema(description = "备注")
private String remark;
} }
...@@ -139,4 +139,11 @@ public class InsuranceReplaceParam implements Serializable { ...@@ -139,4 +139,11 @@ public class InsuranceReplaceParam implements Serializable {
@Schema(description = "是否地市自购") @Schema(description = "是否地市自购")
private String isAdress; private String isAdress;
/**
* 备注
*/
@Schema(description = "备注")
private String remark;
} }
...@@ -82,6 +82,15 @@ public class InsuredListVo implements Serializable { ...@@ -82,6 +82,15 @@ public class InsuredListVo implements Serializable {
@ExcelProperty(value = "项目") @ExcelProperty(value = "项目")
private String projectName; private String projectName;
/**
* 项目编码
*/
@Schema(description = "项目编码")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "项目编码")
private String deptNo;
/** /**
* 投保岗位 * 投保岗位
*/ */
...@@ -200,13 +209,6 @@ public class InsuredListVo implements Serializable { ...@@ -200,13 +209,6 @@ public class InsuredListVo implements Serializable {
@ExcelIgnore @ExcelIgnore
private Integer reduceHandleStatus; private Integer reduceHandleStatus;
/**
* 项目编码
*/
@Schema(description = "项目编码")
@ExcelIgnore
private String deptNo;
/** /**
* 商险购买地省code * 商险购买地省code
*/ */
...@@ -410,4 +412,12 @@ public class InsuredListVo implements Serializable { ...@@ -410,4 +412,12 @@ public class InsuredListVo implements Serializable {
@HeadFontStyle(fontHeightInPoints = 11) @HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "是否地市自购") @ExcelProperty(value = "是否地市自购")
private String isAdress; private String isAdress;
/**
* 备注
*/
@Schema(description = "备注")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value = "备注")
private String remark;
} }
...@@ -228,4 +228,8 @@ public class RefundExportListVo implements Serializable { ...@@ -228,4 +228,8 @@ public class RefundExportListVo implements Serializable {
*/ */
@Schema(description = "是否地市自购") @Schema(description = "是否地市自购")
private String isAdress; private String isAdress;
@Schema(description ="客户名称")
private String unitName;
} }
...@@ -530,8 +530,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -530,8 +530,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
newDetail.setCreateName(user.getNickname()); newDetail.setCreateName(user.getNickname());
//替换不参与结算 //替换不参与结算
newDetail.setDefaultSettleId(null); newDetail.setDefaultSettleId(null);
//替换不继承备注 //替换不继承备注 20250331 fxj 替换模板新增备注字段不用清空
newDetail.setRemark(null); //newDetail.setRemark(null);
//替换不继承保单生效日期 //替换不继承保单生效日期
newDetail.setPolicyEffect(null); newDetail.setPolicyEffect(null);
//保费都默认是0 //保费都默认是0
...@@ -1077,6 +1077,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -1077,6 +1077,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
List<InsuranceExportListOneVO> list = new ArrayList<>(); List<InsuranceExportListOneVO> list = new ArrayList<>();
if(CollectionUtils.isNotEmpty(listVOS)){ if(CollectionUtils.isNotEmpty(listVOS)){
for (InsuranceExportListOneVO listVO : listVOS) { for (InsuranceExportListOneVO listVO : listVOS) {
listVO.setRemarkDispatch(listVO.getRemark());
listVO.setRemark(InsurancesConstants.INSERT); listVO.setRemark(InsurancesConstants.INSERT);
TInsuranceReplace one = tInsuranceReplaceService.getOne(Wrappers.<TInsuranceReplace>query().lambda() TInsuranceReplace one = tInsuranceReplaceService.getOne(Wrappers.<TInsuranceReplace>query().lambda()
.eq(TInsuranceReplace::getToInsuranceDetailId, listVO.getId()) .eq(TInsuranceReplace::getToInsuranceDetailId, listVO.getId())
...@@ -1240,6 +1241,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -1240,6 +1241,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
List<InsuranceExportListVO> list = new ArrayList<>(); List<InsuranceExportListVO> list = new ArrayList<>();
if(CollectionUtils.isNotEmpty(listVOS)){ if(CollectionUtils.isNotEmpty(listVOS)){
for (InsuranceExportListVO listVO : listVOS) { for (InsuranceExportListVO listVO : listVOS) {
listVO.setRemarkDispatch(listVO.getRemark());
listVO.setRemark(InsurancesConstants.INSERT); listVO.setRemark(InsurancesConstants.INSERT);
TInsuranceReplace one = tInsuranceReplaceService.getOne(Wrappers.<TInsuranceReplace>query().lambda() TInsuranceReplace one = tInsuranceReplaceService.getOne(Wrappers.<TInsuranceReplace>query().lambda()
.eq(TInsuranceReplace::getToInsuranceDetailId, listVO.getId()) .eq(TInsuranceReplace::getToInsuranceDetailId, listVO.getId())
...@@ -3709,6 +3711,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap ...@@ -3709,6 +3711,8 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
} }
//所有校验通过后设置查到的结果 //所有校验通过后设置查到的结果
//直接用excel里面的备注覆盖既有备注
detail.setRemark(param.getRemark());
param.setDetail(detail); param.setDetail(detail);
listSuccess.add(param); listSuccess.add(param);
} }
......
...@@ -506,7 +506,7 @@ ...@@ -506,7 +506,7 @@
a.CREATE_NAME as createName, a.CREATE_NAME as createName,
a.POLICY_NO as policyNo, a.POLICY_NO as policyNo,
a.REMARK as remark, a.REMARK as remark,
a.IS_ADRESS as isAdress a.IS_ADRESS as isAdress,a.UNIT_NAME as unitName
from t_insurance_detail a from t_insurance_detail a
where a.DELETE_FLAG = 0 and a.id in where a.DELETE_FLAG = 0 and a.id in
<foreach collection="idList" index="index" item="item" open="(" separator="," close=")"> <foreach collection="idList" index="index" item="item" open="(" separator="," close=")">
...@@ -539,7 +539,7 @@ ...@@ -539,7 +539,7 @@
a.CREATE_NAME as createName, a.CREATE_NAME as createName,
a.POLICY_NO as policyNo, a.POLICY_NO as policyNo,
a.REMARK as remark, a.REMARK as remark,
a.IS_ADRESS as isAdress a.IS_ADRESS as isAdress,a.UNIT_NAME as unitName
from t_insurance_detail a from t_insurance_detail a
where a.DELETE_FLAG = 0 and a.BUY_HANDLE_STATUS = #{param.buyHandleStatus} where a.DELETE_FLAG = 0 and a.BUY_HANDLE_STATUS = #{param.buyHandleStatus}
<if test="param.empName != null and param.empName.trim() != ''"> <if test="param.empName != null and param.empName.trim() != ''">
...@@ -729,7 +729,7 @@ ...@@ -729,7 +729,7 @@
a.CREATE_NAME as createName, a.CREATE_NAME as createName,
a.UNIT_NAME as unitName, a.UNIT_NAME as unitName,
a.UNIT_NO as unitNo, a.UNIT_NO as unitNo,
if(a.IS_ADRESS = '0','是',if(ifnull(a.IS_ADRESS,3) = 3,'','否')) as isAdress if(a.IS_ADRESS = '0','是',if(ifnull(a.IS_ADRESS,3) = 3,'','否')) as isAdress,a.remark
from from
t_insurance_detail a t_insurance_detail a
where where
...@@ -1005,7 +1005,7 @@ ...@@ -1005,7 +1005,7 @@
a.CREATE_NAME as createName, a.CREATE_NAME as createName,
refund.CREATE_TIME as refundCreateTime, refund.CREATE_TIME as refundCreateTime,
a.IS_EFFECT as isEffect, a.IS_EFFECT as isEffect,
a.IS_ADRESS as isAdress a.IS_ADRESS as isAdress,refund.remark as remark
from from
t_insurance_detail a, t_insurance_detail a,
t_insurance_refund refund t_insurance_refund refund
...@@ -1212,7 +1212,7 @@ ...@@ -1212,7 +1212,7 @@
refund.CREATE_NAME as createName, refund.CREATE_NAME as createName,
a.REDUCE_HANDLE_STATUS as reduceHandleStatus, a.REDUCE_HANDLE_STATUS as reduceHandleStatus,
refund.REMARK as remark, refund.REMARK as remark,
a.IS_ADRESS as isAdress a.IS_ADRESS as isAdress,a.UNIT_NAME as unitName
from from
t_insurance_detail a, t_insurance_detail a,
t_insurance_refund refund t_insurance_refund refund
...@@ -1250,7 +1250,7 @@ ...@@ -1250,7 +1250,7 @@
refund.CREATE_NAME as createName, refund.CREATE_NAME as createName,
a.POLICY_NO as policyNo, a.POLICY_NO as policyNo,
refund.REMARK as remark, refund.REMARK as remark,
a.IS_ADRESS as isAdress a.IS_ADRESS as isAdress,a.UNIT_NAME as unitName
from from
t_insurance_detail a, t_insurance_detail a,
t_insurance_refund refund t_insurance_refund refund
...@@ -1478,7 +1478,7 @@ ...@@ -1478,7 +1478,7 @@
FROM t_insurance_detail d FROM t_insurance_detail d
where DELETE_FLAG = 0 where DELETE_FLAG = 0
and (d.BUY_HANDLE_STATUS in (1,2) or (d.BUY_HANDLE_STATUS = 3 and d.IS_EFFECT = 0 and (d.BUY_HANDLE_STATUS in (1,2) or (d.BUY_HANDLE_STATUS = 3 and d.IS_EFFECT = 0
and d.POLICY_EFFECT <![CDATA[ <= ]]> NOW() and d.POLICY_END >= NOW() and d.POLICY_EFFECT <![CDATA[ <= ]]> DATE_ADD(NOW(),INTERVAL 1 DAY) and d.POLICY_END >= NOW()
)) ))
<if test="idCardList != null and idCardList.size > 0"> <if test="idCardList != null and idCardList.size > 0">
......
...@@ -233,5 +233,13 @@ public interface SysUserPermissionMapper extends BaseMapper<SysUserPermission> { ...@@ -233,5 +233,13 @@ public interface SysUserPermissionMapper extends BaseMapper<SysUserPermission> {
Integer selectDivitionCount(@Param("name")String name); Integer selectDivitionCount(@Param("name")String name);
Integer selectDivitionLineCount(@Param("name")String name); Integer selectDivitionLineCount(@Param("name")String name);
//变更后项目负责人
List<SysUserPermission> getUserPermissionByAutoCreateXMBG1(String fdId);
//变更前项目负责人
List<SysUserPermission> getUserPermissionByAutoCreateXMBG2(String fdId);
//变更后项目团队
List<SysUserPermission> getUserPermissionByAutoCreateXMBG3(String fdId);
//变更前项目团队
List<SysUserPermission> getUserPermissionByAutoCreateXMBG4(String fdId);
} }
...@@ -483,9 +483,30 @@ public class SysUserPermissionServiceImpl extends ServiceImpl<SysUserPermissionM ...@@ -483,9 +483,30 @@ public class SysUserPermissionServiceImpl extends ServiceImpl<SysUserPermissionM
case "项目": case "项目":
deleteType = CommonConstants.dingleDigitStrArray[5]; deleteType = CommonConstants.dingleDigitStrArray[5];
list = baseMapper.getUserPermissionByAutoCreateXM(fdId); break; list = baseMapper.getUserPermissionByAutoCreateXM(fdId); break;
case "项目变更": case "项目变更": //项目服务团队及项目负责人变更 fxj 20250410 V1.7.9
deleteType = CommonConstants.dingleDigitStrArray[5]; deleteType = CommonConstants.dingleDigitStrArray[5];
list = baseMapper.getUserPermissionByAutoCreateXMBG(fdId); break; //list = baseMapper.getUserPermissionByAutoCreateXMBG(fdId);
List<SysUserPermission> temp;
//变更后项目负责人
temp = baseMapper.getUserPermissionByAutoCreateXMBG1(fdId);
list = new ArrayList<>();
//无变更取值变更前项目负责人
if (Common.isEmpty(temp)){
temp = baseMapper.getUserPermissionByAutoCreateXMBG2(fdId);
}
if (Common.isNotNull(temp)){
list.addAll(temp);
}
//变更后服务团队
temp = baseMapper.getUserPermissionByAutoCreateXMBG3(fdId);
//无变更取值变更前服务团队
if (Common.isEmpty(temp)){
temp = baseMapper.getUserPermissionByAutoCreateXMBG4(fdId);
}
if (Common.isNotNull(temp)){
list.addAll(temp);
}
break;
default: default:
list = new ArrayList<>(); list = new ArrayList<>();
} }
......
...@@ -404,9 +404,10 @@ ...@@ -404,9 +404,10 @@
,'5' PERMISSION_TYPE,d.fd_3a829ae9bab760 NAME,d.fd_3a829aea0b84a4 CODE,0 SOURCE_TYPE ,'5' PERMISSION_TYPE,d.fd_3a829ae9bab760 NAME,d.fd_3a829aea0b84a4 CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID ,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_fb3b8d0c8f148639b8e2 d from ekp_fb3b8d0c8f148639b8e2 d
LEFT JOIN sys_org_element e on e.fd_id = d.fd_3ae55447e30d62 LEFT JOIN sys_org_element e on e.fd_id = d.fd_dept_manager
JOIN sys_org_person p on e.fd_id=p.fd_id JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId} where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID ) a GROUP BY a.USER_ID
</select> </select>
...@@ -444,17 +445,17 @@ ...@@ -444,17 +445,17 @@
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE ,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID ,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d from ekp_d701e3e72794ff390ca8 d
LEFT JOIN ekporg_18622320f73771d520db f on f.fd_parent_id = d.fd_id LEFT JOIN ekporg_195eb1d6815b96ceb269 f on f.fd_parent_id = d.fd_id
LEFT JOIN sys_org_element e on e.fd_id = f.sys_org_person_id JOIN sys_org_person p on e.fd_id=p.fd_id LEFT JOIN sys_org_element e on e.fd_id = f.sys_org_person_id JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId} where d.fd_id = #{fdId}
union all union ALL
select select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE ,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID ,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d from ekp_d701e3e72794ff390ca8 d
LEFT JOIN ekp_24a8e6a7fc143bb8c48a f on f.fd_3a37fe508071fe = d.fd_3b879793d37afe LEFT JOIN sys_org_element e on e.fd_id = d.fd_changeafter
LEFT JOIN sys_org_element e on e.fd_id = f.fd_3b212a2d7a65c6 JOIN sys_org_person p on e.fd_id=p.fd_id JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId} where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID ) a GROUP BY a.USER_ID
</select> </select>
...@@ -493,4 +494,63 @@ ...@@ -493,4 +494,63 @@
from ekp_shenhepeizhi_table a from ekp_shenhepeizhi_table a
where a.fd_tiaoxian = #{name} where a.fd_tiaoxian = #{name}
</select> </select>
<!-- 变更后项目团队 -->
<select id="getUserPermissionByAutoCreateXMBG3" resultMap="sysUserPermissionMap">
select a.EMP_NAME,a.EMP_LOGIN_NAME,a.EMP_DEPT,a.PERMISSION_TYPE,a.NAME,a.CODE,a.SOURCE_TYPE,a.IS_CONTAINS,a.PERMISSION_STATUS,a.DELETE_FLAG,a.USER_ID,a.DOMAIN_ID
from (
select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d
LEFT JOIN ekporg_195eb1d6815b96ceb269 f on f.fd_parent_id = d.fd_id
LEFT JOIN sys_org_element e on e.fd_id = f.sys_org_person_id JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID
</select>
<!-- 变更后项目负责人 -->
<select id="getUserPermissionByAutoCreateXMBG1" resultMap="sysUserPermissionMap">
select a.EMP_NAME,a.EMP_LOGIN_NAME,a.EMP_DEPT,a.PERMISSION_TYPE,a.NAME,a.CODE,a.SOURCE_TYPE,a.IS_CONTAINS,a.PERMISSION_STATUS,a.DELETE_FLAG,a.USER_ID,a.DOMAIN_ID
from (
select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d
LEFT JOIN sys_org_element e on e.fd_id = d.fd_changeafter
JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID
</select>
<!-- 变更前项目团队 -->
<select id="getUserPermissionByAutoCreateXMBG4" resultMap="sysUserPermissionMap">
select a.EMP_NAME,a.EMP_LOGIN_NAME,a.EMP_DEPT,a.PERMISSION_TYPE,a.NAME,a.CODE,a.SOURCE_TYPE,a.IS_CONTAINS,a.PERMISSION_STATUS,a.DELETE_FLAG,a.USER_ID,a.DOMAIN_ID
from (
select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d
LEFT JOIN ekporg_18622320f73771d520db f on f.fd_parent_id = d.fd_id
LEFT JOIN sys_org_element e on e.fd_id = f.sys_org_person_id JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID
</select>
<!-- 变更前项目负责人 -->
<select id="getUserPermissionByAutoCreateXMBG2" resultMap="sysUserPermissionMap">
select a.EMP_NAME,a.EMP_LOGIN_NAME,a.EMP_DEPT,a.PERMISSION_TYPE,a.NAME,a.CODE,a.SOURCE_TYPE,a.IS_CONTAINS,a.PERMISSION_STATUS,a.DELETE_FLAG,a.USER_ID,a.DOMAIN_ID
from (
select
e.fd_name EMP_NAME,p.fd_login_name EMP_LOGIN_NAME,SUBSTRING_INDEX(SUBSTRING_INDEX(e.fd_ldap_dn,',ou', 2),',ou=', -1) EMP_DEPT
,'5' PERMISSION_TYPE,d.fd_3b8797876dc13c_text NAME,d.fd_3b879793d37afe CODE,0 SOURCE_TYPE
,'1' IS_CONTAINS,'0' PERMISSION_STATUS,'1' DELETE_FLAG,e.fd_id USER_ID,d.fd_id DOMAIN_ID
from ekp_d701e3e72794ff390ca8 d
LEFT JOIN sys_org_element e on e.fd_id = d.fd_changebefore
JOIN sys_org_person p on e.fd_id=p.fd_id
where d.fd_id = #{fdId}
) a GROUP BY a.USER_ID
</select>
</mapper> </mapper>
...@@ -197,6 +197,12 @@ public class TSalaryStandardController { ...@@ -197,6 +197,12 @@ public class TSalaryStandardController {
if (Common.isNotNull(s.getIsCheckRisk()) && CommonConstants.ONE_INT == s.getIsCheckRisk()) { if (Common.isNotNull(s.getIsCheckRisk()) && CommonConstants.ONE_INT == s.getIsCheckRisk()) {
return R.ok(); return R.ok();
} }
if (!CommonConstants.ZERO_STRING.equals(s.getFormType())) {
s.setIsCheckRisk(CommonConstants.ONE_INT);
s.setCheckRiskRemark("非工资类型,放开限制");
this.updateById(s);
return R.ok();
}
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (user != null) { if (user != null) {
// 2025-1-14 10:59:37 提交前拦截: // 2025-1-14 10:59:37 提交前拦截:
...@@ -225,7 +231,8 @@ public class TSalaryStandardController { ...@@ -225,7 +231,8 @@ public class TSalaryStandardController {
|| s.getStatus() == SalaryConstants.STATUS[5] || s.getStatus() == SalaryConstants.STATUS[5]
|| s.getStatus() == SalaryConstants.STATUS[6] || s.getStatus() == SalaryConstants.STATUS[6]
|| s.getStatus() == SalaryConstants.STATUS[7]) { || s.getStatus() == SalaryConstants.STATUS[7]) {
if (Common.isEmpty(s.getIsCheckRisk()) || CommonConstants.ZERO_INT == s.getIsCheckRisk()) { if (CommonConstants.ZERO_STRING.equals(s.getFormType())
&& (Common.isEmpty(s.getIsCheckRisk()) || CommonConstants.ZERO_INT == s.getIsCheckRisk())) {
return R.failed("请先校验商险信息!"); return R.failed("请先校验商险信息!");
} }
......
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the yifu4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng (wangiegie@gmail.com)
*/
package com.yifu.cloud.plus.v1.yifu.social.entity;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;
/**
* 离职原因税友自动化配置表
*
* @author hgw
* @date 2025-04-14 11:57:06
*/
@Data
@TableName("t_social_friend_reduce_set")
@Schema(description = "离职原因税友自动化配置表")
public class TSocialFriendReduceSet {
/**
* 减少原因ID
*/
@TableId(type = IdType.ASSIGN_ID)
@ExcelProperty("减少原因ID")
@Schema(description = "减少原因ID")
private String id;
/**
* 减少原因
*/
@ExcelAttribute(name = "减少原因", maxLength = 32)
@Length(max = 32, message = "减少原因不能超过32个字符")
@ExcelProperty("减少原因")
@Schema(description = "减少原因")
private String reduceReasonName;
/**
* 中断原因
*/
@ExcelAttribute(name = "中断原因", maxLength = 32)
@Length(max = 32, message = "中断原因不能超过32个字符")
@ExcelProperty("中断原因")
@Schema(description = "中断原因")
private String tbyy;
/**
* 劳动用工备案解除/终止原因
*/
@ExcelAttribute(name = "劳动用工备案解除/终止原因", maxLength = 32)
@Length(max = 32, message = "劳动用工备案解除/终止原因不能超过32个字符")
@ExcelProperty("劳动用工备案解除/终止原因")
@Schema(description = "劳动用工备案解除/终止原因")
private String zzyy;
/**
* 备案解除二级原因
*/
@ExcelAttribute(name = "备案解除二级原因", maxLength = 32)
@Length(max = 32, message = "备案解除二级原因不能超过32个字符")
@ExcelProperty("备案解除二级原因")
@Schema(description = "备案解除二级原因")
private String bajcejyy;
}
...@@ -106,4 +106,7 @@ public class SociaFriendYgsAddVo implements Serializable { ...@@ -106,4 +106,7 @@ public class SociaFriendYgsAddVo implements Serializable {
@ExcelProperty("派单类型") @ExcelProperty("派单类型")
private String type; private String type;
@ExcelProperty("备案解除二级原因")
private String bajcejyy;
} }
...@@ -3,6 +3,7 @@ package com.yifu.cloud.plus.v1.yifu.social.config; ...@@ -3,6 +3,7 @@ package com.yifu.cloud.plus.v1.yifu.social.config;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants; import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.exception.CheckedException; import com.yifu.cloud.plus.v1.yifu.common.core.exception.CheckedException;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common; import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
...@@ -26,6 +27,8 @@ import java.util.Date; ...@@ -26,6 +27,8 @@ import java.util.Date;
import java.util.List; import java.util.List;
import java.util.TreeMap; import java.util.TreeMap;
import static com.alibaba.fastjson.serializer.SerializerFeature.*;
/** /**
* @Author: hgw * @Author: hgw
* @Date: 2024-12-6 17:01:23 * @Date: 2024-12-6 17:01:23
...@@ -68,6 +71,10 @@ public class SocialFriendConfig { ...@@ -68,6 +71,10 @@ public class SocialFriendConfig {
private static final String X_REQ_NONCE = "xReqNonce"; private static final String X_REQ_NONCE = "xReqNonce";
private static final String VERSION = "version"; private static final String VERSION = "version";
private static final SerializerFeature[] features = new SerializerFeature[] {
WriteMapNullValue, WriteNullNumberAsZero, WriteNullListAsEmpty,
WriteNullStringAsEmpty,WriteDateUseDateFormat
};
/** /**
* @param : listVo 同一类(户、增减)的前100个 * @param : listVo 同一类(户、增减)的前100个
* @param : vo 第一个,存账密等信息 * @param : vo 第一个,存账密等信息
...@@ -156,7 +163,7 @@ public class SocialFriendConfig { ...@@ -156,7 +163,7 @@ public class SocialFriendConfig {
TSocialFriendBackLog backLogPush = new TSocialFriendBackLog(); TSocialFriendBackLog backLogPush = new TSocialFriendBackLog();
backLogPush.setSocialId(vo.getSocialId()); backLogPush.setSocialId(vo.getSocialId());
backLogPush.setType(5); backLogPush.setType(5);
backLogPush.setLogInfo(json.toString()); backLogPush.setLogInfo(JSON.toJSONString(json, features));
backLogPush.setCreateTime(LocalDateTime.now()); backLogPush.setCreateTime(LocalDateTime.now());
backLogList.add(backLogPush); backLogList.add(backLogPush);
String dataResultList = restTemplate.postForObject(appAddUrl, formEntity, String.class); String dataResultList = restTemplate.postForObject(appAddUrl, formEntity, String.class);
...@@ -474,6 +481,7 @@ public class SocialFriendConfig { ...@@ -474,6 +481,7 @@ public class SocialFriendConfig {
// 办理项目 // 办理项目
blxmlbOne.put("blxm", blxm); blxmlbOne.put("blxm", blxm);
// 中断原因 除死亡以外,其他停保原因默认:“在职人员解除/终止劳动合同” 死亡对应“死亡或失踪” // 中断原因 除死亡以外,其他停保原因默认:“在职人员解除/终止劳动合同” 死亡对应“死亡或失踪”
// 2025-4-14 16:03:54 陈红提的:tbyy 、 zzyy 、 bajcejyy 改为按t_social_friend_reduce_set配置来
blxmlbOne.put("tbyy", vo.getTbyy()); blxmlbOne.put("tbyy", vo.getTbyy());
// 中断时间 yyyy-MM-dd 默认当前时间 // 中断时间 yyyy-MM-dd 默认当前时间
blxmlbOne.put("tbsj", DateUtil.getLastDay()); blxmlbOne.put("tbsj", DateUtil.getLastDay());
...@@ -484,6 +492,7 @@ public class SocialFriendConfig { ...@@ -484,6 +492,7 @@ public class SocialFriendConfig {
tszdxx = new JSONObject(); tszdxx = new JSONObject();
// 劳动用工备案解除/终止原因 数据字典文档 法律依据 [社保]必填; // 劳动用工备案解除/终止原因 数据字典文档 法律依据 [社保]必填;
tszdxx.put("zzyy", vo.getZzyy()); tszdxx.put("zzyy", vo.getZzyy());
tszdxx.put("bajcejyy", vo.getBajcejyy());
// 社保个人身份材料 无 // 社保个人身份材料 无
// tszdxx.put("shjycl", ) // tszdxx.put("shjycl", )
// 医保个人身份材料 无 // 医保个人身份材料 无
......
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the yifu4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng (wangiegie@gmail.com)
*/
package com.yifu.cloud.plus.v1.yifu.social.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
/**
* 离职原因税友自动化配置表
*
* @author hgw
* @date 2025-04-14 11:57:06
*/
@Mapper
public interface TSocialFriendReduceSetMapper extends BaseMapper<TSocialFriendReduceSet> {
/**
* @Description: 获取全量信息
* @Author: hgw
* @Date: 2025/4/14 15:24
* @return: java.util.List<com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet>
**/
List<TSocialFriendReduceSet> getTSocialFriendReduceSetList();
}
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the yifu4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng (wangiegie@gmail.com)
*/
package com.yifu.cloud.plus.v1.yifu.social.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet;
import java.util.Map;
/**
* 离职原因税友自动化配置表
*
* @author hgw
* @date 2025-04-14 11:57:06
*/
public interface TSocialFriendReduceSetService extends IService<TSocialFriendReduceSet> {
/**
* @Description: 查找List并组装Map
* @Author: hgw
* @Date: 2025/4/14 15:23
* @return: java.util.List<com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet>
**/
Map<String, TSocialFriendReduceSet> getFriendReduceMap();
}
...@@ -81,6 +81,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -81,6 +81,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.Cache; import org.springframework.cache.Cache;
import org.springframework.cache.CacheManager; import org.springframework.cache.CacheManager;
import org.springframework.cache.support.SimpleValueWrapper; import org.springframework.cache.support.SimpleValueWrapper;
import org.springframework.security.core.parameters.P;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
...@@ -2341,6 +2342,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2341,6 +2342,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SETTLEDOMAIN_STOP))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SETTLEDOMAIN_STOP)));
return true; return true;
} }
String educationName;
if (Common.isEmpty(empVo)){ if (Common.isEmpty(empVo)){
if (Common.isEmpty(excel.getFileProvince()) if (Common.isEmpty(excel.getFileProvince())
|| Common.isEmpty(excel.getFileCity()) || Common.isEmpty(excel.getFileCity())
...@@ -2363,7 +2365,17 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2363,7 +2365,17 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isEmpty(excel.getEducationName()) ){ if (Common.isEmpty(excel.getEducationName()) ){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY)));
return true; return true;
} else if (Common.isEmpty(excel.getSchoolName())) {
educationName = excel.getEducationName();
if ((educationName.contains("大专")
|| educationName.contains("本科")
|| educationName.contains("硕士")
|| educationName.contains("博士"))) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_SCHOOL_NOT_EMPTY)));
return true;
}
} }
if (Common.isNotNull(excel.getContractName()) && validContractInfo(errorMessageList,excel)){ if (Common.isNotNull(excel.getContractName()) && validContractInfo(errorMessageList,excel)){
return true; return true;
} }
...@@ -2406,6 +2418,27 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2406,6 +2418,27 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isEmpty(empVo.getHignEducation()) && Common.isEmpty(excel.getEducationName())){ if (Common.isEmpty(empVo.getHignEducation()) && Common.isEmpty(excel.getEducationName())){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_EDUCATION_NOT_EMPTY)));
return true; return true;
} else if (Common.isEmpty(excel.getSchoolName()) && Common.isEmpty(empVo.getSchool())) {
educationName = excel.getEducationName();
if (Common.isEmpty(educationName)) {
educationName = empVo.getHignEducation();
// 这里不判断null,因为上面判断过了empVo与excel的学历不都为空
if ((educationName.equals("5")
|| educationName.equals("6")
|| educationName.equals("7")
|| educationName.equals("8"))) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_SCHOOL_NOT_EMPTY)));
return true;
}
} else {
if ((educationName.contains("大专")
|| educationName.contains("本科")
|| educationName.contains("硕士")
|| educationName.contains("博士"))) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_SCHOOL_NOT_EMPTY)));
return true;
}
}
} }
if (Common.isEmpty(empVo.getEmpRegisType()) && Common.isEmpty(excel.getEmpRegisType())){ if (Common.isEmpty(empVo.getEmpRegisType()) && Common.isEmpty(excel.getEmpRegisType())){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_REGISTYPE_NOT_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_EMP_REGISTYPE_NOT_EMPTY)));
...@@ -3563,6 +3596,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3563,6 +3596,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
||CommonConstants.FIVE_STRING.equals(socialInfo.getUnemployHandle())) ||CommonConstants.FIVE_STRING.equals(socialInfo.getUnemployHandle()))
&& CommonConstants.ZERO_STRING.equals(autoFlag)) { && CommonConstants.ZERO_STRING.equals(autoFlag)) {
socialInfo.setYgsHandleStatus(CommonConstants.ONE_STRING); socialInfo.setYgsHandleStatus(CommonConstants.ONE_STRING);
} else {
socialInfo.setYgsHandleStatus(CommonConstants.ZERO_STRING);
} }
if ((CommonConstants.ZERO_STRING.equals(socialInfo.getMedicalHandle()) if ((CommonConstants.ZERO_STRING.equals(socialInfo.getMedicalHandle())
||CommonConstants.FIVE_STRING.equals(socialInfo.getMedicalHandle()) ||CommonConstants.FIVE_STRING.equals(socialInfo.getMedicalHandle())
...@@ -3572,6 +3607,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3572,6 +3607,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
||CommonConstants.FIVE_STRING.equals(socialInfo.getBigailmentHandle())) ||CommonConstants.FIVE_STRING.equals(socialInfo.getBigailmentHandle()))
&& CommonConstants.ZERO_STRING.equals(autoFlag)) { && CommonConstants.ZERO_STRING.equals(autoFlag)) {
socialInfo.setYsdHandleStatus(CommonConstants.ONE_STRING); socialInfo.setYsdHandleStatus(CommonConstants.ONE_STRING);
} else {
socialInfo.setYsdHandleStatus(CommonConstants.ZERO_STRING);
} }
socialInfo.setYgsAddId(CommonConstants.CENTER_SPLIT_LINE_STRING); socialInfo.setYgsAddId(CommonConstants.CENTER_SPLIT_LINE_STRING);
socialInfo.setYgsRequestId(CommonConstants.CENTER_SPLIT_LINE_STRING); socialInfo.setYgsRequestId(CommonConstants.CENTER_SPLIT_LINE_STRING);
......
...@@ -66,6 +66,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -66,6 +66,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
private final TSocialSoldierLogService tSocialSoldierLogService; private final TSocialSoldierLogService tSocialSoldierLogService;
private final TSocialFriendBackLogService tSocialFriendBackLogService; private final TSocialFriendBackLogService tSocialFriendBackLogService;
private final TSocialFreindSetService tSocialFreindSetService; private final TSocialFreindSetService tSocialFreindSetService;
private final TSocialFriendReduceSetService tSocialFriendReduceSetService;
private final TSocialInfoMapper socialMapper; private final TSocialInfoMapper socialMapper;
private final AtomicInteger atomicPushFriend = new AtomicInteger(0); private final AtomicInteger atomicPushFriend = new AtomicInteger(0);
...@@ -98,6 +99,8 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -98,6 +99,8 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
TSocialFreindSet set = tSocialFreindSetService.getById("1"); TSocialFreindSet set = tSocialFreindSetService.getById("1");
if (set != null && Common.isNotNull(set.getType()) && 1 == set.getType()) { if (set != null && Common.isNotNull(set.getType()) && 1 == set.getType()) {
Map<String, TSocialFriendReduceSet> reduceMap = tSocialFriendReduceSetService.getFriendReduceMap();
// 获取时间限制配置(获取 当月启用 的配置) // 获取时间限制配置(获取 当月启用 的配置)
Map<String, TSocialDeadlineInfo> socialSetMap = tSocialDeadlineInfoService.getSocialSetByAreaId(); Map<String, TSocialDeadlineInfo> socialSetMap = tSocialDeadlineInfoService.getSocialSetByAreaId();
...@@ -105,23 +108,23 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -105,23 +108,23 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
// 养工失新增列表 // 养工失新增列表
List<SociaFriendYgsAddVo> ygsAddlist = baseMapper.getSocialSoldierYgsAddVoList(dispatchIdList); List<SociaFriendYgsAddVo> ygsAddlist = baseMapper.getSocialSoldierYgsAddVoList(dispatchIdList);
if (ygsAddlist != null && !ygsAddlist.isEmpty()) { if (ygsAddlist != null && !ygsAddlist.isEmpty()) {
this.doPushSocialAndLogYgs(socialSetMap, ygsAddlist, 1); this.doPushSocialAndLogYgs(socialSetMap, ygsAddlist, 1, reduceMap);
} }
// 养工失减少列表 // 养工失减少列表
List<SociaFriendYgsAddVo> ygsReducelist = baseMapper.getSocialSoldierYgsReduceVoList(dispatchIdList); List<SociaFriendYgsAddVo> ygsReducelist = baseMapper.getSocialSoldierYgsReduceVoList(dispatchIdList);
if (ygsReducelist != null && !ygsReducelist.isEmpty()) { if (ygsReducelist != null && !ygsReducelist.isEmpty()) {
this.doPushSocialAndLogYgs(socialSetMap, ygsReducelist, 2); this.doPushSocialAndLogYgs(socialSetMap, ygsReducelist, 2, reduceMap);
} }
// 医生大新增列表 // 医生大新增列表
List<SociaFriendYgsAddVo> ysdAddlist = baseMapper.getSocialSoldierYsdAddVoList(dispatchIdList); List<SociaFriendYgsAddVo> ysdAddlist = baseMapper.getSocialSoldierYsdAddVoList(dispatchIdList);
if (ysdAddlist != null && !ysdAddlist.isEmpty()) { if (ysdAddlist != null && !ysdAddlist.isEmpty()) {
this.doPushSocialAndLogYsd(socialSetMap, ysdAddlist, 3); this.doPushSocialAndLogYsd(socialSetMap, ysdAddlist, 3, reduceMap);
} }
// 医生大减少列表 // 医生大减少列表
List<SociaFriendYgsAddVo> ysdReducelist = baseMapper.getSocialSoldierYsdReduceVoList(dispatchIdList); List<SociaFriendYgsAddVo> ysdReducelist = baseMapper.getSocialSoldierYsdReduceVoList(dispatchIdList);
if (ysdReducelist != null && !ysdReducelist.isEmpty()) { if (ysdReducelist != null && !ysdReducelist.isEmpty()) {
this.doPushSocialAndLogYsd(socialSetMap, ysdReducelist, 4); this.doPushSocialAndLogYsd(socialSetMap, ysdReducelist, 4, reduceMap);
} }
if ((ygsAddlist == null || ygsAddlist.isEmpty()) if ((ygsAddlist == null || ygsAddlist.isEmpty())
&& (ygsReducelist == null || ygsReducelist.isEmpty()) && (ygsReducelist == null || ygsReducelist.isEmpty())
...@@ -148,7 +151,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -148,7 +151,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
* @return: void * @return: void
**/ **/
private void doPushSocialAndLogYgs(Map<String, TSocialDeadlineInfo> socialSetMap private void doPushSocialAndLogYgs(Map<String, TSocialDeadlineInfo> socialSetMap
, List<SociaFriendYgsAddVo> ygsAddlist, int type) { , List<SociaFriendYgsAddVo> ygsAddlist, int type, Map<String, TSocialFriendReduceSet> reduceMap) {
int canPushType; int canPushType;
TSocialInfo socialInfo; TSocialInfo socialInfo;
String typeStr = "提交"; String typeStr = "提交";
...@@ -170,8 +173,29 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -170,8 +173,29 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
boolean nextFlag = false; boolean nextFlag = false;
SociaFriendYgsAddVo vo; SociaFriendYgsAddVo vo;
int i=1; int i=1;
TSocialFriendReduceSet reduceSet;
for (int index = 0 ; index < ygsAddlist.size(); index++) { for (int index = 0 ; index < ygsAddlist.size(); index++) {
vo = ygsAddlist.get(index); vo = ygsAddlist.get(index);
// 派减离职原因转化:
if (type == 2 && Common.isNotNull(vo.getTbyy())) {
reduceSet = reduceMap.get(vo.getTbyy());
if (reduceSet != null) {
vo.setTbyy(reduceSet.getTbyy());
vo.setZzyy(reduceSet.getZzyy());
vo.setBajcejyy(reduceSet.getBajcejyy());
} else {
remark = "超出离职原因的配置,转人工!配置为:"+vo.getTbyy();
socialInfo = new TSocialInfo();
socialInfo.setId(vo.getSocialId());
socialInfo.setYgsHandleStatus(CommonConstants.FIVE_STRING);
renGongList.add(socialInfo);
socialLog = tSocialSoldierLogService.getFriendLog(vo, typeStr, dispatchItem, remark);
if (socialLog != null) {
logList.add(socialLog);
}
continue;
}
}
// 0:未到时间不动; 1:推送; 2:转人工 // 0:未到时间不动; 1:推送; 2:转人工
canPushType = this.getCanPushType(socialSetMap, vo); canPushType = this.getCanPushType(socialSetMap, vo);
if (1 == canPushType) { if (1 == canPushType) {
...@@ -261,7 +285,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -261,7 +285,7 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
* @return: void * @return: void
**/ **/
private void doPushSocialAndLogYsd(Map<String, TSocialDeadlineInfo> socialSetMap private void doPushSocialAndLogYsd(Map<String, TSocialDeadlineInfo> socialSetMap
, List<SociaFriendYgsAddVo> ysdAddlist, int type) { , List<SociaFriendYgsAddVo> ysdAddlist, int type, Map<String, TSocialFriendReduceSet> reduceMap) {
int canPushType; int canPushType;
TSocialInfo socialInfo; TSocialInfo socialInfo;
String typeStr = "提交"; String typeStr = "提交";
...@@ -284,10 +308,12 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -284,10 +308,12 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
boolean nextFlag = false; boolean nextFlag = false;
SociaFriendYgsAddVo vo; SociaFriendYgsAddVo vo;
int i=1; int i=1;
TSocialFriendReduceSet reduceSet;
for (int index = 0 ; index < ysdAddlist.size(); index++) { for (int index = 0 ; index < ysdAddlist.size(); index++) {
vo = ysdAddlist.get(index); vo = ysdAddlist.get(index);
// 0:未到时间不动; 1:推送; 2:转人工 // 0:未到时间不动; 1:推送; 2:转人工
if ("劳动者死亡".equals(vo.getTbyy())) { if ("16".equals(vo.getTbyy())) {
remark = "劳动者死亡,转人工!"; remark = "劳动者死亡,转人工!";
socialInfo = new TSocialInfo(); socialInfo = new TSocialInfo();
socialInfo.setId(vo.getSocialId()); socialInfo.setId(vo.getSocialId());
...@@ -298,6 +324,26 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -298,6 +324,26 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
logList.add(socialLog); logList.add(socialLog);
} }
} else { } else {
// 派减离职原因转化:
if (type == 4 && Common.isNotNull(vo.getTbyy())) {
reduceSet = reduceMap.get(vo.getTbyy());
if (reduceSet != null) {
vo.setTbyy(reduceSet.getTbyy());
vo.setZzyy(reduceSet.getZzyy());
vo.setBajcejyy(reduceSet.getBajcejyy());
} else {
remark = "超出医保离职原因的配置,转人工!配置为:"+vo.getTbyy();
socialInfo = new TSocialInfo();
socialInfo.setId(vo.getSocialId());
socialInfo.setYgsHandleStatus(CommonConstants.FIVE_STRING);
renGongList.add(socialInfo);
socialLog = tSocialSoldierLogService.getFriendLog(vo, typeStr, dispatchItem, remark);
if (socialLog != null) {
logList.add(socialLog);
}
continue;
}
}
canPushType = this.getCanPushTypeYsd(socialSetMap, vo); canPushType = this.getCanPushTypeYsd(socialSetMap, vo);
if (1 == canPushType) { if (1 == canPushType) {
try { try {
......
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the yifu4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng (wangiegie@gmail.com)
*/
package com.yifu.cloud.plus.v1.yifu.social.service.impl;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.google.common.collect.Maps;
import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet;
import com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFriendReduceSetMapper;
import com.yifu.cloud.plus.v1.yifu.social.service.TSocialFriendReduceSetService;
import lombok.extern.log4j.Log4j2;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;
/**
* 离职原因税友自动化配置表
*
* @author hgw
* @date 2025-04-14 11:57:06
*/
@Log4j2
@Service
public class TSocialFriendReduceSetServiceImpl extends ServiceImpl<TSocialFriendReduceSetMapper, TSocialFriendReduceSet> implements TSocialFriendReduceSetService {
@Override
public Map<String, TSocialFriendReduceSet> getFriendReduceMap() {
List<TSocialFriendReduceSet> list = baseMapper.getTSocialFriendReduceSetList();
// 将list转化为map
if (list != null && !list.isEmpty()) {
Map<String, TSocialFriendReduceSet> map = Maps.newHashMap();
for (TSocialFriendReduceSet reduceSet : list) {
map.put(reduceSet.getId(), reduceSet);
}
return map;
}
return null;
}
}
...@@ -74,18 +74,12 @@ ...@@ -74,18 +74,12 @@
when '2' then '无固定期限劳动合同' when '2' then '无固定期限劳动合同'
else '固定期限劳动合同' end contractTypeTwo, else '固定期限劳动合同' end contractTypeTwo,
a.CONTRACT_END contractEnd, a.CONTRACT_END contractEnd,
if(a.REDUCE_REASON = '16','其他原因中断缴费','在职人员主动解除劳动合同') tbyy, a.REDUCE_REASON tbyy,
case a.REDUCE_REASON a.REDUCE_REASON zzyy,
when '21' then '职工与用人单位协商一致解除劳动合同(18条1款)' s.SOCIAL_PROVINCE socialProvince,
when '5' then '第四十四条第二项,劳动者开始依法享受基本养老保险待遇' s.SOCIAL_CITY socialCity,
when '16' then '劳动者死亡,或者被人民法院宣告死亡或者宣告失踪' s.SOCIAL_TOWN socialTown,
when '1' then '劳动者提前30天书面通知解除或试用期提前3天通知解除合同' a.SCHOOL_NAME byyx
when '2' then '劳动者严重违反用人单位的规章制度'
else '法律、行政法规规定的其他情形' end zzyy,
s.SOCIAL_PROVINCE socialProvince,
s.SOCIAL_CITY socialCity,
s.SOCIAL_TOWN socialTown,
a.SCHOOL_NAME byyx
</sql> </sql>
...@@ -222,14 +216,8 @@ ...@@ -222,14 +216,8 @@
when '2' then '无固定期限劳动合同' when '2' then '无固定期限劳动合同'
else '固定期限劳动合同' end contractTypeTwo, else '固定期限劳动合同' end contractTypeTwo,
a.CONTRACT_END contractEnd, a.CONTRACT_END contractEnd,
if(a.REDUCE_REASON = '16','劳动者死亡','在职人员解除/终止劳动合同') tbyy, a.REDUCE_REASON tbyy,
case a.REDUCE_REASON a.REDUCE_REASON zzyy,
when '21' then '职工与用人单位协商一致解除劳动合同(18条1款)'
when '5' then '第四十四条第二项,劳动者开始依法享受基本养老保险待遇'
when '16' then '劳动者死亡,或者被人民法院宣告死亡或者宣告失踪'
when '1' then '劳动者提前30天书面通知解除或试用期提前3天通知解除合同'
when '2' then '劳动者严重违反用人单位的规章制度'
else '法律、行政法规规定的其他情形' end zzyy,
s.SOCIAL_PROVINCE socialProvince, s.SOCIAL_PROVINCE socialProvince,
s.SOCIAL_CITY socialCity, s.SOCIAL_CITY socialCity,
s.SOCIAL_TOWN socialTown, s.SOCIAL_TOWN socialTown,
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
~
~ Copyright (c) 2018-2025, lengleng All rights reserved.
~
~ Redistribution and use in source and binary forms, with or without
~ modification, are permitted provided that the following conditions are met:
~
~ Redistributions of source code must retain the above copyright notice,
~ this list of conditions and the following disclaimer.
~ Redistributions in binary form must reproduce the above copyright
~ notice, this list of conditions and the following disclaimer in the
~ documentation and/or other materials provided with the distribution.
~ Neither the name of the yifu4cloud.com developer nor the names of its
~ contributors may be used to endorse or promote products derived from
~ this software without specific prior written permission.
~ Author: lengleng (wangiegie@gmail.com)
~
-->
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFriendReduceSetMapper">
<resultMap id="tSocialFriendReduceSetMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet">
<id property="id" column="ID"/>
<result property="reduceReasonName" column="REDUCE_REASON_NAME"/>
<result property="tbyy" column="TBYY"/>
<result property="zzyy" column="ZZYY"/>
<result property="bajcejyy" column="BAJCEJYY"/>
</resultMap>
<sql id="Base_Column_List">
a.ID,
a.TBYY,
a.ZZYY,
a.BAJCEJYY
</sql>
<!--tSocialFriendReduceSet简单分页查询-->
<select id="getTSocialFriendReduceSetList" resultMap="tSocialFriendReduceSetMap">
SELECT
<include refid="Base_Column_List"/>
FROM t_social_friend_reduce_set a
</select>
</mapper>
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