diff --git a/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp b/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp index dc4fbc68c..da96a1669 100644 --- a/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp +++ b/WebContent/Tenwa/Lease/Flow/Comm/LBContractTemplate/contract_template.jsp @@ -3,6 +3,7 @@ <%@page import="jbo.app.tenwa.customer.CUSTOMER_COMPANY_TEMP"%> <%@page import="jbo.app.tenwa.customer.CUSTOMER_PERSON_TEMP"%> <%@page import="jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO_TEMP"%> +<%@page import="jbo.app.tenwa.customer.CUSTOMER_ADDRESS_TEMP"%> <%@page import="com.amarsoft.app.check.CheckFLowPhaseNo"%> <%@ include file="/Frame/resources/include/include_begin_info.jspf"%><% /* @@ -59,11 +60,20 @@ NetMortgagor=cct.getAttribute("company_name").getString(); }else{ BizObjectManager cptm = JBOFactory.getBizObjectManager(CUSTOMER_PERSON_TEMP.CLASS_NAME); - String sSql = "select o.certid,o.mobile,o.nativeplace,o.fullname FROM o where o.customerid =:customerid and o.flowunid=:flowunid"; + BizObjectManager catm = JBOFactory.getBizObjectManager(CUSTOMER_ADDRESS_TEMP.CLASS_NAME); + String sSql = "select o.certid,o.mobile,o.nativeplace,o.MAILING_ADDRESS,o.fullname,o.WORKADD FROM o where o.customerid =:customerid and o.flowunid=:flowunid"; + String catSql = "select o.FULLADDRESS FROM o where o.customerid =:customerid and o.flowunid=:flowunid"; BizObject cpt = cptm.createQuery(sSql).setParameter("customerid", customerid).setParameter("flowunid", flowunid).getSingleResult(false); + BizObject cat = catm.createQuery(catSql).setParameter("customerid", customerid).setParameter("flowunid", flowunid).getSingleResult(false); certid=cpt.getAttribute("certid").getString(); mobile=cpt.getAttribute("mobile").getString(); - address=cpt.getAttribute("nativeplace").getString(); + if("居住地址".equals(cpt.getAttribute("MAILING_ADDRESS").getString())){ + address=cat.getAttribute("FULLADDRESS").getString(); + }else if("户籍地址".equals(cpt.getAttribute("MAILING_ADDRESS").getString())){ + address=cpt.getAttribute("nativeplace").getString(); + }else if("单位地址".equals(cpt.getAttribute("MAILING_ADDRESS").getString())){ + address=cpt.getAttribute("WORKADD").getString(); + } NetMortgagor=cpt.getAttribute("fullname").getString(); } //给网约车模板