From 9e6b75229349c63053d6f7351f079b95b3ed11bd Mon Sep 17 00:00:00 2001 From: tangfutang Date: Tue, 12 Jan 2021 16:10:34 +0800 Subject: [PATCH] =?UTF-8?q?=E7=81=B5=E6=B4=BB=E4=BA=A7=E5=93=81=E5=9C=A8?= =?UTF-8?q?=E6=B5=8B=E8=AF=95=E4=B8=80=E4=BA=9B=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp | 4 ++-- .../WEB-INF/etc/app/component/componenttype-config.xml | 2 +- .../tenwa/reckon/executor/CreateTransactionExecutor.java | 8 +++++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp b/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp index a26082d5f..39612b1b5 100644 --- a/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp +++ b/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp @@ -1086,8 +1086,8 @@ function saveRecord(sPostEvents){ } //校验年利率是否合法 var isFixedRate = "<%=isFixedRate%>"; - if("N" == isFixedRate){ - var yearRae = getItemValue(0,0,"YEAR_RATE"); + var yearRae = getItemValue(0,0,"YEAR_RATE"); + if("N" == isFixedRate && yearRae > 0 ){ var rateTermMin = "<%=rateTermMin%>"; var rateTermMax = "<%=rateTermMax%>"; console.log(rateTermMin +"===" +yearRae+"====" +rateTermMax); diff --git a/WebContent/WEB-INF/etc/app/component/componenttype-config.xml b/WebContent/WEB-INF/etc/app/component/componenttype-config.xml index 0f503b6b4..231c66235 100644 --- a/WebContent/WEB-INF/etc/app/component/componenttype-config.xml +++ b/WebContent/WEB-INF/etc/app/component/componenttype-config.xml @@ -1,6 +1,6 @@ - + diff --git a/calc/com/tenwa/reckon/executor/CreateTransactionExecutor.java b/calc/com/tenwa/reckon/executor/CreateTransactionExecutor.java index c4dd44fbd..0b6eeefd8 100644 --- a/calc/com/tenwa/reckon/executor/CreateTransactionExecutor.java +++ b/calc/com/tenwa/reckon/executor/CreateTransactionExecutor.java @@ -123,7 +123,7 @@ public class CreateTransactionExecutor implements Transaction { } String yearRate = bean.getCb().getYearRate(); this.preHandle(bean.getCb(),bean); - checkYearRate( bean.getCb(), bean, new BigDecimal( bean.getCb().getYearRate() ) ); + checkYearRate( bean.getCb(), bean, new BigDecimal( bean.getCb().getYearRate() ) );//当初理解错误,成本利率和年利率不一样 if(bean.getCb().getRentOrRate().equals("rent")&&new BigDecimal(bean.getCb().getIncomeNumber()).multiply(new BigDecimal(bean.getCb().getRentValue())).compareTo(new BigDecimal(bean.getCb().getCleanLeaseMoney()))<0){ throw new BusinessException("按租金算年利率租金总和必须大于融资额"); } @@ -139,6 +139,7 @@ public class CreateTransactionExecutor implements Transaction { // 返回参数上做处理 return JSONEncoder.encode(jsonObject); }catch(BusinessException e){ + e.printStackTrace(); try { tx.rollback(); } catch (JBOException e1) { @@ -184,11 +185,12 @@ public class CreateTransactionExecutor implements Transaction { try { Map> productRevenues = ProductParamUtil.getProductComponentType( tcb.getProductId(), "PRD0390" ); tcb.setProductRevenues( productRevenues ); - String rateMin = productRevenues.get( "CostInterestRate" ).get( "CostInterestRate-MIN" ); + //年利率和成本利率不一样,对应的年利率改在页面进行校验 + /*String rateMin = productRevenues.get( "CostInterestRate" ).get( "CostInterestRate-MIN" ); String rateMax = productRevenues.get( "CostInterestRate" ).get( "CostInterestRate-MAX" ); if ( !( yearRate.compareTo( new BigDecimal( rateMax ) ) <= 0 && yearRate.compareTo( new BigDecimal( rateMin ) ) >= 0 ) ) { throw new BusinessException( "年利率: " + yearRate.setScale( 6, 4 ).toString() + ",不在产品配置区间范围内" ); - } + }*/ } catch ( Exception e ) { e.printStackTrace(); throw new BusinessException( e.getMessage() );