|
|
@ -1103,8 +1103,27 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
billNode.setNodeCode("6"); |
|
|
|
asBusrepairBillNodeService.insert(billNode); |
|
|
|
} |
|
|
|
if (null != settelApply.getHourAmount()) { |
|
|
|
if (settelApply.getHourAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
|
|
|
|
BigDecimal settleHourAmount = BigDecimal.ZERO; |
|
|
|
BigDecimal settleGoodsAmount = BigDecimal.ZERO; |
|
|
|
List<AsBillSettelApplySitem> sitemList = asBillSettelApplySitemService.fetchByBillSid(sid); |
|
|
|
if (!sitemList.isEmpty()) { |
|
|
|
for (AsBillSettelApplySitem sitem : sitemList) { |
|
|
|
if (null != sitem.getSitemSettleAmount()) { |
|
|
|
settleHourAmount = sitem.getSitemSettleAmount().add(settleHourAmount); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
List<AsBillSettelApplyDetail> goodsList = asBillSettelApplyDetailService.fetchByBillSid(sid); |
|
|
|
if (!goodsList.isEmpty()) { |
|
|
|
for (AsBillSettelApplyDetail g : goodsList) { |
|
|
|
if (null != g.getGoodsSettleAmount()) { |
|
|
|
settleGoodsAmount = g.getGoodsSettleAmount().add(settleGoodsAmount); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (settleHourAmount.compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateBySid(asBusrepairBill.getCreateBySid()); |
|
|
@ -1125,15 +1144,15 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgSid(asBusrepairBill.getUseOrgSid()); |
|
|
|
finUncollectedReceivablesDetailedDto.setOrgSidPath(asBusrepairBill.getOrgSidPath()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReceivablesName("工时费"); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney((settelApply.getHourAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney((settelApply.getHourAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney(settleHourAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney(settleHourAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgName(asBusrepairBill.getUseOrgName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setKxState("01"); |
|
|
|
finUncollectedReceivablesDetailedFeign.saveOrUpdate(finUncollectedReceivablesDetailedDto); |
|
|
|
} |
|
|
|
} |
|
|
|
if (null != settelApply.getGoodsAmount()) { |
|
|
|
if (settelApply.getGoodsAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
|
|
|
|
|
|
|
|
if (settleGoodsAmount.compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateBySid(asBusrepairBill.getCreateBySid()); |
|
|
@ -1154,13 +1173,13 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgSid(asBusrepairBill.getUseOrgSid()); |
|
|
|
finUncollectedReceivablesDetailedDto.setOrgSidPath(asBusrepairBill.getOrgSidPath()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReceivablesName("材料费"); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney((settelApply.getGoodsAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney((settelApply.getGoodsAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney(settleGoodsAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney(settleGoodsAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgName(asBusrepairBill.getUseOrgName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setKxState("01"); |
|
|
|
finUncollectedReceivablesDetailedFeign.saveOrUpdate(finUncollectedReceivablesDetailedDto); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (settelApply.getAddAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
@ -1467,8 +1486,26 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
billNode.setNodeCode("6"); |
|
|
|
asBusrepairBillNodeService.insert(billNode); |
|
|
|
} |
|
|
|
if (null != settelApply.getHourAmount()) { |
|
|
|
if (settelApply.getHourAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
BigDecimal settleHourAmount = BigDecimal.ZERO; |
|
|
|
BigDecimal settleGoodsAmount = BigDecimal.ZERO; |
|
|
|
List<AsBillSettelApplySitem> sitemList = asBillSettelApplySitemService.fetchByBillSid(businessSid); |
|
|
|
if (!sitemList.isEmpty()) { |
|
|
|
for (AsBillSettelApplySitem sitem : sitemList) { |
|
|
|
if (null != sitem.getSitemSettleAmount()) { |
|
|
|
settleHourAmount = sitem.getSitemSettleAmount().add(settleHourAmount); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
List<AsBillSettelApplyDetail> goodsList = asBillSettelApplyDetailService.fetchByBillSid(businessSid); |
|
|
|
if (!goodsList.isEmpty()) { |
|
|
|
for (AsBillSettelApplyDetail g : goodsList) { |
|
|
|
if (null != g.getGoodsSettleAmount()) { |
|
|
|
settleGoodsAmount = g.getGoodsSettleAmount().add(settleGoodsAmount); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (settleHourAmount.compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateBySid(asBusrepairBill.getCreateBySid()); |
|
|
@ -1489,15 +1526,15 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgSid(asBusrepairBill.getUseOrgSid()); |
|
|
|
finUncollectedReceivablesDetailedDto.setOrgSidPath(asBusrepairBill.getOrgSidPath()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReceivablesName("工时费"); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney((settelApply.getHourAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney((settelApply.getHourAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney(settleHourAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney(settleHourAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgName(asBusrepairBill.getUseOrgName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setKxState("01"); |
|
|
|
finUncollectedReceivablesDetailedFeign.saveOrUpdate(finUncollectedReceivablesDetailedDto); |
|
|
|
} |
|
|
|
} |
|
|
|
if (null != settelApply.getGoodsAmount()) { |
|
|
|
if (settelApply.getGoodsAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
|
|
|
|
|
|
|
|
if (settleGoodsAmount.compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateBySid(asBusrepairBill.getCreateBySid()); |
|
|
@ -1518,13 +1555,13 @@ public class AsBillSettelApplyService extends MybatisBaseService<AsBillSettelApp |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgSid(asBusrepairBill.getUseOrgSid()); |
|
|
|
finUncollectedReceivablesDetailedDto.setOrgSidPath(asBusrepairBill.getOrgSidPath()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReceivablesName("材料费"); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney((settelApply.getGoodsAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney((settelApply.getGoodsAmount()).toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setCurrentReceivableMoney(settleGoodsAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setReveivableMoney(settleGoodsAmount.toString()); |
|
|
|
finUncollectedReceivablesDetailedDto.setUseOrgName(asBusrepairBill.getUseOrgName()); |
|
|
|
finUncollectedReceivablesDetailedDto.setKxState("01"); |
|
|
|
finUncollectedReceivablesDetailedFeign.saveOrUpdate(finUncollectedReceivablesDetailedDto); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (settelApply.getAddAmount().compareTo(BigDecimal.ZERO) > 0) { |
|
|
|
FinUncollectedReceivablesDetailedDto finUncollectedReceivablesDetailedDto = new FinUncollectedReceivablesDetailedDto(); |
|
|
|
finUncollectedReceivablesDetailedDto.setCreateByName(asBusrepairBill.getCreateByName()); |
|
|
|