Commit 45794e518bfa9aac3676da6ed2f317de24b4dbd7

Authored by chenhang4442024
1 parent 5bf511c6

fix:1.业务研发净利润表的利润率改为采用美元计算,保证与订单页面的利润率求值一致。

src/main/java/com/order/erp/service/order/impl/ProjectBaseInfoServiceImpl.java
... ... @@ -978,11 +978,12 @@ public class ProjectBaseInfoServiceImpl extends ServiceImpl<ProjectBaseInfoMappe
978 978 .subtract(BigDecimal.valueOf(businessProfitInfoVO.getProductionDepartmentTotalPrice()))
979 979 .subtract(BigDecimal.valueOf(businessProfitInfoVO.getPacketRmbTotalPrice())));
980 980 }
981   - if (Objects.nonNull(businessProfitInfoVO.getProfit())
982   - && Objects.nonNull(businessProfitInfoVO.getCustomerRmbTotalPrice())) {
  981 + if (Objects.nonNull(businessProfitInfoVO.getCustomerTotalPrice())
  982 + && Objects.nonNull(businessProfitInfoVO.getPacketTotalPrice())) {
983 983 //毛利润率
984   - businessProfitInfoVO.setProfitRate(businessProfitInfoVO.getProfit()
985   - .divide(BigDecimal.valueOf(businessProfitInfoVO.getCustomerRmbTotalPrice()), 4, RoundingMode.HALF_UP));
  984 + businessProfitInfoVO.setProfitRate((BigDecimal.valueOf(businessProfitInfoVO.getCustomerTotalPrice())
  985 + .subtract(BigDecimal.valueOf(businessProfitInfoVO.getProductionDepartmentTotalPrice()).divide(exchangeRate,4, RoundingMode.HALF_UP))
  986 + .subtract(BigDecimal.valueOf(businessProfitInfoVO.getPacketTotalPrice()))).divide(BigDecimal.valueOf(businessProfitInfoVO.getCustomerTotalPrice()), 4, RoundingMode.HALF_UP));
986 987 }
987 988 if (Objects.nonNull(businessProfitInfoVO.getCustomerRmbTotalPrice())
988 989 && Objects.nonNull(businessProfitInfoVO.getRmbTotalExpense())) {
... ...