Commit a5e0d51f authored by hongguangwu's avatar hongguangwu

MVP1.4-人员合同相关

parent 8d64e01e
......@@ -1548,15 +1548,25 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
employee = tEmployeeInfoMapper.selectById(employeeInfo.getEmpId());
initEmpBusinessInfo(employeeInfo, employee, businessVo, tBusinessEmployeeExtendInfo);
}
// 获取合同数据
// 获取合同数据(去除作废,终止)
List<TEmployeeContractInfo> contractInfoList = contractInfoMapper.selectList(Wrappers.<TEmployeeContractInfo>query().lambda()
.eq(TEmployeeContractInfo::getEmpIdcard,employeeInfo.getEmpIdcard())
.eq(TEmployeeContractInfo::getIsObsolete,CommonConstants.ZERO_STRING)
.ne(TEmployeeContractInfo::getSituation, EmployeeConstants.SITUATION_SIX)
.ne(TEmployeeContractInfo::getSituation, EmployeeConstants.SITUATION_SEVEN)
.eq(TEmployeeContractInfo::getSettleDomain, settleDomain)
.orderByDesc(TEmployeeContractInfo::getContractStart));
// 获取合同数据(全部2023-1-16 11:32:12 倩倩要求:B端人员里要看到作废中止的合同(原话:显示没有问题))
List<TEmployeeContractInfo> allContractInfoList = contractInfoMapper.selectList(Wrappers.<TEmployeeContractInfo>query().lambda()
.eq(TEmployeeContractInfo::getEmpIdcard,employeeInfo.getEmpIdcard())
.eq(TEmployeeContractInfo::getIsObsolete,CommonConstants.ZERO_STRING)
.eq(TEmployeeContractInfo::getSettleDomain, settleDomain)
.orderByDesc(TEmployeeContractInfo::getContractStart));
// 处理详情对应的合同信息
if (Common.isNotNull(contractInfoList)){
initEmpBusinessContractInfo(businessDetailVo, contractInfoList);
initEmpBusinessContractInfo(businessDetailVo, contractInfoList, allContractInfoList);
}
// 获取最高学历
List<TEmpEducation> educations = empEducationMapper.selectList(Wrappers.<TEmpEducation>query().lambda()
......@@ -1606,14 +1616,15 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
return R.ok(businessVo);
}
private void initEmpBusinessContractInfo(EmployeeBusinessDetailVo businessDetailVo, List<TEmployeeContractInfo> contractInfoList) {
private void initEmpBusinessContractInfo(EmployeeBusinessDetailVo businessDetailVo
, List<TEmployeeContractInfo> contractInfoList, List<TEmployeeContractInfo> allContractInfoList) {
businessDetailVo.setSituationCount(contractInfoList.size());
if (businessDetailVo.getSituationCount() > CommonConstants.ONE_INT){
businessDetailVo.setSituation(EmpBusinessConstants.empContractSituationRenew);
}else {
businessDetailVo.setSituation(EmpBusinessConstants.empContractSituationNew);
}
businessDetailVo.setContractInfoList(contractInfoList);
businessDetailVo.setContractInfoList(allContractInfoList);
TEmployeeContractInfo contractInfo = contractInfoList.get(CommonConstants.ZERO_INT);
if (null != contractInfo.getContractEnd()){
businessDetailVo.setContractEndDate(DateUtil.formatDate(contractInfo.getContractEnd()));
......
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