From 6436061626d791c321769b6a783ff2673205ec9c Mon Sep 17 00:00:00 2001 From: zzk Date: Tue, 19 Apr 2022 11:18:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E5=89=8D=E7=BB=93=E6=B8=85=E9=83=A8?= =?UTF-8?q?=E5=88=86=E7=BB=93=E6=B8=85=E7=A7=9F=E8=B5=81=E7=89=A9=E6=9C=AA?= =?UTF-8?q?=E5=85=A8=E9=83=A8=E7=BB=93=E6=B8=85=E5=90=88=E5=90=8C=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E4=B8=8D=E5=8F=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LCContractTerminateInfo.jsp | 5 +---- .../CreateVoucherProcess/EarlyContract.java | 5 ++--- .../commbusiness/LBInitContractStatusBusiness.java | 14 +++++++++++--- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/WebContent/Tenwa/Lease/Flow/Comm/LCContractTerminate/LCContractTerminateInfo.jsp b/WebContent/Tenwa/Lease/Flow/Comm/LCContractTerminate/LCContractTerminateInfo.jsp index 539ac89e9..24ab35445 100644 --- a/WebContent/Tenwa/Lease/Flow/Comm/LCContractTerminate/LCContractTerminateInfo.jsp +++ b/WebContent/Tenwa/Lease/Flow/Comm/LCContractTerminate/LCContractTerminateInfo.jsp @@ -187,7 +187,6 @@ //计算债券总计 function updateContractBondTotal(){ - debugger var SETTLE_METHOD = getItemValue(0,0,"SETTLE_METHOD"); if(SETTLE_METHOD != "SETTLE_METHOD02"){ var dunrent = getItemValue(0,getRow(),"DUN_RENT"); @@ -266,7 +265,6 @@ //保存数据 function saveRecord(sPostEvents) { - debugger //校验是否有保证金代偿 var isCompensation = AsControl.RunJavaMethod("com.tenwa.reckon.executor.RentCalHelper","isCompensation","contractId=<%=contractId%>"); if("false" == isCompensation){ @@ -340,7 +338,7 @@ if(SETTLE_METHOD == "SETTLE_METHOD02"){ ret = AsControl.RunJavaMethodTrans("com.tenwa.voucher.CreateVoucherProcess.EarlyContract","partSettlement","REPURCHASE_RATIO="+EQUIPMENT_RATIO+",flowunid=<%=flowunid%>,contractId=<%=contractId%>,START_DATE=<%=START_DATE%>,plannumber=<%=PAYMENT_NUMBER%>,calType=pay_process,PAYDAY_ADJUST="+PAYDAY_ADJUST+",SettleMethod="+SETTLE_METHOD); }else{ - AsControl.RunJavaMethod("com.tenwa.voucher.CreateVoucherProcess.EarlyContract","alterdata","flowunid=<%=flowunid%>"); + AsControl.RunJavaMethodTrans("com.tenwa.voucher.CreateVoucherProcess.EarlyContract","alterdata","flowunid=<%=flowunid%>"); AsControl.RunJavaMethod("com.tenwa.reckon.executor.CreateTransactionExecutor","runTerminate","flowunid=<%=flowunid%>,plannumber=<%=paymentnumber%>,productId=<%=productId%>,calType=pay_process,MAXIMUM_TOTAL=MAXIMUM_TOTAL,REPURCHASE_MONEY = REPURCHASE_MONEY"); ret = "操作成功" } @@ -461,7 +459,6 @@ function settlemet(){ - debugger AsDialog.OpenSelector("selectEquipCarTermination","contractid,<%=contractId%>,flowunid,<%=flowunid%>","dialogWidth=" + parseInt(window.screen.width * 0.8) + "px dialogHeight=" + parseInt(window.screen.height * 0.6) + "px",function(sReturn){ if(!sReturn||sReturn=="_CANCEL_"||sReturn=="_NONE_"){ setItemValue(0,0,'SETTLE_METHOD',""); diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/EarlyContract.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/EarlyContract.java index 6b006b3fe..13299984a 100644 --- a/src_core/com/tenwa/voucher/CreateVoucherProcess/EarlyContract.java +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/EarlyContract.java @@ -324,7 +324,7 @@ public class EarlyContract { Transaction Sqlca = null; try { Sqlca = Transaction.createTransaction(tx); - String sql="UPDATE LB_EQUIPMENT_CAR_TEMP SET SETTLE_STATUS='3' WHERE (TERMINATE_TYPE IS NULL OR TERMINATE_TYPE='1') AND FLOWUNID='"+flowunid+"' "; + String sql="UPDATE LB_EQUIPMENT_CAR_TEMP SET TERMINATE_TYPE='3' WHERE (TERMINATE_TYPE IS NULL OR TERMINATE_TYPE='1') AND FLOWUNID='"+flowunid+"' "; Sqlca.executeSQL(sql); Sqlca.commit(); }catch(Exception e) { @@ -334,8 +334,7 @@ public class EarlyContract { e1.printStackTrace(); } e.printStackTrace(); - } - + } } diff --git a/src_tenwa/com/tenwa/lease/flow/contract/commbusiness/LBInitContractStatusBusiness.java b/src_tenwa/com/tenwa/lease/flow/contract/commbusiness/LBInitContractStatusBusiness.java index 8f5e661f4..1b66db3c5 100644 --- a/src_tenwa/com/tenwa/lease/flow/contract/commbusiness/LBInitContractStatusBusiness.java +++ b/src_tenwa/com/tenwa/lease/flow/contract/commbusiness/LBInitContractStatusBusiness.java @@ -15,14 +15,22 @@ public class LBInitContractStatusBusiness extends BaseBussiness { @Override public Object run(Transaction Sqlca) throws Exception { this.initBussinessParam(Sqlca); + String flowname=(String)this.getAttribute("FlowName"); String contractId=this.getAttribute("ContractId").toString(); + String settletype=this.getAttribute("settletype").toString(); String contractStatus=this.getAttribute("ContractStatus").toString(); + String FlowUnid=this.getAttribute("FlowUnid").toString(); BizObjectManager bom=JBOFactory.getBizObjectManager(LB_CONTRACT_INFO.CLASS_NAME); + String part = Sqlca.getString(" select case when min(TERMINATE_TYPE)=1 or min(TERMINATE_TYPE) is null then 'Y' else 'N' end from lb_equipment_car_temp lect where FLOWUNID = '"+FlowUnid+"' group by FLOWUNID"); Sqlca.join(bom); + if(contractStatus.equals("100")) { + settle(Sqlca); + } + if("提前结清".equals(flowname)&&"Y".equals(settletype)&&"Y".equals(part)) { + contractStatus = "31"; + } bom.createQuery("update O set CONTRACT_STATUS=:contractstatus where id=:contractid").setParameter("contractstatus", contractStatus).setParameter("contractid", contractId).executeUpdate(); - if(contractStatus.equals("100")) { - settle(Sqlca); - } + String sMessage="true"; return sMessage; }