认领处理单-新增字段-提交校验
This commit is contained in:
		
							parent
							
								
									84380ba10a
								
							
						
					
					
						commit
						8d106789c5
					
				|  | @ -0,0 +1,190 @@ | |||
| package shjh.jhzj7.fi.fi.plugin.form; | ||||
| 
 | ||||
| import kd.bos.dataentity.entity.DynamicObject; | ||||
| import kd.bos.dataentity.entity.DynamicObjectCollection; | ||||
| import kd.bos.dataentity.utils.StringUtils; | ||||
| import kd.bos.entity.datamodel.events.PropertyChangedArgs; | ||||
| import kd.bos.form.field.ComboEdit; | ||||
| import kd.bos.form.plugin.AbstractFormPlugin; | ||||
| import kd.sdk.plugin.Plugin; | ||||
| import shjh.jhzj7.fi.fi.plugin.form.info.ClaimFieldsInfo; | ||||
| 
 | ||||
| import java.util.EventObject; | ||||
| 
 | ||||
| /** | ||||
|  * 动态表单插件-【认领处理单】 | ||||
|  * @author LiGuiQiang | ||||
|  */ | ||||
| public class ClaimBillFormPlugin extends AbstractFormPlugin implements Plugin { | ||||
| 
 | ||||
| 
 | ||||
|     @Override | ||||
|     public void afterBindData(EventObject e) { | ||||
|         super.afterBindData(e); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.COST_CENTER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.REFUND_METHODS); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.CUSTOMER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.REPAYMENT_METHOD); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.CUSTOMER_SPLIT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.ENTRY_CUSTOMER); | ||||
|         hideEntryFields(); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public void propertyChanged(PropertyChangedArgs e) { | ||||
|         super.propertyChanged(e); | ||||
|         String fieldKey = e.getProperty().getName(); | ||||
|         if (StringUtils.equals(fieldKey, ClaimFieldsInfo.REC_PAY_TYPE)) { | ||||
|             handleReceivingTypeChange(); | ||||
|         } else if (StringUtils.equals(fieldKey, ClaimFieldsInfo.REFUND_METHODS)) { | ||||
|             handleRefundMethodsChange(); | ||||
|         } else if (StringUtils.equals(fieldKey, ClaimFieldsInfo.CUSTOMER_SPLIT)) { | ||||
|             handleCustomerSplit(); | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     private void handleReceivingTypeChange() { | ||||
|         DynamicObject receivingType = (DynamicObject) this.getModel().getValue(ClaimFieldsInfo.RECEIVING_TYPE); | ||||
|         if (null!=receivingType){ | ||||
|             String number = receivingType.getString("number"); | ||||
|             if (null!=number){ | ||||
|                 clearFields(); | ||||
|                 switch (number) { | ||||
|                     case "100": | ||||
|                         showTopFieldsBySale(); | ||||
|                         break; | ||||
|                     case "103": | ||||
|                         showCostCenter(); | ||||
|                         showRefundMethods(); | ||||
|                         showEntryFieldsByRefund(); | ||||
|                         break; | ||||
|                     case "109": | ||||
|                         showCostCenter(); | ||||
|                         showRepaymentMethod(); | ||||
|                         showEntryFieldsByEmployee(); | ||||
|                         break; | ||||
|                     default: | ||||
|                         break; | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
| 
 | ||||
|     } | ||||
| 
 | ||||
|     private void handleRefundMethodsChange() { | ||||
|         String value = (String) this.getModel().getValue(ClaimFieldsInfo.REFUND_METHODS); | ||||
|         if (ClaimFieldsInfo.METHOD_C.equals(value) || ClaimFieldsInfo.METHOD_D.equals(value)) { | ||||
|             this.getView().setVisible(true, ClaimFieldsInfo.CUSTOMER); | ||||
|         } else { | ||||
|             this.getView().setVisible(false, ClaimFieldsInfo.CUSTOMER); | ||||
|             this.getModel().setValue(ClaimFieldsInfo.CUSTOMER, null); | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     private void handleCustomerSplit(){ | ||||
|         Boolean split = (Boolean) this.getModel().getValue(ClaimFieldsInfo.CUSTOMER_SPLIT); | ||||
|         DynamicObjectCollection entry = this.getModel().getEntryEntity(ClaimFieldsInfo.ENTRY); | ||||
|         if (split){ | ||||
|             this.getView().setVisible(true,ClaimFieldsInfo.ENTRY_CUSTOMER); | ||||
|         }else { | ||||
|             this.getView().setVisible(false,ClaimFieldsInfo.ENTRY_CUSTOMER); | ||||
|             for (int i = 0; i < entry.size(); i++) { | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.ENTRY_CUSTOMER,null,i); | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     private void showTopFieldsBySale(){ | ||||
|         this.getView().setVisible(true, ClaimFieldsInfo.CUSTOMER_SPLIT); | ||||
|     } | ||||
| 
 | ||||
| 
 | ||||
|     private void showCostCenter() { | ||||
|         this.getView().setVisible(true, ClaimFieldsInfo.COST_CENTER); | ||||
|     } | ||||
| 
 | ||||
|     private void showRefundMethods() { | ||||
|         this.getView().setVisible(true, ClaimFieldsInfo.REFUND_METHODS); | ||||
|         ComboEdit edit = this.getView().getControl(ClaimFieldsInfo.REFUND_METHODS); | ||||
|         edit.setMustInput(true); | ||||
|     } | ||||
| 
 | ||||
|     private void showEntryFieldsByRefund() { | ||||
|         this.getView().setVisible(true, ClaimFieldsInfo.PREPAYMENT_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.PURCHASE_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.PURCHASE_LINE_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.BILL_SUBJECT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.PREPAYMENT_DATE); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.PAYMENT_AMOUNT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.DOCUMENT_AMOUNT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.REFUNDED_AMOUNT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.VERIFICATION_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.FISCAL_YEAR); | ||||
|     } | ||||
|     private void showRepaymentMethod() { | ||||
|         this.getView().setVisible(true, ClaimFieldsInfo.REPAYMENT_METHOD); | ||||
|     } | ||||
| 
 | ||||
|     private void showEntryFieldsByEmployee(){ | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.LOAN_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.LOAN_AMOUNT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.LOAN_BALANCE); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.REPAYMENT_AMOUNT); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.VERIFICATION_NUMBER); | ||||
|         this.getView().setVisible(true,ClaimFieldsInfo.FISCAL_YEAR); | ||||
|     } | ||||
| 
 | ||||
|     private void clearFields() { | ||||
|         this.getModel().setValue(ClaimFieldsInfo.COST_CENTER, null); | ||||
|         this.getView().setVisible(false, ClaimFieldsInfo.COST_CENTER); | ||||
|         ComboEdit edit = this.getView().getControl(ClaimFieldsInfo.REFUND_METHODS); | ||||
|         edit.setMustInput(false); | ||||
|         this.getModel().setValue(ClaimFieldsInfo.REFUND_METHODS, null); | ||||
|         this.getView().setVisible(false, ClaimFieldsInfo.REFUND_METHODS); | ||||
|         this.getModel().setValue(ClaimFieldsInfo.CUSTOMER, null); | ||||
|         this.getView().setVisible(false, ClaimFieldsInfo.CUSTOMER); | ||||
|         this.getModel().setValue(ClaimFieldsInfo.REPAYMENT_METHOD, null); | ||||
|         this.getView().setVisible(false, ClaimFieldsInfo.REPAYMENT_METHOD); | ||||
|         this.getModel().setValue(ClaimFieldsInfo.CUSTOMER_SPLIT, null); | ||||
|         this.getView().setVisible(false, ClaimFieldsInfo.CUSTOMER_SPLIT); | ||||
|         DynamicObjectCollection entry = this.getModel().getEntryEntity(ClaimFieldsInfo.ENTRY); | ||||
|         if (null!=entry){ | ||||
|             hideEntryFields(); | ||||
|             for (int i = 0; i < entry.size(); i++) { | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.ENTRY_CUSTOMER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.PREPAYMENT_NUMBER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.PURCHASE_NUMBER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.PURCHASE_LINE_NUMBER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.BILL_SUBJECT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.PREPAYMENT_DATE, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.PAYMENT_AMOUNT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.DOCUMENT_AMOUNT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.REFUNDED_AMOUNT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.LOAN_NUMBER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.LOAN_AMOUNT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.LOAN_BALANCE, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.REPAYMENT_AMOUNT, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.VERIFICATION_NUMBER, null,i); | ||||
|                 this.getModel().setValue(ClaimFieldsInfo.FISCAL_YEAR, null,i); | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     private void hideEntryFields(){ | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.PREPAYMENT_NUMBER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.PURCHASE_NUMBER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.PURCHASE_LINE_NUMBER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.BILL_SUBJECT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.PREPAYMENT_DATE); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.PAYMENT_AMOUNT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.DOCUMENT_AMOUNT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.REFUNDED_AMOUNT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.LOAN_NUMBER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.LOAN_AMOUNT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.LOAN_BALANCE); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.REPAYMENT_AMOUNT); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.VERIFICATION_NUMBER); | ||||
|         this.getView().setVisible(false,ClaimFieldsInfo.FISCAL_YEAR); | ||||
|     } | ||||
| 
 | ||||
| } | ||||
|  | @ -0,0 +1,68 @@ | |||
| package shjh.jhzj7.fi.fi.plugin.form.info; | ||||
| 
 | ||||
| /** | ||||
|  * @author LiGuiQiang | ||||
|  */ | ||||
| public class ClaimFieldsInfo { | ||||
| 
 | ||||
|     /** | ||||
|      * 单据标识 | ||||
|      */ | ||||
|     public static final String RECEIVING_TYPE = "e_receivingtype"; | ||||
|     /** | ||||
|      * Top:收款类型 | ||||
|      */ | ||||
|     public static final String REC_PAY_TYPE = "recpaytype"; | ||||
|     /** | ||||
|      * Top:成本中心 | ||||
|      */ | ||||
|     public static final String COST_CENTER = "shjh_costcenter"; | ||||
|     /** | ||||
|      * Top:退款方式 | ||||
|      */ | ||||
|     public static final String REFUND_METHODS = "shjh_refundmethods"; | ||||
|     /** | ||||
|      * Top:客户名称 | ||||
|      */ | ||||
|     public static final String CUSTOMER = "shjh_customer"; | ||||
|     /** | ||||
|      * Top:还款方式 | ||||
|      */ | ||||
|     public static final String REPAYMENT_METHOD = "shjh_repaymentmethod"; | ||||
|     /** | ||||
|      * Top:客户拆分 | ||||
|      */ | ||||
|     public static final String CUSTOMER_SPLIT = "shjh_customersplit"; | ||||
|     /** | ||||
|      * Top:收款金额 | ||||
|      */ | ||||
|     public static final String RE_AMOUNT="reamount"; | ||||
|     /** | ||||
|      * 分录标识 | ||||
|      */ | ||||
|     public static final String ENTRY = "entryentity"; | ||||
| 
 | ||||
|     public static final String ENTRY_CUSTOMER = "shjh_entrycustomer"; | ||||
| 
 | ||||
|     public static final String PREPAYMENT_NUMBER = "shjh_prepaymentnum"; | ||||
|     public static final String PURCHASE_NUMBER = "shjh_purchasenum"; | ||||
|     public static final String PURCHASE_LINE_NUMBER = "shjh_purchaselinenum"; | ||||
|     public static final String BILL_SUBJECT = "shjh_billsubject"; | ||||
|     public static final String PREPAYMENT_DATE = "shjh_prepaymentdate"; | ||||
|     public static final String PAYMENT_AMOUNT = "shjh_paymentamount"; | ||||
|     public static final String DOCUMENT_AMOUNT = "shjh_documentamount"; | ||||
|     public static final String REFUNDED_AMOUNT = "shjh_refundedamount"; | ||||
|     public static final String LOAN_NUMBER = "shjh_loannum"; | ||||
|     public static final String LOAN_AMOUNT = "shjh_loanamount"; | ||||
|     public static final String LOAN_BALANCE = "shjh_loanbalance"; | ||||
|     public static final String REPAYMENT_AMOUNT = "shjh_repaymentamount"; | ||||
|     public static final String VERIFICATION_NUMBER = "shjh_verificationnum"; | ||||
|     public static final String FISCAL_YEAR = "shjh_fiscalyear"; | ||||
|     public static final String METHOD_C = "C"; | ||||
|     public static final String METHOD_D = "D"; | ||||
| 
 | ||||
|     /** | ||||
|      * Entry:应收金额 | ||||
|      */ | ||||
|     public static final String RECEIVABLE_AMOUNT = "e_receivableamt"; | ||||
| } | ||||
|  | @ -0,0 +1,64 @@ | |||
| package shjh.jhzj7.fi.fi.plugin.task; | ||||
| 
 | ||||
| import kd.bos.context.RequestContext; | ||||
| import kd.bos.dataentity.OperateOption; | ||||
| import kd.bos.dataentity.entity.DynamicObject; | ||||
| import kd.bos.dataentity.utils.StringUtils; | ||||
| import kd.bos.entity.operate.result.OperationResult; | ||||
| import kd.bos.exception.KDException; | ||||
| import kd.bos.orm.query.QCP; | ||||
| import kd.bos.orm.query.QFilter; | ||||
| import kd.bos.schedule.api.MessageHandler; | ||||
| import kd.bos.schedule.executor.AbstractTask; | ||||
| import kd.bos.servicehelper.BusinessDataServiceHelper; | ||||
| import kd.bos.servicehelper.operation.OperationServiceHelper; | ||||
| import kd.sdk.plugin.Plugin; | ||||
| 
 | ||||
| import java.math.BigDecimal; | ||||
| import java.util.ArrayList; | ||||
| import java.util.List; | ||||
| import java.util.Map; | ||||
| 
 | ||||
| /** | ||||
|  * 收款入账中心-按规则自动生成收款单 | ||||
|  * | ||||
|  * @author LiGuiQiang | ||||
|  */ | ||||
| public class ReceiptGenerationTask extends AbstractTask implements Plugin { | ||||
| 
 | ||||
|     @Override | ||||
|     public MessageHandler getMessageHandle() { | ||||
|         return super.getMessageHandle(); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public void execute(RequestContext requestContext, Map<String, Object> map) throws KDException { | ||||
|         //查询【收款入账中心】 | ||||
|         //【待确认】receredtype | ||||
|         //【收款金额不等于0】creditamount | ||||
|         //【收款认领通知为空】claimnoticebillno | ||||
|         QFilter qFilter = new QFilter("receredtype", QCP.equals, "0"); | ||||
|         qFilter.and("creditamount", QCP.not_equals, BigDecimal.ZERO); | ||||
|         qFilter.and("claimnoticebillno", QCP.equals, ""); | ||||
|         qFilter.and("billno", QCP.equals, "20250211-0000000094"); | ||||
|         DynamicObject[] collection = BusinessDataServiceHelper.load("bei_intelrec", "id", qFilter.toArray()); | ||||
|         if (collection.length != 0) { | ||||
|             Object[] idArray = new Object[collection.length]; | ||||
|             for (int i = 0; i < collection.length; i++) { | ||||
|                 DynamicObject dynamicObject = collection[i]; | ||||
|                 Object id = dynamicObject.get("id"); | ||||
|                 idArray[i] = id; | ||||
|             } | ||||
|             for (Object o : idArray) { | ||||
|                 DynamicObject dynamicObject = BusinessDataServiceHelper.loadSingle(o, "bei_intelrec"); | ||||
| 
 | ||||
|             } | ||||
|         } | ||||
| 
 | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public boolean isSupportReSchedule() { | ||||
|         return super.isSupportReSchedule(); | ||||
|     } | ||||
| } | ||||
|  | @ -0,0 +1,100 @@ | |||
| package shjh.jhzj7.fi.fi.plugin.validators; | ||||
| 
 | ||||
| import kd.bos.dataentity.entity.DynamicObject; | ||||
| import kd.bos.dataentity.entity.DynamicObjectCollection; | ||||
| import kd.bos.entity.ExtendedDataEntity; | ||||
| import kd.bos.entity.validate.AbstractValidator; | ||||
| import shjh.jhzj7.fi.fi.plugin.form.info.ClaimFieldsInfo; | ||||
| 
 | ||||
| import java.math.BigDecimal; | ||||
| import java.math.RoundingMode; | ||||
| 
 | ||||
| /** | ||||
|  * 认领处理单-提交操作校验 | ||||
|  * | ||||
|  * @author LiGuiQiang | ||||
|  */ | ||||
| public class ClaimSubmitValidator extends AbstractValidator { | ||||
|     @Override | ||||
|     public void validate() { | ||||
|         ExtendedDataEntity[] dataEntities = this.getDataEntities(); | ||||
|         if (dataEntities != null && dataEntities.length >= 1) { | ||||
|             for (ExtendedDataEntity dataEntity : dataEntities) { | ||||
|                 if (dataEntity != null) { | ||||
|                     DynamicObject bill = dataEntity.getDataEntity(); | ||||
|                     DynamicObjectCollection entry = bill.getDynamicObjectCollection(ClaimFieldsInfo.ENTRY); | ||||
|                     if (entry != null && !entry.isEmpty()) { | ||||
|                         BigDecimal reAmount = bill.getBigDecimal(ClaimFieldsInfo.RE_AMOUNT); | ||||
|                         BigDecimal receivableAll = BigDecimal.ZERO; | ||||
|                         BigDecimal refundedAll = BigDecimal.ZERO; | ||||
|                         BigDecimal repaymentAll = BigDecimal.ZERO; | ||||
| 
 | ||||
|                         // 计算所有金额的合计 | ||||
|                         for (DynamicObject dynamicObject : entry) { | ||||
|                             receivableAll = receivableAll.add(dynamicObject.getBigDecimal(ClaimFieldsInfo.RECEIVABLE_AMOUNT)); | ||||
|                             refundedAll = refundedAll.add(dynamicObject.getBigDecimal(ClaimFieldsInfo.REFUNDED_AMOUNT)); | ||||
|                             repaymentAll = repaymentAll.add(dynamicObject.getBigDecimal(ClaimFieldsInfo.REPAYMENT_AMOUNT)); | ||||
|                         } | ||||
| 
 | ||||
|                         DynamicObject receivingType = bill.getDynamicObject(ClaimFieldsInfo.REC_PAY_TYPE); | ||||
|                         if (null != receivingType) { | ||||
|                             String type = receivingType.getString("number"); | ||||
|                             if (null != type) { | ||||
|                                 if (isAmountInvalid(type, reAmount, receivableAll, refundedAll, repaymentAll)) { | ||||
|                                     String errorMessage = getErrorMessage(type, reAmount, receivableAll, refundedAll, repaymentAll); | ||||
|                                     this.addErrorMessage(dataEntity, errorMessage); | ||||
|                                 } | ||||
|                             } | ||||
|                         } | ||||
|                     } | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * 判断金额是否有效 | ||||
|      * | ||||
|      * @param type          收款类型 | ||||
|      * @param reAmount      收款金额 | ||||
|      * @param receivableAll 应收金额合计 | ||||
|      * @param refundedAll   退还金额合计 | ||||
|      * @param repaymentAll  还款金额合计 | ||||
|      * @return 布尔值 | ||||
|      */ | ||||
|     private boolean isAmountInvalid(String type, BigDecimal reAmount, BigDecimal receivableAll, BigDecimal refundedAll, BigDecimal repaymentAll) { | ||||
|         switch (type) { | ||||
|             case "100": | ||||
|                 return reAmount.compareTo(receivableAll) <= 0; | ||||
|             case "103": | ||||
|                 return reAmount.compareTo(refundedAll) <= 0; | ||||
|             case "109": | ||||
|                 return reAmount.compareTo(repaymentAll) <= 0; | ||||
|             default: | ||||
|                 return false; | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * 获取错误信息 | ||||
|      * | ||||
|      * @param type          收款类型 | ||||
|      * @param reAmount      收款金额 | ||||
|      * @param receivableAll 应收金额合计 | ||||
|      * @param refundedAll   退还金额合计 | ||||
|      * @param repaymentAll  还款金额合计 | ||||
|      * @return 错误信息 | ||||
|      */ | ||||
|     private String getErrorMessage(String type, BigDecimal reAmount, BigDecimal receivableAll, BigDecimal refundedAll, BigDecimal repaymentAll) { | ||||
|         switch (type) { | ||||
|             case "100": | ||||
|                 return String.format("提交失败:分录应收金额合计(%.2f)应小于等于收款金额(%.2f)", receivableAll.setScale(2, RoundingMode.DOWN).doubleValue(), reAmount.setScale(2, RoundingMode.DOWN).doubleValue()); | ||||
|             case "103": | ||||
|                 return String.format("提交失败:分录本次退还本位币金额合计(%.2f)应小于等于收款金额(%.2f)", refundedAll.setScale(2, RoundingMode.DOWN).doubleValue(), reAmount.setScale(2, RoundingMode.DOWN).doubleValue()); | ||||
|             case "109": | ||||
|                 return String.format("提交失败:分录本次还款金额合计(%.2f)应小于等于收款金额(%.2f)", repaymentAll.setScale(2, RoundingMode.DOWN).doubleValue(), reAmount.setScale(2, RoundingMode.DOWN).doubleValue()); | ||||
|             default: | ||||
|                 return ""; | ||||
|         } | ||||
|     } | ||||
| } | ||||
		Loading…
	
		Reference in New Issue