Commit d82dc171 authored by huyuchen's avatar huyuchen

薪资审核页面接口修改

parent b7f4cf7e
......@@ -32,7 +32,6 @@ import com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser;
import com.yifu.cloud.plus.v1.yifu.common.dapr.util.ArchivesDaprUtil;
import com.yifu.cloud.plus.v1.yifu.common.dapr.util.UpmsDaprUtils;
import com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils;
import com.yifu.cloud.plus.v1.yifu.insurances.util.ValidityUtil;
import com.yifu.cloud.plus.v1.yifu.social.constants.PreDispatchConstants;
import com.yifu.cloud.plus.v1.yifu.social.entity.*;
import com.yifu.cloud.plus.v1.yifu.social.mapper.*;
......@@ -84,6 +83,9 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
@Autowired
private TDispatchInfoService dispatchInfoService;
@Autowired
private SysHouseHoldInfoMapper sysHouseHoldInfoMapper;
/**
* 预派单记录简单分页查询
*
......@@ -577,7 +579,8 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
}
@Override
public List<ErrorMessage> batchSavePreDisPatchAdd(List<TPreDispatchInfo> listInfo, YifuUser user, String socialHouse, String fundHouse, String departId) {
public List<ErrorMessage> batchSavePreDisPatchAdd(List<TPreDispatchInfo> listInfo, YifuUser user, String socialHouse
, String fundHouse, String departId) {
List<ErrorMessage> errorList = new ArrayList<>();
R<TSettleDomainSelectVo> domainR = archivesDaprUtil.getSettleDomainSelectVoById(departId);
// 获取区域数据MAP
......@@ -631,12 +634,8 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
info.setPreStatus(CommonConstants.ZERO_STRING);
// 为验重添加到MAP
existsMap.put(info.getEmpIdcard() + CommonConstants.DOWN_LINE_STRING + info.getPayAddress(), info);
if (Common.isEmpty(info.getExceptionContent())) {
errorList.add(new ErrorMessage(i, "保存成功!", CommonConstants.GREEN));
} else {
if (!Common.isEmpty(info.getExceptionContent())) {
info.setPreStatus(CommonConstants.ONE_STRING);
errorList.add(new ErrorMessage(i, "保存成功!" +
info.getExceptionContent(), CommonConstants.RED));
}
baseMapper.insert(info);
}
......@@ -705,12 +704,8 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
}
// 为验重添加到MAP
existsMap.put(info.getEmpIdcard() + CommonConstants.DOWN_LINE_STRING + info.getPayAddress(), info);
if (Common.isEmpty(info.getExceptionContent())) {
errorList.add(new ErrorMessage(i, CommonConstants.SAVE_SUCCESS, CommonConstants.GREEN));
} else {
if (!Common.isEmpty(info.getExceptionContent())) {
info.setPreStatus(CommonConstants.ONE_STRING);
errorList.add(new ErrorMessage(i, CommonConstants.SAVE_SUCCESS +
info.getExceptionContent(), CommonConstants.RED));
}
baseMapper.insert(info);
}
......@@ -978,11 +973,6 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
info.setContractEndAdd(info.getContractEnd());
info.setContractStartAdd(info.getContractStart());
baseMapper.updatePreDispatchInfoById(info);
if (Common.isNotNull(info.getExceptionContent())){
errorList.add(new ErrorMessage(i, CommonConstants.SAVE_SUCCESS+info.getExceptionContent(),CommonConstants.RED));
}else {
errorList.add(new ErrorMessage(i, CommonConstants.SAVE_SUCCESS,CommonConstants.GREEN));
}
}
private static boolean isaBoolean(LocalDateTime temp, LocalDateTime now) {
......@@ -1116,8 +1106,13 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
info.setContractTermAdd(Integer.toString(Common.getYearOfTime(info.getContractStart(), info.getContractEnd())));
// 默认工时制 综合工时制2
info.setWorkingHoursAdd(CommonConstants.TWO_STRING);
info.setSocialHouseAdd(socialHouse);
info.setFundHouseAdd(fundHouse);
SysHouseHoldInfo sysHouseHoldInfo = sysHouseHoldInfoMapper.selectOne(Wrappers.<SysHouseHoldInfo>query().lambda()
.eq(SysHouseHoldInfo::getName, socialHouse).eq(SysHouseHoldInfo::getType, CommonConstants.ZERO_STRING));
info.setSocialHouseAdd(sysHouseHoldInfo.getId());
SysHouseHoldInfo sysHouseHoldFund = sysHouseHoldInfoMapper.selectOne(Wrappers.<SysHouseHoldInfo>query().lambda()
.eq(SysHouseHoldInfo::getName, fundHouse).eq(SysHouseHoldInfo::getType, CommonConstants.ONE_STRING));
info.setFundHouseAdd(sysHouseHoldFund.getId());
}
/**
......@@ -2207,7 +2202,8 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
Common.isNotNull(preInfo.getPensionStart())){
importVo.setPensionStart(DateUtil.getFirstDay(preInfo.getPensionStart()));
if (Common.isNotNull(preInfo.getPensionAddress())){
importVo.setSocialHousehold(preInfo.getSocialHouseAdd());
SysHouseHoldInfo sysHouseHoldInfo = sysHouseHoldInfoMapper.selectById(preInfo.getSocialHouseAdd());
importVo.setSocialHousehold(sysHouseHoldInfo.getName());
}
SysBaseSetInfo socialBaseSet = getSysBaseSetInfo(preInfo.getSocialProvince(),preInfo.getSocialCity(),
preInfo.getSocialTown(),preInfo.getSocialHouseAdd(),CommonConstants.ZERO_STRING);
......@@ -2333,7 +2329,8 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
importVo.setProvidentPer(preInfo.getFundPersonalPer());
}
if (Common.isNotNull(preInfo.getFundAddress())){
importVo.setProvidentHousehold(preInfo.getFundHouseAdd());
SysHouseHoldInfo sysHouseHoldInfo = sysHouseHoldInfoMapper.selectById(preInfo.getFundHouseAdd());
importVo.setProvidentHousehold(sysHouseHoldInfo.getName());
}
}
......
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