‘linchangsheng’ 5 달 전
부모
커밋
3e70036d71
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      mall-server-api/src/main/java/com/gree/mall/manager/logic/worker/WorkerWarrantyLogic.java

+ 4 - 0
mall-server-api/src/main/java/com/gree/mall/manager/logic/worker/WorkerWarrantyLogic.java

@@ -245,6 +245,10 @@ public class WorkerWarrantyLogic {
 
             if (workerWarranty.getWaitAmount().doubleValue() < 0)
                 throw new RemoteServiceException("第"+rowIndex+"行"+"缴纳金额超过应缴纳金额");
+
+            if (workerWarranty.getRefundAmount().doubleValue() > workerWarranty.getPayableAmount().doubleValue()) {
+                throw new RemoteServiceException("总退金额大于了缴纳金额");
+            }
             workerWarranties.add(workerWarranty);
 
         }