update:批量添加工作组成员后,单独计算每个工作组的金额,取本年应收款A

This commit is contained in:
sunzheng
2024-07-10 14:08:53 +08:00
parent 03e2f3e56b
commit 405af59486
@@ -461,6 +461,13 @@ public class PayWorkingGroupSubItemController extends JeroController<PayWorkingG
String[] workingGroupIdsArr = workingGroupIds.split(",");
List<String> errInfoList = new ArrayList<>();
for (String workingGroupId : workingGroupIdsArr) {
PayWorkingGroup payWorkingGroup = payWorkingGroupService.getById(workingGroupId);
BigDecimal yearChargeA = payWorkingGroup.getYearChargeA();
if (Objects.isNull(yearChargeA)) {
payWorkingGroupSubItem.setReceivableAmount(BigDecimal.ZERO);
}else {
payWorkingGroupSubItem.setReceivableAmount(yearChargeA);
}
payWorkingGroupSubItem.setId(null);
List<PayWorkingGroupSubItemContacts> payWorkingGroupSubItemContactsList =
payWorkingGroupSubItem.getPayWorkingGroupSubItemContactsList();