|
@@ -973,7 +973,10 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
|
|
|
|
|
|
v.setGross(v.getIncomeAmount().subtract(v.getExpenditureAmount()));
|
|
|
|
|
|
- v.setGrossRate(v.getGross().divide(v.getIncomeAmount(), RoundingMode.CEILING).multiply(new BigDecimal("100")));
|
|
|
+ v.setGrossRate(BigDecimal.ZERO);
|
|
|
+ if (v.getIncomeAmount().compareTo(BigDecimal.ZERO) != 0) {
|
|
|
+ v.setGrossRate(v.getGross().divide(v.getIncomeAmount(), RoundingMode.CEILING).multiply(new BigDecimal("100")));
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|