From 99d737189bc2be8bf6937f83e2392d14a8d3fd89 Mon Sep 17 00:00:00 2001 From: tangft <32189@DESKTOP-M6TAG3K> Date: Wed, 9 Jan 2019 17:50:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=BA=A7=E5=93=81=E5=9C=A8?= =?UTF-8?q?=E5=90=88=E5=90=8C=E5=88=B6=E4=BD=9C=E6=B5=81=E7=A8=8B=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E6=A0=87=E8=AF=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LBContractTemplate/contract_template.jsp | 5 ++- .../ContractApprovalApplyList.jsp | 6 +++ .../handle/FileTemplateUtil.java | 39 +++++++++++++------ 3 files changed, 37 insertions(+), 13 deletions(-) diff --git a/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp b/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp index a023b8a53..9a4ee5a2e 100644 --- a/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp +++ b/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp @@ -153,7 +153,8 @@ var docno = ""; $(document).ready(function(){ var RightType="<%=RightType%>"; - var phaseno="<%=phaseno%>" + var phaseno="<%=phaseno%>"; + var operationType = "<%=CurPage.getParameter("operationType")%>"; /* if(RightType=="ReadOnly"){ $('#A_Group_0010').css('display','none'); $('#A_Group_0020').css('display','none'); @@ -163,7 +164,7 @@ $('#A_Group_0010').css('display','none'); $('#A_Group_0020').css('display','none'); } - var sReturn = RunJavaMethodSqlca("com.tenwa.app.baseFileTemplate.handle.FileTemplateUtil","getContractClass","leasform="+"<%=leasform%>"+",isNetCar="+"<%=CurPage.getParameter("isNetCar")%>"); + var sReturn = RunJavaMethodSqlca("com.tenwa.app.baseFileTemplate.handle.FileTemplateUtil","getContractClass","leasform="+"<%=leasform%>"+",isNetCar="+"<%=CurPage.getParameter("isNetCar")%>"+",operationType="+operationType); var jsonData=eval("("+sReturn+")"); initFileTemplate(eval("("+jsonData[0].fileTemplate+")")); // initOneClass(); diff --git a/WebContent/Tenwa/Lease/Flow/Contract/ContractApproval/ContractApprovalApplyList.jsp b/WebContent/Tenwa/Lease/Flow/Contract/ContractApproval/ContractApprovalApplyList.jsp index 907f2ff67..8036f23ea 100644 --- a/WebContent/Tenwa/Lease/Flow/Contract/ContractApproval/ContractApprovalApplyList.jsp +++ b/WebContent/Tenwa/Lease/Flow/Contract/ContractApproval/ContractApprovalApplyList.jsp @@ -49,8 +49,14 @@ var leasform = sReturn[5]; var carAttributes = sReturn[6]; var isNetCar = sReturn[7]; + var sParams = "ApplyType=<%=sApplyType%>,CurUserID=<%=CurUser.getUserID()%>"; sParams =sParams+",isNetCar="+isNetCar+",carAttributes="+carAttributes+",leasform="+leasform+",ProductId="+product_id+",ProjectId="+id+",ProjectNo="+project_id+",customertype="+customertype+",ProjectName="+project_name+",ApplyType=<%=sApplyType%>"; + + if(flowno=="BContractApproveApply"){ + sParams =sParams+",operationType="+sReturn[8]; + } + var sReturnInfo = RunJavaMethodTrans("com.tenwa.lease.flow.contract.contractapproval.ContractApprovalStartAction","initFLow",sParams); if(typeof(sReturnInfo)=="undefined" || sReturnInfo=="" || sReturnInfo=="_CANCEL_") return; diff --git a/src/com/tenwa/app/baseFileTemplate/handle/FileTemplateUtil.java b/src/com/tenwa/app/baseFileTemplate/handle/FileTemplateUtil.java index df06e7193..bb8a457bf 100644 --- a/src/com/tenwa/app/baseFileTemplate/handle/FileTemplateUtil.java +++ b/src/com/tenwa/app/baseFileTemplate/handle/FileTemplateUtil.java @@ -41,6 +41,7 @@ public class FileTemplateUtil { public String contractId; public String contractNo; public String isNetCar;//用于判断是否是网约车 + public String operationType;//用于判断是否是北汽产品 public String getTemplateCalss() {return templateCalss;} public void setTemplateCalss(String templateCalss) {this.templateCalss = templateCalss;} @@ -92,6 +93,12 @@ public class FileTemplateUtil { public void setContractNo(String contractNo) { this.contractNo = contractNo; } + public String getOperationType() { + return operationType; + } + public void setOperationType(String operationType) { + this.operationType = operationType; + } public String getTemplateClass(Transaction Sqlca) throws Exception{ String fileClass=templateCalss.replaceAll("@", ","); @@ -130,18 +137,28 @@ public class FileTemplateUtil { } public String getContractClass(Transaction Sqlca){ - if("01".equals(leasform)){ - /*return "[{'fileTemplate':\""+"[{'text':'融资租赁合同-C端直租','value':'24aba365e2794a018814ae81341486bf'}," - + "{'text':'直租个人授权协议书','value':'3334eed6051248b88cd4f2a22e93ac96'},]"+"\"}]";*/ - return "[{'fileTemplate':\""+"[{'text':'合同(直租)','value':'24aba365e2794a018814ae81341486bf'}]"+"\"}]"; - }else{ - /*return "[{'fileTemplate':\""+"[{'text':'融资租赁合同-C端回租','value':'641c55a1168f4a488a5028ee68870156'}," - + "{'text':'回租个人授权协议书','value':'e980635a77124d5598be1717c062b877'}," - + "{'text':'抵押合同','value':'ec90c114914d4725b57729107888511c'}]"+"\"}]";*/ - if("0".equals(isNetCar)){ - return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)','value':'641c55a1168f4a488a5028ee68870156'}]"+"\"}]"; + if("BAIC_MOTOR".equals(operationType)){ + if("01".equals(leasform)){ + return "[{'fileTemplate':\""+"[{'text':'合同(直租)','value':'b20b919c6144480b9466e4ea9b0da142'}]"+"\"}]"; }else{ - return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)和抵押合同','value':'c8d5b729a0954482877c26a1293b766b'}]"+"\"}]"; + return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)','value':'115905186577406ea5414dd14e592e7d'}]"+"\"}]"; + } + }else if ("DYCD".equals(operationType)){ + return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)','value':'8d4232a5423e491ca905e77c54105a85'}]"+"\"}]"; + }else{ + if("01".equals(leasform)){ + /*return "[{'fileTemplate':\""+"[{'text':'融资租赁合同-C端直租','value':'24aba365e2794a018814ae81341486bf'}," + + "{'text':'直租个人授权协议书','value':'3334eed6051248b88cd4f2a22e93ac96'},]"+"\"}]";*/ + return "[{'fileTemplate':\""+"[{'text':'合同(直租)','value':'24aba365e2794a018814ae81341486bf'}]"+"\"}]"; + }else{ + /*return "[{'fileTemplate':\""+"[{'text':'融资租赁合同-C端回租','value':'641c55a1168f4a488a5028ee68870156'}," + + "{'text':'回租个人授权协议书','value':'e980635a77124d5598be1717c062b877'}," + + "{'text':'抵押合同','value':'ec90c114914d4725b57729107888511c'}]"+"\"}]";*/ + if("0".equals(isNetCar)){ + return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)','value':'641c55a1168f4a488a5028ee68870156'}]"+"\"}]"; + }else{ + return "[{'fileTemplate':\""+"[{'text':'合同(售后回租)和抵押合同','value':'c8d5b729a0954482877c26a1293b766b'}]"+"\"}]"; + } } } }