Commit 02da7e15 authored by huyuchen's avatar huyuchen

预派单 代码修改

parent f55345ec
......@@ -470,7 +470,7 @@ public class TPreDispatchInfo extends BaseEntity {
*/
@Schema(description ="员工类型")
@Size(max = 20, message = "员工类型不可超过20位")
@NotNull(message = "员工姓名不可为空")
@NotNull(message = "员工类型不可为空")
private String empTypeAdd;
/**
......
......@@ -1070,9 +1070,9 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
info.setUnitIdAdd(selectVo.getCustomerId());
info.setUnitNameAdd(selectVo.getCustomerName());
}
// 默认合同名称为代理社保 合同类型为固定期限1
// 默认合同名称为代理社保 合同类型为其他
info.setContractNameAdd(PreDispatchConstants.CONTRACT_NAME);
info.setContractTypeAdd(CommonConstants.ONE_STRING);
info.setContractTypeAdd(CommonConstants.THREE_STRING);
info.setContractStartAdd(info.getContractStart());
// 默认为开始时间后的两年时间
info.setContractEndAdd(info.getContractEnd());
......@@ -1776,18 +1776,6 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
}
}
private void initDayConfMap(HashMap<String, Integer> dayConfMap) {
List<TDispatchDayConf> dayConfList = dispatchDayConfMapper.selectList(Wrappers.<TDispatchDayConf>query().lambda());
if (Common.isNotNull(dayConfList)) {
for (TDispatchDayConf conf : dayConfList) {
dayConfMap.put(Common.isBlankToNullString(conf.getProvince()) +
CommonConstants.DOWN_LINE_STRING + Common.isBlankToNullString(conf.getCity()) +
CommonConstants.DOWN_LINE_STRING + Common.isBlankToNullString(conf.getTown()), conf.getDay());
}
}
}
/**
* 通过身份证+派单类型 确定是否唯一(创建时间为当月的)
*
......@@ -1810,6 +1798,18 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
initExistsMapByIdCards(existsMap, idcards, type);
}
private void initDayConfMap(HashMap<String, Integer> dayConfMap) {
List<TDispatchDayConf> dayConfList = dispatchDayConfMapper.selectList(Wrappers.<TDispatchDayConf>query().lambda());
if (Common.isNotNull(dayConfList)) {
for (TDispatchDayConf conf : dayConfList) {
dayConfMap.put(Common.isBlankToNullString(conf.getProvince()) +
CommonConstants.DOWN_LINE_STRING + Common.isBlankToNullString(conf.getCity()) +
CommonConstants.DOWN_LINE_STRING + Common.isBlankToNullString(conf.getTown()), conf.getDay());
}
}
}
private void initExistsMapByIdCards(Map<String, TPreDispatchInfo> existsMap, List<String> idcards, String type) {
if (Common.isNotNull(idcards)) {
List<TPreDispatchInfo> preDispatchInfoList = baseMapper.selectList(Wrappers.<TPreDispatchInfo>query()
......@@ -2213,7 +2213,7 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
**/
private void initDispatchContractVo(TPreDispatchInfo preInfo, TDispatchImportVo importVo) {
if (Common.isNotNull(preInfo.getContractNameAdd())){
importVo.setContractName(CommonConstants.THREE_STRING);
importVo.setContractName(preInfo.getContractTypeAdd());
if (Common.isNotNull(preInfo.getContractStartAdd())){
importVo.setContractStart(DateUtil.stringToDate(ServiceUtil.
replaceSeparator(preInfo.getContractStartAdd(),CommonConstants.CENTER_SPLIT_LINE_STRING,
......@@ -2224,7 +2224,7 @@ public class TPreDispatchInfoServiceImpl extends ServiceImpl<TPreDispatchInfoMap
replaceSeparator(preInfo.getContractEndAdd(), CommonConstants.CENTER_SPLIT_LINE_STRING,
CommonConstants.SLASH_SPLIT_LINE_STRING), DateUtil.ISO_DATE_FORMAT));
}
importVo.setContractTerm(CommonConstants.TWO_STRING);
importVo.setContractTerm(preInfo.getContractTermAdd());
importVo.setContractType(CommonConstants.ONE_STRING);
importVo.setContractSubName(PreDispatchConstants.CONTRACT_NAME);
}
......
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