Commit c2dde5b5 authored by chenyuxi's avatar chenyuxi

feat: 1.7.14首次提交,瓜子C端信息收集增加“暂存”功能

parent efa04039
...@@ -574,4 +574,7 @@ public class TGzEmpInfo extends BaseEntity { ...@@ -574,4 +574,7 @@ public class TGzEmpInfo extends BaseEntity {
@Schema(description = "持卡人姓名") @Schema(description = "持卡人姓名")
private String accountName; private String accountName;
@Schema(description = "档案状态(0:已提交,1:暂存)")
private String empStatus;
} }
...@@ -48,6 +48,10 @@ public class TGzEmpInfoExportMain implements Serializable { ...@@ -48,6 +48,10 @@ public class TGzEmpInfoExportMain implements Serializable {
@ExcelProperty("员工档案提交时间") @ExcelProperty("员工档案提交时间")
private String createTime; private String createTime;
@ExcelAttribute(name = "档案状态", isDataId = true, readConverterExp = "0=已提交,1=暂存")
@ExcelProperty("档案状态")
private String empStatus;
@ExcelAttribute(name = "档案推送瓜子状态", isDataId = true, readConverterExp = "0=待推送,1=已推送") @ExcelAttribute(name = "档案推送瓜子状态", isDataId = true, readConverterExp = "0=待推送,1=已推送")
@ExcelProperty("档案推送瓜子状态") @ExcelProperty("档案推送瓜子状态")
private String empPushStatus; private String empPushStatus;
......
...@@ -491,6 +491,10 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -491,6 +491,10 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
YifuUser user = getNewYifuUser(); YifuUser user = getNewYifuUser();
TGzEmpInfo tGzEmpInfo = tGzEmpInfoVo; TGzEmpInfo tGzEmpInfo = tGzEmpInfoVo;
Integer offerId = tGzEmpInfoVo.getOfferId(); Integer offerId = tGzEmpInfoVo.getOfferId();
// 1.7.14: 档案状态必传
if (Common.isEmpty(tGzEmpInfoVo.getEmpStatus())) {
return R.failed("档案状态必传!");
}
if (Common.isEmpty(offerId)) { if (Common.isEmpty(offerId)) {
return R.failed("请传参流程ID!"); return R.failed("请传参流程ID!");
} else { } else {
...@@ -504,6 +508,8 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -504,6 +508,8 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
// 测试 郭彤:这个提示改下吧,没必要吧ID还有状态枚举值列出来 2025-6-30 18:09:05 // 测试 郭彤:这个提示改下吧,没必要吧ID还有状态枚举值列出来 2025-6-30 18:09:05
// return R.failed("瓜子Offer状态不对("+gzOfferInfo.getOfferStatus()+"),不可编辑,Offer的ID="+ offerId) // return R.failed("瓜子Offer状态不对("+gzOfferInfo.getOfferStatus()+"),不可编辑,Offer的ID="+ offerId)
} }
// 1.7.14: 档案状态是提交,才更新offer状态
if(CommonConstants.ZERO_STRING.equals(tGzEmpInfoVo.getEmpStatus())){
gzOfferInfo.setOfferStatus("12"); gzOfferInfo.setOfferStatus("12");
gzOfferInfoMapper.updateById(gzOfferInfo); gzOfferInfoMapper.updateById(gzOfferInfo);
...@@ -531,17 +537,25 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -531,17 +537,25 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
} }
} }
} }
}
String gzEmpId = tGzEmpInfoVo.getId(); String gzEmpId = tGzEmpInfoVo.getId();
if (Common.isEmpty(gzEmpId)) { if (Common.isEmpty(gzEmpId)) {
tGzEmpInfo.setCreateBy(user.getId()); tGzEmpInfo.setCreateBy(user.getId());
tGzEmpInfo.setCreateName(user.getNickname()); tGzEmpInfo.setCreateName(user.getNickname());
// 1.7.14: 档案状态是提交,才存 创建时间(提交时间)
if(CommonConstants.ZERO_STRING.equals(tGzEmpInfoVo.getEmpStatus())){
tGzEmpInfo.setCreateTime(LocalDateTime.now()); tGzEmpInfo.setCreateTime(LocalDateTime.now());
}
this.save(tGzEmpInfo); this.save(tGzEmpInfo);
gzEmpId = tGzEmpInfo.getId(); gzEmpId = tGzEmpInfo.getId();
} else { } else {
tGzEmpInfo.setUpdateBy(user.getId()); tGzEmpInfo.setUpdateBy(user.getId());
tGzEmpInfo.setUpdateTime(LocalDateTime.now()); tGzEmpInfo.setUpdateTime(LocalDateTime.now());
// 1.7.14: 档案状态是暂存,清除 创建时间(提交时间)
if(CommonConstants.ONE_STRING.equals(tGzEmpInfoVo.getEmpStatus())){
tGzEmpInfo.setCreateTime(null);
}
this.updateById(tGzEmpInfo); this.updateById(tGzEmpInfo);
} }
// 获取瓜子档案附属信息:先删除后增加: // 获取瓜子档案附属信息:先删除后增加:
...@@ -843,6 +857,22 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -843,6 +857,22 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
if (Common.isEmpty(attaEmp.getAttaName())) { if (Common.isEmpty(attaEmp.getAttaName())) {
attaEmp.setAttaName(CommonConstants.CENTER_SPLIT_LINE_STRING); attaEmp.setAttaName(CommonConstants.CENTER_SPLIT_LINE_STRING);
} }
// 1.7.14: 附件类型映射
// 41(瓜子申明签名)42(瓜子确认签名)NID_A(证件正面) NID_B(证件反面)
// 附件类型转化:声明签字:21;确认签字:22; 9身份证;24 身份证国徽
if("41".equals(atta.getRelationType())){
atta.setRelationType("21");
}
if("42".equals(atta.getRelationType())){
atta.setRelationType("22");
}
if("NID_A".equals(atta.getRelationType())){
atta.setRelationType("9");
}
if("NID_B".equals(atta.getRelationType())){
atta.setRelationType("24");
}
attaEmp.setDomainId(empId); attaEmp.setDomainId(empId);
attaEmp.setCreateBy(user.getId()); attaEmp.setCreateBy(user.getId());
attaEmp.setCreateName(user.getNickname()); attaEmp.setCreateName(user.getNickname());
...@@ -1020,9 +1050,11 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -1020,9 +1050,11 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
// 按gzEmpInfo实体类顺序转化: // 按gzEmpInfo实体类顺序转化:
emp.setEmpName(gzEmpInfo.getName()); emp.setEmpName(gzEmpInfo.getName());
emp.setEmpIdcard(gzEmpInfo.getNationalId()); emp.setEmpIdcard(gzEmpInfo.getNationalId());
emp.setIdProvince(gzEmpInfo.getNativePlaceAreaId()); // 1.7.14: 户籍所在地取值调整
emp.setIdCity(null); emp.setIdProvince(gzEmpInfo.getHukouProvinceAreaId());
emp.setIdTown(null); emp.setIdCity(gzEmpInfo.getHukouCityAreaId());
emp.setIdTown(gzEmpInfo.getHukouCountyAreaId());
// 民族 // 民族
emp.setEmpNational(getDictValue(dictMap, gzEmpInfo.getEthnicGrpCd(), ExcelAttributeConstants.GZ_ETHNIC_GRP_CD)); emp.setEmpNational(getDictValue(dictMap, gzEmpInfo.getEthnicGrpCd(), ExcelAttributeConstants.GZ_ETHNIC_GRP_CD));
// 婚姻状态 // 婚姻状态
...@@ -1050,10 +1082,10 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI ...@@ -1050,10 +1082,10 @@ public class TGzEmpInfoServiceImpl extends ServiceImpl<TGzEmpInfoMapper, TGzEmpI
emp.setContactAddress(gzEmpInfo.getAddress()); emp.setContactAddress(gzEmpInfo.getAddress());
// 户口性质 // 户口性质
emp.setEmpRegisType(getDictValue(dictMap, gzEmpInfo.getHukouType(), ExcelAttributeConstants.GZ_HUKOU_TYPE)); emp.setEmpRegisType(getDictValue(dictMap, gzEmpInfo.getHukouType(), ExcelAttributeConstants.GZ_HUKOU_TYPE));
// 1.7.14: 档案所在地取值调整: ”默认为“安徽省-合肥市-蜀山区”
emp.setFileProvince(gzEmpInfo.getHukouProvinceAreaId()); emp.setFileProvince(12);
emp.setFileCity(gzEmpInfo.getHukouCityAreaId()); emp.setFileCity(135);
emp.setFileTown(gzEmpInfo.getHukouCountyAreaId()); emp.setFileTown(1267);
emp.setBankName(getDictValue(dictMap, gzEmpInfo.getBankCd(), ExcelAttributeConstants.GZ_BANK)); emp.setBankName(getDictValue(dictMap, gzEmpInfo.getBankCd(), ExcelAttributeConstants.GZ_BANK));
emp.setBankSubName(gzEmpInfo.getBankName()); emp.setBankSubName(gzEmpInfo.getBankName());
if (Common.isNotNull(gzEmpInfo.getAccountProvinceAreaId())) { if (Common.isNotNull(gzEmpInfo.getAccountProvinceAreaId())) {
......
...@@ -102,6 +102,7 @@ ...@@ -102,6 +102,7 @@
<result property="hukouCountyAreaId" column="hukou_county_area_id"/> <result property="hukouCountyAreaId" column="hukou_county_area_id"/>
<result property="accountProvinceAreaId" column="account_province_area_id"/> <result property="accountProvinceAreaId" column="account_province_area_id"/>
<result property="accountCityAreaId" column="account_city_area_id"/> <result property="accountCityAreaId" column="account_city_area_id"/>
<result property="empStatus" column="emp_status"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
a.id, a.id,
...@@ -181,7 +182,8 @@ ...@@ -181,7 +182,8 @@
a.hukou_city_area_id, a.hukou_city_area_id,
a.hukou_county_area_id, a.hukou_county_area_id,
a.account_province_area_id, a.account_province_area_id,
a.account_city_area_id a.account_city_area_id,
a.emp_status
</sql> </sql>
<sql id="tGzEmpInfo_where"> <sql id="tGzEmpInfo_where">
<if test="tGzEmpInfo != null"> <if test="tGzEmpInfo != null">
...@@ -194,6 +196,9 @@ ...@@ -194,6 +196,9 @@
<if test="tGzEmpInfo.offerId != null "> <if test="tGzEmpInfo.offerId != null ">
AND a.offer_id = #{tGzEmpInfo.offerId} AND a.offer_id = #{tGzEmpInfo.offerId}
</if> </if>
<if test="tGzEmpInfo.empStatus != null and tGzEmpInfo.empStatus.trim() != ''">
AND a.emp_status = #{tGzEmpInfo.empStatus}
</if>
<if test="tGzEmpInfo.empPushStatus != null and tGzEmpInfo.empPushStatus.trim() != ''"> <if test="tGzEmpInfo.empPushStatus != null and tGzEmpInfo.empPushStatus.trim() != ''">
AND a.emp_push_status = #{tGzEmpInfo.empPushStatus} AND a.emp_push_status = #{tGzEmpInfo.empPushStatus}
</if> </if>
...@@ -411,7 +416,7 @@ ...@@ -411,7 +416,7 @@
a.del_flag = '0' a.del_flag = '0'
<include refid="tGzEmpInfo_where"/> <include refid="tGzEmpInfo_where"/>
</where> </where>
ORDER by a.create_time desc,a.id desc ORDER by a.emp_status,a.create_time desc,a.id desc
</select> </select>
<!--count--> <!--count-->
...@@ -431,6 +436,7 @@ ...@@ -431,6 +436,7 @@
a.id, a.id,
a.biz_id, a.biz_id,
a.offer_id, a.offer_id,
a.emp_status,
a.emp_push_status, a.emp_push_status,
a.contract_push_status, a.contract_push_status,
a.contract_atta_push_status, a.contract_atta_push_status,
...@@ -517,7 +523,7 @@ ...@@ -517,7 +523,7 @@
<include refid="tGzEmpInfo_where"/> <include refid="tGzEmpInfo_where"/>
</where> </where>
group by a.id group by a.id
ORDER by a.create_time desc,a.id desc ORDER by a.emp_status,a.create_time desc,a.id desc
<if test="tGzEmpInfo.limitStart != null"> <if test="tGzEmpInfo.limitStart != null">
limit #{tGzEmpInfo.limitStart},#{tGzEmpInfo.limitEnd} limit #{tGzEmpInfo.limitStart},#{tGzEmpInfo.limitEnd}
</if> </if>
......
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