薪酬系统-多语言,拉取0801分支改动,适配部分中文表述
This commit is contained in:
parent
baf1da3edd
commit
e4f0746650
Binary file not shown.
|
|
@ -725,8 +725,8 @@ public class SIArchivesBiz extends Service {
|
|||
.otherPaymentBaseString(paramReq.getPaymentForm())
|
||||
.build();
|
||||
//校验福利基数是否符合上下限要求,
|
||||
if (!checkWelBaseLimit(insertOtherInfo.getOtherSchemeId(),insertOtherInfo.getOtherPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
if (!checkWelBaseLimit(insertOtherInfo.getOtherSchemeId(),insertOtherInfo.getOtherPaymentBaseString(), user)) {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 543878, "其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
|
||||
}
|
||||
encryptUtil.encrypt(insertOtherInfo, InsuranceArchivesOtherSchemePO.class, user);
|
||||
otherSchemeMapper.insert(insertOtherInfo);
|
||||
|
|
@ -741,7 +741,7 @@ public class SIArchivesBiz extends Service {
|
|||
baseInfoPO.setOtherArchivesId(otherInfos.get(0).getId());
|
||||
getInsuranceBaseInfoMapper().updateById(baseInfoPO);
|
||||
} else {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "档案不存在!"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 544305, "档案不存在!"));
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -827,8 +827,8 @@ public class SIArchivesBiz extends Service {
|
|||
.employeeId(param.getEmployeeId())
|
||||
.build();
|
||||
//校验福利基数是否符合上下限要求,
|
||||
if (!checkWelBaseLimit(insertFundInfo.getFundSchemeId(),insertFundInfo.getFundPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
if (!checkWelBaseLimit(insertFundInfo.getFundSchemeId(),insertFundInfo.getFundPaymentBaseString(), user)) {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 543880, "公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
|
||||
}
|
||||
encryptUtil.encrypt(insertFundInfo, InsuranceArchivesFundSchemePO.class, user);
|
||||
fundSchemeMapper.insert(insertFundInfo);
|
||||
|
|
@ -843,7 +843,7 @@ public class SIArchivesBiz extends Service {
|
|||
baseInfoPO.setFundArchivesId(fundInfos.get(0).getId());
|
||||
getInsuranceBaseInfoMapper().updateById(baseInfoPO);
|
||||
} else {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "档案不存在!"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 544305, "档案不存在!"));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -936,8 +936,8 @@ public class SIArchivesBiz extends Service {
|
|||
.paymentOrganization(param.getPaymentOrganization())
|
||||
.build();
|
||||
//校验福利基数是否符合上下限要求
|
||||
if (!checkWelBaseLimit(insertSocialInfo.getSocialSchemeId(),insertSocialInfo.getSocialPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
if (!checkWelBaseLimit(insertSocialInfo.getSocialSchemeId(),insertSocialInfo.getSocialPaymentBaseString(), user)) {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 543882, "社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
|
||||
}
|
||||
encryptUtil.encrypt(insertSocialInfo, InsuranceArchivesSocialSchemePO.class, user);
|
||||
socialSchemeMapper.insert(insertSocialInfo);
|
||||
|
|
@ -952,7 +952,7 @@ public class SIArchivesBiz extends Service {
|
|||
baseInfoPO.setSocialArchivesId(socialInfos.get(0).getId());
|
||||
getInsuranceBaseInfoMapper().updateById(baseInfoPO);
|
||||
} else {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "档案不存在!"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(), 544305, "档案不存在!"));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ public class SalaryFormulaEmployeeDTO {
|
|||
//部门
|
||||
@SalaryFormulaVar(defaultLabel = "部门", labelId = 27511, dataType = "string")
|
||||
private String departmentName;
|
||||
@SalaryFormulaVar(defaultLabel = "部门ID", labelId = 86185, dataType = "string")
|
||||
@SalaryFormulaVar(defaultLabel = "部门ID", labelId = 22279, dataType = "string")
|
||||
private Long departmentId;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
|
||||
List<ExtEmpPO> extEmpPOS = getExternalEmployeeMapper().listSome(ExtEmpPO.builder().username(param.getUsername()).build());
|
||||
if (CollectionUtils.isNotEmpty(extEmpPOS)) {
|
||||
throw new SalaryRunTimeException("姓名已存在!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544753,"姓名已存在!"));
|
||||
}
|
||||
|
||||
ExtEmpPO po = new ExtEmpPO();
|
||||
|
|
@ -110,7 +110,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
if (!StringUtils.equals(oldPO.getUsername(), param.getUsername())) {
|
||||
List<ExtEmpPO> extEmpPOS = getExternalEmployeeMapper().listSome(ExtEmpPO.builder().username(param.getUsername()).build());
|
||||
if (CollectionUtils.isNotEmpty(extEmpPOS)) {
|
||||
throw new SalaryRunTimeException("姓名已存在!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544753,"姓名已存在!"));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -231,15 +231,15 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
|
||||
// 模板表头
|
||||
List<Object> headerList = Lists.newArrayList(
|
||||
SalaryI18nUtil.getI18nLabel(25034, "姓名"),
|
||||
SalaryI18nUtil.getI18nLabel(27511, "部门"),
|
||||
SalaryI18nUtil.getI18nLabel(33553, "分部"),
|
||||
SalaryI18nUtil.getI18nLabel(1516, "入职日期"),
|
||||
SalaryI18nUtil.getI18nLabel(125238, "手机号"),
|
||||
SalaryI18nUtil.getI18nLabel(1933, "工号"),
|
||||
SalaryI18nUtil.getI18nLabel(1887, "身份证号码"),
|
||||
SalaryI18nUtil.getI18nLabel(0, "本人开户的银行卡卡号"),
|
||||
SalaryI18nUtil.getI18nLabel(0, "本人开户的银行卡开户支行全称"));
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),25034, "姓名"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),27511, "部门"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),33553, "分部"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),1516, "入职日期"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),125238, "手机号"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),1933, "工号"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),1887, "身份证号码"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),544309, "本人开户的银行卡卡号"),
|
||||
SalaryI18nUtil.getI18nLabel(user.getLanguage(),544310, "本人开户的银行卡开户支行全称"));
|
||||
List<String> dataIndexList = Lists.newArrayList("username", "departmentName", "subcompanyName", "companystartdate", "mobile", "workcode", "idNo", "bankCardNum", "bankName");
|
||||
|
||||
// excel导出的数据
|
||||
|
|
@ -248,8 +248,8 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
|
||||
// 注释
|
||||
List<ExcelComment> excelComments = Lists.newArrayList();
|
||||
excelComments.add(new ExcelComment(0, 0, 1, 2, SalaryI18nUtil.getI18nLabel(30036, "必填")));
|
||||
excelComments.add(new ExcelComment(3, 0, 4, 2, SalaryI18nUtil.getI18nLabel(542348, "格式样例为'2022-01-01'、'2022/1/1'")));
|
||||
excelComments.add(new ExcelComment(0, 0, 1, 2, SalaryI18nUtil.getI18nLabel(user.getLanguage(),30036, "必填")));
|
||||
excelComments.add(new ExcelComment(3, 0, 4, 2, SalaryI18nUtil.getI18nLabel(user.getLanguage(),542348, "格式样例为'2022-01-01'、'2022/1/1'")));
|
||||
|
||||
String sheetName = "非系统人员导入模板";
|
||||
return ExcelUtilPlus.genWorkbookV2(rows, sheetName, excelComments);
|
||||
|
|
@ -282,7 +282,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
|
||||
//excel文件id
|
||||
String imageId = Util.null2String(param.getImageId());
|
||||
Validate.notBlank(imageId, SalaryI18nUtil.getI18nLabel(542127, "imageId为空"));
|
||||
Validate.notBlank(imageId, SalaryI18nUtil.getI18nLabel(user.getLanguage(),542127, "imageId为空"));
|
||||
|
||||
// 失败的数量
|
||||
int failCount = 0;
|
||||
|
|
@ -305,10 +305,10 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
// 处理数值
|
||||
List<Map<String, Object>> data = ExcelParseHelper.parse2Map(sheet, 1);
|
||||
if (CollectionUtils.isEmpty(headers)) {
|
||||
throw new SalaryRunTimeException("表头为空");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542317,"表头为空"));
|
||||
}
|
||||
if (CollectionUtils.isEmpty(data)) {
|
||||
throw new SalaryRunTimeException("无数据");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),508873,"无数据"));
|
||||
}
|
||||
//存储待新增和待更新的ExtEmpPO数据
|
||||
List<ExtEmpPO> updateExtEmpPOList = new ArrayList<>();
|
||||
|
|
@ -316,23 +316,24 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
//遍历excel表具体数据
|
||||
for (int i = 0; i < data.size(); i++) {
|
||||
|
||||
String row = "第" + (i + 1) + "行";
|
||||
// String row = "第" + (i + 1) + "行";
|
||||
String row = SalaryI18nUtil.getI18nLabel(user.getLanguage(),542129,"错误行") + (i + 1) + ":";
|
||||
|
||||
boolean isError = false;
|
||||
Map<String, Object> map = data.get(i);
|
||||
Long employeeId = 0L;
|
||||
|
||||
String username = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(25034, "姓名"), "");
|
||||
String departmentName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(27511, "部门"), "");
|
||||
String subcompanyName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(33553, "分部"), "");
|
||||
String companystartdate = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(1516, "入职日期"), "");
|
||||
String username = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),25034, "姓名"), "");
|
||||
String departmentName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),27511, "部门"), "");
|
||||
String subcompanyName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),33553, "分部"), "");
|
||||
String companystartdate = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),1516, "入职日期"), "");
|
||||
|
||||
//校验姓名
|
||||
if (StringUtils.isBlank(username)) {
|
||||
//姓名是必填项
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(102838, "姓名不能为空"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),542130, "姓名不能为空"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
long usernameNum = updateExtEmpPOList.stream().filter(f -> f.getUsername().equals(username)).count() + insertExtEmpPOList.stream().filter(f -> f.getUsername().equals(username)).count();
|
||||
|
|
@ -340,7 +341,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
//excel中姓名相同时,只会录入第一次出现的数据
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(102838, "本次excel文件中已存在该姓名相关数据,本行数据无法录入"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544758, "本次excel文件中已存在该姓名相关数据,本行数据无法录入"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
//校验部门、分部
|
||||
|
|
@ -351,7 +352,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
if (subCompanyInfos.size() == 0) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "分部信息不存在,请检查分部数据是否正确"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544748, "分部信息不存在,请检查分部数据是否正确"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
}
|
||||
|
|
@ -360,14 +361,14 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
if (deptInfos.size() == 0) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "部门信息不存在,请检查部门数据是否正确"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544749, "部门信息不存在,请检查部门数据是否正确"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
}
|
||||
if (StringUtils.isNotBlank(companystartdate) && (companystartdate.length() < 10 || !SalaryDateUtil.checkDay(companystartdate.substring(0, 10)))) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "入职日期格式错误,正确格式为YYYY-MM或者yyyy-MM-dd"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544312, "入职日期格式错误,正确格式为YYYY-MM或者yyyy-MM-dd"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
|
||||
|
|
@ -392,13 +393,13 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
if(subCompanyInfos.size() == 0 && deptInfos.size() > 1) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "系统中存在重复部门信息,无法指定当前人员关联的唯一部门,请通过填写部门所属的分部信息来缩小部门筛选范围"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544313, "系统中存在重复部门信息,无法指定当前人员关联的唯一部门,请通过填写部门所属的分部信息来缩小部门筛选范围"));
|
||||
excelComments.add(errorMessageMap);
|
||||
} else if (subCompanyInfos.size() > 1 && deptInfos.size() == 0) {
|
||||
//部门结果数为0,分部结果数大于1,则无法匹配
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "系统中存在重复分部信息,无法指定当前人员关联的唯一分部,请通过填写人员所属的部门信息来缩小分部筛选范围"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544314, "系统中存在重复分部信息,无法指定当前人员关联的唯一分部,请通过填写人员所属的部门信息来缩小分部筛选范围"));
|
||||
excelComments.add(errorMessageMap);
|
||||
} else if (subCompanyInfos.size() >= 1 && deptInfos.size() >= 1) {
|
||||
//部门结果数大于等于1,分部结果数大于等于1,筛选出可配对的组合,根据部门的所属分部字段进行配对
|
||||
|
|
@ -410,12 +411,12 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
if (targetDeptInfos.size() == 0) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "部门与分部无法匹配"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544315, "部门与分部无法匹配"));
|
||||
excelComments.add(errorMessageMap);
|
||||
} else if (targetDeptInfos.size() > 1) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "该组数据中的部门和分部信息在系统中出现多组匹配的部门和分布组合,无法指定唯一的部门和分部组合"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544316, "该组数据中的部门和分部信息在系统中出现多组匹配的部门和分布组合,无法指定唯一的部门和分部组合"));
|
||||
excelComments.add(errorMessageMap);
|
||||
} else {
|
||||
targetSubCompanyInfos = subCompanyInfos.stream().filter(f -> f.getId().equals(targetDeptInfos.get(0).getSubcompanyid1())).collect(Collectors.toList());
|
||||
|
|
@ -439,7 +440,7 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
} else if (targetExtEmpInfoList.size() > 1) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "数据库中非系统人员信息存在姓名相同数据,请先确保姓名唯一"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544317, "数据库中非系统人员信息存在姓名相同数据,请先确保姓名唯一"));
|
||||
excelComments.add(errorMessageMap);
|
||||
} else {
|
||||
if (!isError) {
|
||||
|
|
@ -493,15 +494,15 @@ public class ExtEmpServiceImpl extends Service implements ExtEmpService {
|
|||
BeanUtils.copyProperties(po, resultPo);
|
||||
resultPo.setUpdateTime(new Date());
|
||||
}
|
||||
String username = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(25034, "姓名"), "");
|
||||
// String departmentName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(27511, "部门"), "");
|
||||
// String subcompanyName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(33553, "分部"), "");
|
||||
String companystartdate = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(1516, "入职日期"), "");
|
||||
String mobile = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(125238, "手机号"), "");
|
||||
String workcode = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(1933, "工号"), "");
|
||||
String idNo = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(1887, "身份证号码"), "");
|
||||
String bankCardNum = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(0, "本人开户的银行卡卡号"), "");
|
||||
String bankName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(0, "本人开户的银行卡开户支行全称"), "");
|
||||
String username = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),25034, "姓名"), "");
|
||||
// String departmentName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),27511, "部门"), "");
|
||||
// String subcompanyName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),33553, "分部"), "");
|
||||
String companystartdate = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),1516, "入职日期"), "");
|
||||
String mobile = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),125238, "手机号"), "");
|
||||
String workcode = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),1933, "工号"), "");
|
||||
String idNo = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),1887, "身份证号码"), "");
|
||||
String bankCardNum = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544309, "本人开户的银行卡卡号"), "");
|
||||
String bankName = (String) map.getOrDefault(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544310, "本人开户的银行卡开户支行全称"), "");
|
||||
|
||||
if (StringUtils.isNotBlank(companystartdate)) {
|
||||
resultPo.setCompanystartdate(companystartdate.substring(0, 10));
|
||||
|
|
|
|||
|
|
@ -1551,10 +1551,10 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
|||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),542452, "账单月份输入有误,请参照“2022-09”这种格式进行检查"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
if (headers.contains(SalaryI18nUtil.getI18nLabel(0, "补缴月份")) && (supplementaryMonth.length() < 7 || !SalaryDateUtil.checkYearMonth(supplementaryMonth.substring(0, 7)))) {
|
||||
if (headers.contains(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542265, "补缴月份")) && (supplementaryMonth.length() < 7 || !SalaryDateUtil.checkYearMonth(supplementaryMonth.substring(0, 7)))) {
|
||||
isError = true;
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(0, "补缴月份输入有误,请参照“2022-09”这种格式进行检查"));
|
||||
errorMessageMap.put("message", row + SalaryI18nUtil.getI18nLabel(user.getLanguage(),544643, "补缴月份输入有误,请参照“2022-09”这种格式进行检查"));
|
||||
excelComments.add(errorMessageMap);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -367,7 +367,7 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
|||
Util_DataCache.setObjVal("welfareChangeSign", "0");
|
||||
} catch (Exception e) {
|
||||
log.info("福利档案-增量数据处理出错:{}", e.getMessage(), e);
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "福利档案-增量数据处理出错"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544406, "福利档案-增量数据处理出错"));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -378,11 +378,11 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
|||
@Override
|
||||
public void deleteArchive(Collection<Long> archiveIds) {
|
||||
if(CollectionUtils.isEmpty(archiveIds)){
|
||||
throw new SalaryRunTimeException("社保福利档案参数为空!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544754,"社保福利档案参数为空!"));
|
||||
}
|
||||
SalarySysConfPO canDelete = getSalarySysConfService(user).getOneByCode(SalarySysConstant.SALARY_ARCHIVE_DELETE);
|
||||
if(Objects.isNull(canDelete) || StringUtils.equals(canDelete.getConfValue(),"0") ){
|
||||
throw new SalaryRunTimeException("不允许删除社保福利档案,请先开启删除档案规则配置!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544755,"不允许删除社保福利档案,请先开启删除档案规则配置!"));
|
||||
}
|
||||
List<InsuranceArchivesBaseInfoPO> insuranceArchivesList = getInsuranceBaseInfoMapper().listByIds(archiveIds);
|
||||
|
||||
|
|
@ -392,13 +392,13 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
|||
boolean err = insuranceArchivesList.stream().anyMatch(po -> !canDeleteTaxAgentIds.contains(po.getPaymentOrganization()));
|
||||
|
||||
if (CollectionUtils.isEmpty(insuranceArchivesList) || err) {
|
||||
throw new SalaryRunTimeException("社保档案不存在,或没有权限删除该社保案!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544756,"社保档案不存在,或没有权限删除该社保案!"));
|
||||
}
|
||||
|
||||
Optional<InsuranceArchivesBaseInfoPO> fixedList = insuranceArchivesList.stream().filter(archive -> !StringUtils.equals(archive.getRunStatus(), EmployeeStatusEnum.STAY_ADD.getValue())
|
||||
&& !StringUtils.equals(archive.getRunStatus(), EmployeeStatusEnum.STOP_PAYMENT_FROM_ADD.getValue())).findFirst();
|
||||
if(fixedList.isPresent()){
|
||||
throw new SalaryRunTimeException("在缴员工、待减员、停止缴纳-来自待减员,无法删除薪资档案!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544757,"在缴员工、待减员、停止缴纳-来自待减员,无法删除薪资档案!"));
|
||||
}
|
||||
List<Long> archiveDelIds = insuranceArchivesList.stream().map(InsuranceArchivesBaseInfoPO::getId).collect(Collectors.toList());
|
||||
List<Long> socialArchiveDelIds = insuranceArchivesList.stream().map(InsuranceArchivesBaseInfoPO::getSocialArchivesId).collect(Collectors.toList());
|
||||
|
|
@ -540,7 +540,7 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
|||
return baseInfoPOList;
|
||||
} catch (Exception e) {
|
||||
log.info("新增福利档案出错:{}", e.getMessage(), e);
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "福利档案新增失败"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544750, "福利档案新增失败"));
|
||||
}
|
||||
}
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -171,18 +171,18 @@ public class SICategoryServiceImpl extends Service implements SICategoryService
|
|||
public Map<String, Object> updateCategoryNameAndPayScope(ICategoryFormDTO iCategoryFormDTO) {
|
||||
ICategoryPO categoryPO = getICategoryMapper().getByIdAndDataType(iCategoryFormDTO.getId(), DataTypeEnum.CUSTOM.getValue());
|
||||
if(categoryPO == null){
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "自定义福利不存在"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542479, "自定义福利不存在"));
|
||||
}
|
||||
// 判断是否启用
|
||||
Integer isUse = categoryPO.getIsUse();
|
||||
if(isUse == 1){
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "编辑失败,请先关闭启用按钮!"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542480, "编辑失败,请先关闭启用按钮!"));
|
||||
}
|
||||
// 判断福利名称是否重复
|
||||
List<ICategoryPO> iCategoryPOS = getICategoryMapper().listByName(iCategoryFormDTO.getInsuranceName());
|
||||
iCategoryPOS = iCategoryPOS.stream().filter(f -> !f.getId().equals(iCategoryFormDTO.getId())).collect(Collectors.toList());
|
||||
if(CollectionUtils.isNotEmpty(iCategoryPOS)){
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "福利名称不能重复"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542481, "福利名称不能重复"));
|
||||
}
|
||||
ICategoryPO iCategoryPO = ICategoryPO.builder().id(iCategoryFormDTO.getId()).insuranceName(iCategoryFormDTO.getInsuranceName())
|
||||
.paymentScope(SalaryEnumUtil.enumArrToString(iCategoryFormDTO.getPaymentScope()))
|
||||
|
|
@ -196,17 +196,17 @@ public class SICategoryServiceImpl extends Service implements SICategoryService
|
|||
public Map<String, Object> deleteCustomCategory(ICategoryFormDTO iCategoryFormDTO) {
|
||||
ICategoryPO categoryPO = getICategoryMapper().getByIdAndDataType(iCategoryFormDTO.getId(), DataTypeEnum.CUSTOM.getValue());
|
||||
if(categoryPO == null){
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "自定义福利不存在"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542479, "自定义福利不存在"));
|
||||
}
|
||||
// 判断是否启用
|
||||
Integer isUse = categoryPO.getIsUse();
|
||||
if(isUse == 1){
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "删除失败,请先关闭启用按钮!"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544308, "删除失败,请先关闭启用按钮!"));
|
||||
}
|
||||
// 判断自定义福利项是否存在核算数据
|
||||
//获取所有福利核算数据
|
||||
List<InsuranceAccountDetailPO> insuranceAccountDetailPOS = getInsuranceAccountDetailMapper().listAll();
|
||||
encryptUtil.decryptList(insuranceAccountDetailPOS, InsuranceAccountDetailPO.class);
|
||||
encryptUtil.decryptList(insuranceAccountDetailPOS, InsuranceAccountDetailPO.class, user);
|
||||
//数据组装
|
||||
List<Map<String, Object>> records = getRecordsBuildService(user).buildCommonRecords(insuranceAccountDetailPOS, null);
|
||||
String welfareTypeName = "";
|
||||
|
|
@ -221,7 +221,7 @@ public class SICategoryServiceImpl extends Service implements SICategoryService
|
|||
welfareTypeName = "other";
|
||||
break;
|
||||
default:
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(542456, "福利类型不在"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542456, "福利类型不存在"));
|
||||
}
|
||||
String welfareNameStart = categoryPO.getId() + welfareTypeName;
|
||||
//校验福利项是否存在核算记录
|
||||
|
|
@ -229,7 +229,7 @@ public class SICategoryServiceImpl extends Service implements SICategoryService
|
|||
if (!Objects.isNull(f.get(welfareNameStart + "Per"))
|
||||
|| !Objects.isNull(f.get(welfareNameStart + "Com"))
|
||||
|| !Objects.isNull(f.get(welfareNameStart + "Base"))) {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0, "删除失败,已存在福利核算记录"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544307, "删除失败,已存在福利核算记录"));
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ public class SIImportServiceImpl extends Service implements SIImportService {
|
|||
String sheetName;
|
||||
//表头
|
||||
if (param.isExtWelArchiveList()) {
|
||||
sheetName = SalaryI18nUtil.getI18nLabel(542679, "非系统人员");
|
||||
sheetName = SalaryI18nUtil.getI18nLabel(user.getLanguage(),542679, "非系统人员");
|
||||
} else if (param.getRunStatuses().size() > 0) {
|
||||
if (param.getRunStatuses().contains(EmployeeStatusEnum.STAY_ADD.getValue()) && param.getRunStatuses().size() == 1) {
|
||||
sheetName = SalaryI18nUtil.getI18nLabel(user.getLanguage(),542711, "待增员");
|
||||
|
|
|
|||
|
|
@ -264,7 +264,7 @@ public class SalaryArchiveExcelServiceImpl extends Service implements SalaryArch
|
|||
// 调薪
|
||||
} else if (isSalaryItemAdjust) {
|
||||
nameI18n += "-" + SalaryI18nUtil
|
||||
.getI18nLabel(SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getLabelId(), SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getDefaultLabel());
|
||||
.getI18nLabel(user.getLanguage(),SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getLabelId(), SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getDefaultLabel());
|
||||
}
|
||||
}
|
||||
String finalNameI18n = nameI18n;
|
||||
|
|
@ -390,7 +390,7 @@ public class SalaryArchiveExcelServiceImpl extends Service implements SalaryArch
|
|||
// SalaryI18nUtil.getI18nLabel(user.getLanguage(),e.getLabelId(), e.getDefaultLabel())
|
||||
// ).collect(Collectors.toList());
|
||||
// SalaryArchiveExcelBO
|
||||
// .createExcelComment(excelComments, SalaryI18nUtil.getI18nLabel(user.getLanguage(),121922, "必填,可填写如:") + Joiner.on(",").join(incomeCategoryOptions), 0, 0, 2, 2);
|
||||
// .createExcelComment(excelComments, SalaryI18nUtil.getI18nLabel(user.getLanguage(),544747, "必填,可填写如:") + Joiner.on(",").join(incomeCategoryOptions), 0, 0, 2, 2);
|
||||
// SalaryArchiveExcelBO.createExcelComment(excelComments, requireI18n + ',' + SalaryI18nUtil.getI18nLabel(user.getLanguage(),127641, "多个账套之间用,分隔"), 0, 0, 3, 3);
|
||||
// int i = enableHr ? 10 : 9;
|
||||
if (isPendingList) {
|
||||
|
|
@ -402,7 +402,7 @@ public class SalaryArchiveExcelServiceImpl extends Service implements SalaryArch
|
|||
excelComments.add(new ExcelComment(7, 0, 9, 2, SalaryI18nUtil.getI18nLabel(user.getLanguage(),542348, "格式样例为'2022-01-01'、'2022/1/1'")));
|
||||
excelComments.add(new ExcelComment(8, 0, 10, 2, SalaryI18nUtil.getI18nLabel(user.getLanguage(),542349, "必填,格式样例为'2022-01-01'、'2022/1/1'")));
|
||||
} else if (isSalaryItemAdjust) {
|
||||
excelComments.add(new ExcelComment(6, 0, 8, 3, SalaryI18nUtil.getI18nLabel(user.getLanguage(),0, "必填,可填写如:")
|
||||
excelComments.add(new ExcelComment(6, 0, 8, 3, SalaryI18nUtil.getI18nLabel(user.getLanguage(),544747, "必填,可填写如:")
|
||||
+ SalaryI18nUtil.getI18nLabel(user.getLanguage(),16250, "入职") + "、"
|
||||
+ SalaryI18nUtil.getI18nLabel(user.getLanguage(),6088, "转正") + "、"
|
||||
+ SalaryI18nUtil.getI18nLabel(user.getLanguage(),542686, "调薪") + "、"
|
||||
|
|
|
|||
|
|
@ -319,11 +319,11 @@ public class SalaryArchiveServiceImpl extends Service implements SalaryArchiveSe
|
|||
@Override
|
||||
public void deleteSalaryArchive(Collection<Long> salaryArchiveIds) {
|
||||
if(CollectionUtils.isEmpty(salaryArchiveIds)){
|
||||
throw new SalaryRunTimeException("薪资档案参数为空!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544759,"薪资档案参数为空!"));
|
||||
}
|
||||
SalarySysConfPO canDelete = getSalarySysConfService(user).getOneByCode(SalarySysConstant.SALARY_ARCHIVE_DELETE);
|
||||
if(Objects.isNull(canDelete) || StringUtils.equals(canDelete.getConfValue(),"0") ){
|
||||
throw new SalaryRunTimeException("不允许删除薪资档案,请先开启删除档案规则配置!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544760,"不允许删除薪资档案,请先开启删除档案规则配置!"));
|
||||
}
|
||||
List<SalaryArchivePO> salaryArchiveList = getSalaryArchiveMapper().listSome(SalaryArchivePO.builder().ids(salaryArchiveIds).build());
|
||||
|
||||
|
|
@ -332,12 +332,12 @@ public class SalaryArchiveServiceImpl extends Service implements SalaryArchiveSe
|
|||
.stream().map(TaxAgentPO::getId).collect(Collectors.toList());
|
||||
boolean err = salaryArchiveList.stream().anyMatch(po -> !canDeleteTaxAgentIds.contains(po.getTaxAgentId()));
|
||||
if(CollectionUtils.isEmpty(salaryArchiveList) || err){
|
||||
throw new SalaryRunTimeException("薪资档案不存在,或没有权限删除该薪资档案!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544761,"薪资档案不存在,或没有权限删除该薪资档案!"));
|
||||
}
|
||||
Optional<SalaryArchivePO> fixedList = salaryArchiveList.stream().filter(archive -> !StringUtils.equals(archive.getRunStatus(), SalaryArchiveStatusEnum.PENDING.getValue())
|
||||
&& !StringUtils.equals(archive.getRunStatus(), SalaryArchiveStatusEnum.STOP_FROM_PENDING.getValue())).findFirst();
|
||||
if(fixedList.isPresent()){
|
||||
throw new SalaryRunTimeException("发薪员工、待停薪员工、停薪_来自待停薪,无法删除薪资档案!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544762,"发薪员工、待停薪员工、停薪_来自待停薪,无法删除薪资档案!"));
|
||||
}
|
||||
List<Long> deleteIds = salaryArchiveList.stream().map(SalaryArchivePO::getId).collect(Collectors.toList());
|
||||
// 删除薪资档案及档案项目
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ import com.engine.salary.service.SalaryBillItemNameService;
|
|||
import com.engine.salary.service.SalaryItemService;
|
||||
import com.engine.salary.service.SalaryTemplateService;
|
||||
import com.engine.salary.util.SalaryEntityUtil;
|
||||
import com.engine.salary.util.SalaryI18nUtil;
|
||||
import com.google.common.collect.Lists;
|
||||
import dm.jdbc.util.IdGenerator;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
|
|
@ -84,12 +85,12 @@ public class SalaryBillItemNameServiceImpl extends Service implements SalaryBill
|
|||
return;
|
||||
List<Long> templateIdList = saveList.stream().map(SalaryBillItemNameSaveParam::getSalaryTemplateId).distinct().collect(Collectors.toList());
|
||||
if(CollectionUtils.isEmpty(templateIdList) || templateIdList.size()>1){
|
||||
throw new SalaryRunTimeException("工资单模板id为空,或存在多个工资单模板id");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544763,"工资单模板id为空,或存在多个工资单模板id"));
|
||||
}
|
||||
Long salaryTemplateId = templateIdList.get(0);
|
||||
SalaryTemplatePO salaryTemplatePO = getSalaryTemplateService(user).getById(salaryTemplateId);
|
||||
if(Objects.isNull(salaryTemplatePO)){
|
||||
throw new SalaryRunTimeException("工资单模板不存在或已被删除");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),0,"工资单模板不存在或已被删除"));
|
||||
}
|
||||
List<SalaryBillItemNamePO> needInsertList = new ArrayList<>();
|
||||
List<SalaryBillItemNamePO> needUpdateList = new ArrayList<>();
|
||||
|
|
|
|||
|
|
@ -992,7 +992,7 @@ public class SalaryBillServiceImpl extends Service implements SalaryBillService
|
|||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739466138709688320").salaryItemValue("3.00").name(SalaryI18nUtil.getI18nLabel(184539, "绩效分值")).sortedIndex(3).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739505579468095489").salaryItemValue("600.00").name(SalaryI18nUtil.getI18nLabel(184540, "工时奖金")).sortedIndex(4).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739505652314767360").salaryItemValue("500.00").name(SalaryI18nUtil.getI18nLabel(184544, "成果奖金")).sortedIndex(5).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739506094797062145").salaryItemValue("200.00").name(SalaryI18nUtil.getI18nLabel(184545, "考勤扣款")).sortedIndex(6).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739506094797062145").salaryItemValue("200.00").name(SalaryI18nUtil.getI18nLabel(33900, "考勤扣款")).sortedIndex(6).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739506691648290816").salaryItemValue("800.00").name(SalaryI18nUtil.getI18nLabel(184546, "餐补")).sortedIndex(7).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739516333975699456").salaryItemValue("1").name(SalaryI18nUtil.getI18nLabel(184547, "当月缺勤")).sortedIndex(8).build());
|
||||
// items.add(SalaryTemplateSalaryItemListDTO.builder().id("739516913670455296").salaryItemValue("200.00").name(SalaryI18nUtil.getI18nLabel(184549, "缺勤扣款")).sortedIndex(9).build());
|
||||
|
|
|
|||
|
|
@ -334,10 +334,10 @@ public class SalaryFormulaServiceImpl extends Service implements SalaryFormulaSe
|
|||
// if (run.isStatus()) {
|
||||
// //返回结果不是数字
|
||||
// if (returnTypeEnum == ReturnTypeEnum.NUMBER && !NumberUtils.isCreatable(String.valueOf(run))) {
|
||||
// throw new SalaryRunTimeException("返回结果不是数值");
|
||||
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542390, "返回结果不是数值"));
|
||||
// }
|
||||
// }else {
|
||||
// throw new SalaryRunTimeException("公式配置异常");
|
||||
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544764,"公式配置异常"));
|
||||
// }
|
||||
// }
|
||||
|
||||
|
|
|
|||
|
|
@ -647,7 +647,7 @@ public class SalarySobItemServiceImpl extends Service implements SalarySobItemSe
|
|||
private SalaryItemPO checkItemExists(Long salaryItemId, Map<Long, SalaryItemPO> salaryItemsMap) {
|
||||
SalaryItemPO salaryItemPO = salaryItemsMap.get(salaryItemId);
|
||||
if (ObjectUtils.isEmpty(salaryItemPO)){
|
||||
throw new SalaryRunTimeException("保存失败!存在薪资项目不存在或已被删除");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544765,"保存失败!存在薪资项目不存在或已被删除"));
|
||||
}
|
||||
return salaryItemPO;
|
||||
}
|
||||
|
|
@ -736,17 +736,17 @@ public class SalarySobItemServiceImpl extends Service implements SalarySobItemSe
|
|||
// 查询薪资账套
|
||||
SalarySobPO salarySobPO = salarySobBiz.getById(param.getSalarySobId());
|
||||
if (Objects.isNull(salarySobPO)) {
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(98379, "参数错误,薪资账套不存在或者已被删除"));
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542420, "参数错误,薪资账套不存在或者已被删除"));
|
||||
}
|
||||
// 查询薪资项目
|
||||
List<SalarySobItemPO> salarySobItemPOS = getSalarySobItemMapper().listSome(SalarySobItemPO.builder().salarySobId(param.getSalarySobId()).salaryItemId(param.getSalaryItemId()).build());
|
||||
if (CollectionUtils.isEmpty(salarySobItemPOS)){
|
||||
throw new SalaryRunTimeException("账套中薪资项目不存在");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544766,"账套中薪资项目不存在"));
|
||||
}
|
||||
SalarySobItemPO salarySobItemPO = salarySobItemPOS.get(0);
|
||||
SalaryItemPO salaryItemPO = getSalaryItemService(user).getById(salarySobItemPO.getSalaryItemId());
|
||||
if (ObjectUtils.isEmpty(salaryItemPO)){
|
||||
throw new SalaryRunTimeException("薪资项目不存在或已被删除");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544767,"薪资项目不存在或已被删除"));
|
||||
}
|
||||
//获取系统值
|
||||
List<SalarySobDefaultItemPO> salarySobDefaultItemPOS = getSalarySobDefaultItemMapper().listAll();
|
||||
|
|
|
|||
|
|
@ -396,11 +396,11 @@ public class TaxAgentManageRangeServiceImpl extends Service implements TaxAgentM
|
|||
public void saveExtRange(TaxAgentManageRangeExtSaveParam saveParam) {
|
||||
|
||||
if (saveParam == null) {
|
||||
throw new SalaryRunTimeException("参数错误");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),389204,"参数错误"));
|
||||
}
|
||||
Long taxAgentId = saveParam.getTaxAgentId();
|
||||
if (Objects.isNull(taxAgentId)) {
|
||||
throw new SalaryRunTimeException("个税扣缴义务人的id不允许为空");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),542557,"个税扣缴义务人的id不允许为空"));
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -562,7 +562,7 @@ public class TaxAgentManageRangeServiceImpl extends Service implements TaxAgentM
|
|||
@Override
|
||||
public PageInfo<TaxAgentExtRangePO> listExt(TaxAgentRangeExtQueryParam param) {
|
||||
if (param.getTaxAgentId() == null) {
|
||||
throw new SalaryRunTimeException("扣缴义务人id为空");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544768,"扣缴义务人id为空"));
|
||||
}
|
||||
|
||||
List<TaxAgentExtRangePO> taxAgentExtRangePOS = getTaxAgentExtRangeMapper().list(TaxAgentExtRangePO.builder().taxAgentId(param.getTaxAgentId()).build());
|
||||
|
|
|
|||
|
|
@ -485,12 +485,12 @@ public class TaxAgentServiceImpl extends Service implements TaxAgentService {
|
|||
// 被社保福利档案引用
|
||||
List<InsuranceArchivesBaseInfoPO> socialByPaymentOrganization = getInsuranceBaseInfoMapper().getSocialByPaymentOrganization(id);
|
||||
if(CollectionUtils.isNotEmpty(socialByPaymentOrganization)){
|
||||
throw new SalaryRunTimeException("存在社保福利档案引用");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544751, "存在社保福利档案引用"));
|
||||
}
|
||||
// 被社保福利台账引用
|
||||
List<InsuranceAccountBatchPO> insuranceArchiveList = getInsuranceAccountBatchMapper().list(InsuranceAccountBatchParam.builder().taxAgents(Collections.singletonList(id)).build());
|
||||
if(CollectionUtils.isNotEmpty(insuranceArchiveList)){
|
||||
throw new SalaryRunTimeException("存在社保福利台账引用");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544752, "存在社保福利台账引用"));
|
||||
}
|
||||
//被社保福利档案引用
|
||||
// List<InsuranceArchivesSocialSchemePO> socialSchemePOList = new LambdaQueryChainWrapper<>(siArchivesSocialMapper)
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ public class ExtEmpController {
|
|||
User user = HrmUserVarify.getUser(request, response);
|
||||
XSSFWorkbook workbook = getExtEmpWrapper(user).exportImportTemplate();
|
||||
String time = LocalDate.now().toString();
|
||||
String fileName = SalaryI18nUtil.getI18nLabel(0, "非系统人员导入模板") + time;
|
||||
String fileName = SalaryI18nUtil.getI18nLabel(user.getLanguage(), 544311, "非系统人员导入模板") + time;
|
||||
try {
|
||||
fileName = URLEncoder.encode(fileName + ".xlsx", "UTF-8").replaceAll("\\+", "%20");
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
|
|
|
|||
|
|
@ -263,7 +263,7 @@ public class SISchemeController {
|
|||
String fileName;
|
||||
//表头
|
||||
if (param.isExtWelArchiveList()) {
|
||||
fileName = SalaryI18nUtil.getI18nLabel(0, "社保福利档案导入模板") + "-" + SalaryI18nUtil.getI18nLabel(542679, "非系统人员");
|
||||
fileName = SalaryI18nUtil.getI18nLabel(user.getLanguage(),542503, "社保福利档案导入模板") + "-" + SalaryI18nUtil.getI18nLabel(user.getLanguage(),542679, "非系统人员");
|
||||
} else if (param.getRunStatuses().size() > 0) {
|
||||
if (param.getRunStatuses().contains(EmployeeStatusEnum.STAY_ADD.getValue()) && param.getRunStatuses().size() == 1) {
|
||||
fileName = SalaryI18nUtil.getI18nLabel(user.getLanguage(),542503, "社保福利档案导入模板") + "-" + EmployeeStatusEnum.STAY_ADD.getDefaultLabel();
|
||||
|
|
|
|||
|
|
@ -687,14 +687,14 @@ public class SalarySendWrapper extends Service implements SalarySendWrapperProxy
|
|||
|
||||
public void confirmSalaryBill(Long salaryInfoId) {
|
||||
if(ObjectUtil.isNull(salaryInfoId)){
|
||||
throw new SalaryRunTimeException("工资单id不能为空!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544769,"工资单id不能为空!"));
|
||||
}
|
||||
getSalaryBillService(user).confirmSalaryBill(salaryInfoId);
|
||||
}
|
||||
|
||||
public void feedBackSalaryBill(Long salaryInfoId) {
|
||||
if(ObjectUtil.isNull(salaryInfoId)){
|
||||
throw new SalaryRunTimeException("工资单id不能为空!");
|
||||
throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(user.getLanguage(),544769, "工资单id不能为空!"));
|
||||
}
|
||||
getSalaryBillService(user).feedBackSalaryBill(salaryInfoId);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue