Compare commits

...

10 Commits

10 changed files with 149 additions and 31 deletions

Binary file not shown.

View File

@ -869,7 +869,7 @@ public class SalaryBillBO {
if ("text".equals(wmClassify)) {
wmTextFieldIds = (List<String>) salaryBillWatermark.getWmSetting().getOrDefault("wmSelectedFieldIds", Collections.emptyList());
List<String> empFields = Arrays.asList(HRM_Name, HRM_Num, HRM_Mobile, HRM_Email, HRM_CurrentOperatorId, HRM_Department);
List<String> empFields = Arrays.asList(HRM_Name, HRM_Num, HRM_Mobile, HRM_Email, HRM_CurrentOperatorId, HRM_Department, HRM_SecondDepartment);
if (wmTextFieldIds.contains(HRM_SecondDepartment)) {
// 需要查分部
salaryBillWatermark.getWmSetting().put("needQuerySubDepart", true);

View File

@ -144,7 +144,7 @@ public class SalarySobItemAggregateBO {
.canEdit(openFormulaForcedEditing || Objects.equals(salaryItemPO.getCanEdit(), 1))
.canDelete(openFormulaForcedEditing || salaryItemPO.getCanDelete() == null || Objects.equals(salaryItemPO.getCanDelete(), 1))
.width(salaryItemPO.getWidth())
.defaultValue(salaryItemPO.getDefaultValue())
.defaultValue(salarySobItemPO.getDefaultValue())
.build());
}
}

View File

@ -11,6 +11,7 @@
e.workcode,
e.certificatenum as idNo,
e.accounttype as accountType,
e.sex as sex,
'false' as extEmp
from hrmresource e
left join hrmdepartment d on e.departmentid = d.id
@ -21,6 +22,7 @@
<select id="getEmployeeByIds" resultType="com.engine.salary.entity.datacollection.DataCollectionEmployee">
select e.id as employeeId,
e.lastname as username,
e.sex as sex,
e.certificatenum as idNo,
e.status as status,
e.workcode as workcode,
@ -41,6 +43,7 @@
<select id="getEmployeeByIdsIncludeAccountType" resultType="com.engine.salary.entity.datacollection.DataCollectionEmployee">
select e.id as employeeId,
e.lastname as username,
e.sex as sex,
e.certificatenum as idNo,
e.status as status,
e.workcode as workcode,
@ -122,6 +125,7 @@
select e.id as employeeId,
e.lastname as username,
e.status as status,
e.sex as sex,
e.certificatenum as idNo,
e.workcode as workcode,
d.departmentname as departmentName,
@ -228,6 +232,7 @@
select e.id as employeeId,
e.lastname as username,
e.status as status,
e.sex as sex,
e.certificatenum as idNo,
e.workcode as workcode,
d.departmentname as departmentName,
@ -282,6 +287,7 @@
e.lastname as username,
e.status as status,
e.workcode as workcode,
e.sex as sex,
e.certificatenum as idNo,
e.companystartdate as companystartdate,
e.mobile as mobile,
@ -303,6 +309,7 @@
e.status as status,
e.workcode as workcode,
e.certificatenum as idNo,
e.sex as sex,
e.companystartdate as companystartdate,
e.mobile as mobile,
e.accounttype as accountType,
@ -323,6 +330,7 @@
e.status as status,
e.workcode as workcode,
e.certificatenum as idNo,
e.sex as sex,
e.companystartdate as companystartdate,
e.mobile as mobile,
e.departmentid as departmentId,
@ -487,6 +495,7 @@
e.lastname as username,
e.status as status,
e.certificatenum as idNo,
e.sex as sex,
e.workcode as workcode,
e.companystartdate as companystartdate,
e.mobile as mobile,
@ -562,6 +571,7 @@
e.lastname as username,
e.status as status,
e.certificatenum as idNo,
e.sex as sex,
e.workcode as workcode,
d.departmentname as departmentName,
d.id as departmentId,

View File

@ -2881,12 +2881,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (otherPaymentBaseString != null) {
updateOtherInfo.setOtherPaymentBaseString(otherPaymentBaseString);
}
if (!welBaseDiffSign) {
otherPaymentBaseString = adaptWelBaseLimit(updateOtherInfo.getOtherSchemeId(), updateOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (otherPaymentBaseString != null) {
updateOtherInfo.setOtherPaymentBaseString(otherPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(updateOtherInfo.getOtherSchemeId(),updateOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "其他福利个人: " + errorMsg;
}
if ( (!welBaseDiffSign) && (!checkWelBaseLimit(updateOtherInfo.getOtherSchemeId(),updateOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "其他福利公司: " + errorMsg;
}
}
//需要拆分个人和公司福利基数时
if (welBaseDiffSign) {
@ -2952,12 +2962,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (otherPaymentBaseString != null) {
insertOtherInfo.setOtherPaymentBaseString(otherPaymentBaseString);
}
if (!welBaseDiffSign) {
otherPaymentBaseString = adaptWelBaseLimit(insertOtherInfo.getOtherSchemeId(), insertOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (otherPaymentBaseString != null) {
insertOtherInfo.setOtherPaymentBaseString(otherPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(insertOtherInfo.getOtherSchemeId(),insertOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "其他福利个人:" + errorMsg;
}
if ( (!welBaseDiffSign) && (!checkWelBaseLimit(insertOtherInfo.getOtherSchemeId(),insertOtherInfo.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "其他福利公司:" + errorMsg;
}
}
//需要拆分个人和公司福利基数时
if (welBaseDiffSign) {
@ -3092,12 +3112,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (fundPaymentBaseString != null) {
updateFundInfo.setFundPaymentBaseString(fundPaymentBaseString);
}
if (!welBaseDiffSign) {
fundPaymentBaseString = adaptWelBaseLimit(updateFundInfo.getFundSchemeId(), updateFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (fundPaymentBaseString != null) {
updateFundInfo.setFundPaymentBaseString(fundPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(updateFundInfo.getFundSchemeId(),updateFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "公积金个人" + errorMsg;
}
if ( (!welBaseDiffSign) && (!checkWelBaseLimit(updateFundInfo.getFundSchemeId(),updateFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "公积金公司" + errorMsg;
}
}
//需要拆分个人和公司福利基数时
@ -3168,12 +3198,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (fundPaymentBaseString != null) {
insertFundInfo.setFundPaymentBaseString(fundPaymentBaseString);
}
if (!welBaseDiffSign) {
fundPaymentBaseString = adaptWelBaseLimit(insertFundInfo.getFundSchemeId(), insertFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (fundPaymentBaseString != null) {
insertFundInfo.setFundPaymentBaseString(fundPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(insertFundInfo.getFundSchemeId(),insertFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "公积金个人:" + errorMsg;
}
if ((!welBaseDiffSign) && (!checkWelBaseLimit(insertFundInfo.getFundSchemeId(),insertFundInfo.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "公积金公司:" + errorMsg;
}
}
//需要拆分个人和公司福利基数时
@ -3315,12 +3355,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (socialPaymentBaseString != null) {
updateSocialInfo.setSocialPaymentBaseString(socialPaymentBaseString);
}
if (!welBaseDiffSign) {
socialPaymentBaseString = adaptWelBaseLimit(updateSocialInfo.getSocialSchemeId(), updateSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (socialPaymentBaseString != null) {
updateSocialInfo.setSocialPaymentBaseString(socialPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(updateSocialInfo.getSocialSchemeId(),updateSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "社保个人:" + errorMsg;
}
if ((!welBaseDiffSign) && (!checkWelBaseLimit(updateSocialInfo.getSocialSchemeId(),updateSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "社保公司:" + errorMsg;
}
}
//需要拆分个人和公司福利基数时
@ -3390,12 +3440,22 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (socialPaymentBaseString != null) {
insertSocialInfo.setSocialPaymentBaseString(socialPaymentBaseString);
}
if (!welBaseDiffSign) {
socialPaymentBaseString = adaptWelBaseLimit(insertSocialInfo.getSocialSchemeId(), insertSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
if (socialPaymentBaseString != null) {
insertSocialInfo.setSocialPaymentBaseString(socialPaymentBaseString);
}
}
} else {
StringBuilder errorMsg = new StringBuilder("");
if (!checkWelBaseLimit(insertSocialInfo.getSocialSchemeId(),insertSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg)) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "社保个人:" + errorMsg;
}
if ((!welBaseDiffSign) && (!checkWelBaseLimit(insertSocialInfo.getSocialSchemeId(),insertSocialInfo.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg))) {
// throw new SalaryRunTimeException(SalaryI18nUtil.getI18nLabel(0,"社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!"));
combineErrorMsg = "社保公司:" + errorMsg;
}
}
//需要拆分个人和公司福利基数时
if (welBaseDiffSign) {

View File

@ -1432,6 +1432,14 @@ public class SISchemeServiceImpl extends Service implements SISchemeService {
Boolean otherCheckBase = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesOtherSchemePO.getOtherSchemeId(), insuranceArchivesOtherSchemePO.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_PERSON.getValue(), errorMsg);
Boolean socialCheckBase2 = true;
Boolean fundCheckBase2 = true;
Boolean otherCheckBase2 = true;
if (!welBaseDiffSign) {
socialCheckBase2 = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesSocialSchemePO.getSocialSchemeId(), insuranceArchivesSocialSchemePO.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg);
fundCheckBase2 = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesFundSchemePO.getFundSchemeId(), insuranceArchivesFundSchemePO.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg);
otherCheckBase2 = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesOtherSchemePO.getOtherSchemeId(), insuranceArchivesOtherSchemePO.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg);
}
Boolean socialCheckComBase = true;
Boolean fundCheckComBase = true;
Boolean otherCheckComBase = true;
@ -1440,17 +1448,17 @@ public class SISchemeServiceImpl extends Service implements SISchemeService {
fundCheckComBase = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesFundSchemePO.getFundSchemeId(), insuranceArchivesFundSchemePO.getFundPaymentComBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg);
otherCheckComBase = getSIArchivesService(user).checkWelBaseLimit(insuranceArchivesOtherSchemePO.getOtherSchemeId(), insuranceArchivesOtherSchemePO.getOtherPaymentComBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue(), errorMsg);
}
if (socialCheckBase && fundCheckBase && otherCheckBase && socialCheckComBase && fundCheckComBase && otherCheckComBase) {
if (socialCheckBase && fundCheckBase && otherCheckBase && socialCheckBase2 && fundCheckBase2 && otherCheckBase2 && socialCheckComBase && fundCheckComBase && otherCheckComBase) {
insuranceArchivesAccountPOS.add(insuranceArchivesAccountPO);
} else {
String checkMessage = "该条数据中";
if (!socialCheckBase || !socialCheckComBase) {
if (!socialCheckBase || !socialCheckBase2 || !socialCheckComBase) {
checkMessage = checkMessage + "社保福利基数、";
}
if (!fundCheckBase || !fundCheckComBase) {
if (!fundCheckBase || !fundCheckBase2 || !fundCheckComBase) {
checkMessage = checkMessage + "公积金福利基数、";
}
if (!otherCheckBase || !otherCheckComBase) {
if (!otherCheckBase || !otherCheckBase2 || !otherCheckComBase) {
checkMessage = checkMessage + "其他福利基数、";
}
checkMessage = checkMessage.substring(0, checkMessage.length() - 1);
@ -1470,6 +1478,14 @@ public class SISchemeServiceImpl extends Service implements SISchemeService {
insuranceArchivesSocialSchemePO.setSocialPaymentBaseString(newSocialPaymentBaseString);
insuranceArchivesFundSchemePO.setFundPaymentBaseString(newFundPaymentBaseString);
insuranceArchivesOtherSchemePO.setOtherPaymentBaseString(newOtherPaymentBaseString);
if (!welBaseDiffSign) {
newSocialPaymentBaseString = getSIArchivesService(user).checkAndBuildWelBaseWithLimit(insuranceArchivesSocialSchemePO.getSocialSchemeId(), insuranceArchivesSocialSchemePO.getSocialPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
newFundPaymentBaseString = getSIArchivesService(user).checkAndBuildWelBaseWithLimit(insuranceArchivesFundSchemePO.getFundSchemeId(), insuranceArchivesFundSchemePO.getFundPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
newOtherPaymentBaseString = getSIArchivesService(user).checkAndBuildWelBaseWithLimit(insuranceArchivesOtherSchemePO.getOtherSchemeId(), insuranceArchivesOtherSchemePO.getOtherPaymentBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());
insuranceArchivesSocialSchemePO.setSocialPaymentBaseString(newSocialPaymentBaseString);
insuranceArchivesFundSchemePO.setFundPaymentBaseString(newFundPaymentBaseString);
insuranceArchivesOtherSchemePO.setOtherPaymentBaseString(newOtherPaymentBaseString);
}
if (welBaseDiffSign) {
String newSocialPaymentComBaseString = getSIArchivesService(user).checkAndBuildWelBaseWithLimit(insuranceArchivesSocialSchemePO.getSocialSchemeId(), insuranceArchivesSocialSchemePO.getSocialPaymentComBaseString(), PaymentScopeEnum.SCOPE_COMPANY.getValue());

View File

@ -405,11 +405,13 @@ public class SalaryAcctExcelServiceImpl extends Service implements SalaryAcctExc
if (openSum != null && StringUtils.isNotBlank(openSum.getConfValue()) && OpenEnum.parseByValue(openSum.getConfValue()) == OpenEnum.OPEN) {
total = true;
Map<String, Object> sumRow = getSalaryAcctResultService(user).sumRow(queryParam);
sumRow.forEach((k, v) -> {
if (NumberUtils.isCreatable(v.toString())) {
sumRow.put(k, new BigDecimal(v.toString()));
}
});
if (sumRow != null) {
sumRow.forEach((k, v) -> {
if (NumberUtils.isCreatable(v.toString())) {
sumRow.put(k, new BigDecimal(v.toString()));
}
});
}
if (sumRow != null) {
sumRow.put("taxAgentName", "总计");
resultMapList.add(sumRow);

View File

@ -1327,20 +1327,23 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
}
Long ygxzItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "ygxz_item_id"));
Long kebItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "kb_item_id"));
Long shijItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "shij_item_id"));
Long bingjItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "bingj_item_id"));
// Long shijItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "shij_item_id"));
// Long bingjItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "bingj_item_id"));
Long qingjItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "qingj_item_id"));
Long sangjItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "sangj_item_id"));
// Long sangjItemId = SalaryEntityUtil.string2Long(baseBean.getPropValue("czgymtSalaryReport", "sangj_item_id"));
List<Long> needShowInQjItemIds = Arrays.stream(baseBean.getPropValue("czgymtSalaryReport", "need_show_item_ids_in_qj").split(","))
.filter(NumberUtils::isCreatable).map(Long::valueOf).collect(Collectors.toList());
List<Long> otherItemIds = Arrays.stream(baseBean.getPropValue("czgymtSalaryReport", "need_sum_item_ids_in_qj").split(","))
.filter(NumberUtils::isCreatable).map(Long::valueOf).collect(Collectors.toList());
List<Long> salaryItemIdList = new ArrayList<>();
salaryItemIdList.add(ygxzItemId);
salaryItemIdList.addAll(reportItemIds);
salaryItemIdList.add(shijItemId == null ? 0L : shijItemId);
salaryItemIdList.add(bingjItemId == null ? 0L : bingjItemId);
salaryItemIdList.add(qingjItemId == null ? 0L : qingjItemId);
salaryItemIdList.add(sangjItemId == null ? 0L : sangjItemId);
salaryItemIdList.addAll(needShowInQjItemIds);
salaryItemIdList.addAll(otherItemIds);
salaryItemIdList.add(kebItemId == null ? 0L : kebItemId);
salaryItemIdList = salaryItemIdList.stream().filter(id -> id != null).distinct().collect(Collectors.toList());
@ -1362,10 +1365,12 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
// 处理请假字段
for (Map<String, Object> map : acctResultMap) {
StringBuilder qjSb = new StringBuilder();
qjSb.append(Utils.null2String(salaryItemMap.get(qingjItemId))).append(Utils.null2String(map.get(Utils.null2String(qingjItemId)))).append(" ")
.append(Utils.null2String(salaryItemMap.get(shijItemId))).append(Utils.null2String(map.get(Utils.null2String(shijItemId)))).append(" ")
.append(Utils.null2String(salaryItemMap.get(bingjItemId))).append(Utils.null2String(map.get(Utils.null2String(bingjItemId)))).append(" ")
.append(Utils.null2String(salaryItemMap.get(sangjItemId))).append(Utils.null2String(map.get(Utils.null2String(sangjItemId)))).append(" ");
for (Long qjItemId : needShowInQjItemIds) {
String value = Utils.null2String(map.get(Utils.null2String(qjItemId)));
if (StringUtils.isNotBlank(value) && NumberUtils.isCreatable(value) && (new BigDecimal(value).compareTo(BigDecimal.ZERO) != 0) ) {
qjSb.append(Utils.null2String(salaryItemMap.get(qjItemId))).append(value).append(" ");
}
}
BigDecimal sumVal = new BigDecimal("0");
for (Long id : otherItemIds) {
@ -1374,7 +1379,9 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
sumVal = sumVal.add(new BigDecimal(value));
}
}
qjSb.append("其他").append(sumVal.toString());
if (sumVal.compareTo(BigDecimal.ZERO) != 0) {
qjSb.append("其他").append(sumVal.toString());
}
map.put(Utils.null2String(qingjItemId), qjSb.toString());
String kebId = Utils.null2String(map.get(kebItemId.toString()));
String kebName = departmentNameMap.getOrDefault(SalaryEntityUtil.string2Long(kebId), "");
@ -1382,14 +1389,15 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
}
if (CollectionUtils.isNotEmpty(param.getKbIds())) {
acctResultMap = acctResultMap.stream().filter(map -> param.getKbIds().contains(Utils.null2String(map.get(kebItemId.toString())))).collect(Collectors.toList());
List<String> kbList = param.getKbIds().stream().filter(kbid -> kbid != null).map(kbid -> String.valueOf(kbid)).collect(Collectors.toList());
acctResultMap = acctResultMap.stream().filter(map -> kbList.contains(Utils.null2String(map.get(kebItemId.toString())))).collect(Collectors.toList());
}
if (CollectionUtils.isNotEmpty(param.getYgxzs())) {
List<String> ygxzList = new ArrayList<>();
rs.execute("select id,name from hrmusekind and id in (" + StringUtils.join(param.getYgxzs(), ",") + ")");
rs.execute("select id,name from hrmusekind where id in (" + StringUtils.join(param.getYgxzs(), ",") + ")");
while (rs.next()) {
ygxzList.add(rs.getString("name"));
ygxzList.add(rs.getString("id"));
}
acctResultMap = acctResultMap.stream().filter(map -> ygxzList.contains(Utils.null2String(map.get(ygxzItemId.toString())))).collect(Collectors.toList());
}
@ -1525,16 +1533,17 @@ public class SalaryAcctResultServiceImpl extends Service implements SalaryAcctRe
List<SalaryItemPO> salaryItems = salaryItemPOList.stream().filter(itemPO -> finalSalaryItemIdList.contains(itemPO.getId())).collect(Collectors.toList());
List<Map<String, Object>> acctResultMap = SalaryAcctResultBO.buildData4Gymt(salaryItems, salarySobEmpFields, employeeList, salaryAcctEmployeePOList, acctResultList, param.getSalaryMonth() ,false);
if (CollectionUtils.isNotEmpty(param.getKbIds())) {
List<DeptInfo> deptInfoList = getSalaryEmployeeService(user).getDeptInfoList(param.getKbIds());
List<String> depNames = deptInfoList.stream().map(DeptInfo::getName).collect(Collectors.toList());
acctResultMap = acctResultMap.stream().filter(map -> depNames.contains(Utils.null2String(map.get(kebItemId.toString())))).collect(Collectors.toList());
List<String> kbList = param.getKbIds().stream().filter(kbid -> kbid != null).map(kbid -> String.valueOf(kbid)).collect(Collectors.toList());
// List<DeptInfo> deptInfoList = getSalaryEmployeeService(user).getDeptInfoList(param.getKbIds());
// List<String> depNames = deptInfoList.stream().map(DeptInfo::getName).collect(Collectors.toList());
acctResultMap = acctResultMap.stream().filter(map -> kbList.contains(Utils.null2String(map.get(kebItemId.toString())))).collect(Collectors.toList());
}
if (CollectionUtils.isNotEmpty(param.getYgxzs())) {
List<String> ygxzList = new ArrayList<>();
rs.execute("select id,name from hrmusekind and id in (" + StringUtils.join(param.getYgxzs(), ",") + ")");
rs.execute("select id,name from hrmusekind where id in (" + StringUtils.join(param.getYgxzs(), ",") + ")");
while (rs.next()) {
ygxzList.add(rs.getString("name"));
ygxzList.add(rs.getString("id"));
}
acctResultMap = acctResultMap.stream().filter(map -> ygxzList.contains(Utils.null2String(map.get(ygxzItemId.toString())))).collect(Collectors.toList());
}

View File

@ -239,6 +239,14 @@ public class AttendQuoteController {
return new ResponseResult<Long, List<Map<String, Object>>>(user).run(getAttendQuoteWrapper(user)::selectSalarySobList);
}
@GET
@Path("/allSalarySobList")
@Produces(MediaType.APPLICATION_JSON)
public String allSalarySobList(@Context HttpServletRequest request, @Context HttpServletResponse response) {
User user = HrmUserVarify.getUser(request, response);
return new ResponseResult<Long, List<Map<String, Object>>>(user).run(getAttendQuoteWrapper(user)::allSalarySobList);
}
/**
* 删除考勤数据

View File

@ -147,6 +147,19 @@ public class AttendQuoteWrapper extends Service {
}).collect(Collectors.toList());
}
public List<Map<String, Object>> allSalarySobList() {
// 查询所有启用的薪资账套
List<SalarySobPO> salarySobs = getSalarySobService(user).listAll();
salarySobs = salarySobs.stream().filter(sob -> sob.getDisable().equals(NumberUtils.INTEGER_ZERO)).collect(Collectors.toList());;
return salarySobs.stream().map(m -> {
Map<String, Object> map = new HashMap<>(2);
map.put("id", String.valueOf(m.getId()));
map.put("content", m.getName());
return map;
}).collect(Collectors.toList());
}
/**
* 删除考勤引用
*