diff --git a/D/tomcatLogs/info/info.log b/D/tomcatLogs/info/info.log new file mode 100644 index 000000000..e69de29bb diff --git a/WebContent/AppConfig/OrgUserManage/UserList.jsp b/WebContent/AppConfig/OrgUserManage/UserList.jsp index c0f9083cc..20c921c14 100644 --- a/WebContent/AppConfig/OrgUserManage/UserList.jsp +++ b/WebContent/AppConfig/OrgUserManage/UserList.jsp @@ -34,10 +34,53 @@ //{((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399"))?"true":"false"),"","Button","½ɫ","½ɫ","my_Addrole()","","","",""}, //{((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399"))?"true":"false"),"","Button","û½ɫ","û½ɫ","MuchAddrole()","","","",""}, {((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399") || CurUser.hasRole("800R00000067") )?"true":"false"),"","Button","ת","תԱ","UserChange()","","","","btn_icon_transfer"}, - {((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399") || CurUser.hasRole("800R00000067") )?"true":"false"),"","Button","ʼ","ʼû","ClearPassword()","","","","btn_icon_set"} - }; + {((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399") || CurUser.hasRole("800R00000067") )?"true":"false"),"","Button","ʼ","ʼû","ClearPassword()","","","","btn_icon_set"}, + {((CurUser.hasRole("099") || CurUser.hasRole("299") || CurUser.hasRole("399") || CurUser.hasRole("800R00000067") )?"true":"false"),"","Button","թ˻ͬ","թ˻ͬ","afsAccountSync()","","","","btn_icon_set"} + }; %><%@include file="/Frame/resources/include/ui/include_list.jspf"%> +<%@ include file="/Frame/resources/include/include_end.jspf"%> \ No newline at end of file diff --git a/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/RCScoreResultDetail.jsp b/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/RCScoreResultDetail.jsp new file mode 100644 index 000000000..77fc771bd --- /dev/null +++ b/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/RCScoreResultDetail.jsp @@ -0,0 +1,56 @@ +<%@ page import="jbo.oti.RC_SCORE_RESULT_DETAIL" %> +<%@ page import="org.apache.commons.collections.CollectionUtils" %> +<%@ page contentType="text/html; charset=GBK"%> +<%@include file="/IncludeBegin.jsp"%><% + String flowId = CurPage.getParameter("flowId");//̱ + System.out.println("flowId=" + flowId); + String projectNo = CurPage.getParameter("projectNo");//ҵ + System.out.println("projectNo=" + projectNo); + String sFlowUnid = CurPage.getParameter("FlowUnid");//̱ + System.out.println("sFlowUnid=" + sFlowUnid); + BizObjectManager rcScoreResultDetail = JBOFactory.getBizObjectManager(RC_SCORE_RESULT_DETAIL.CLASS_NAME); + List rcScoreResultDetailBizObjectList = rcScoreResultDetail.createQuery("project_no=:project_no").setParameter("project_no", projectNo).getResultList(false); + if(CollectionUtils.isNotEmpty(rcScoreResultDetailBizObjectList)){ +%> + + + + + + + + +<% + for(BizObject rcScoreResultDetailBizObject : rcScoreResultDetailBizObjectList){ + String person_type = rcScoreResultDetailBizObject.getAttribute("person_type").toString(); + String person_name = rcScoreResultDetailBizObject.getAttribute("person_name").toString(); + String third_result_url = rcScoreResultDetailBizObject.getAttribute("third_result_url").toString(); + String pboc_result_url = rcScoreResultDetailBizObject.getAttribute("pboc_result_url").toString(); + String update_time = rcScoreResultDetailBizObject.getAttribute("update_time").toString(); + +%> + + + + + + + +<% + } + }else { + %> +
ǰϸΪգִѯֽ
+ <% + } + %> + + + +<%@include file="/IncludeEnd.jsp"%> \ No newline at end of file diff --git a/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/personAddress.jsp b/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/personAddress.jsp new file mode 100644 index 000000000..0acc8fc22 --- /dev/null +++ b/WebContent/Tenwa/Lease/Flow/Project/BusinessApplication/personAddress.jsp @@ -0,0 +1,65 @@ +<%@ page import="org.apache.commons.lang3.StringUtils" %> +<%@ page contentType="text/html; charset=GBK"%> +<%@ include file="/Frame/resources/include/include_begin_info.jspf"%><% + + String addressId = CurPage.getParameter("addressId"); + String areaCode = ""; + System.out.println("--addressId---" + addressId); + ASObjectModel doTemp = new ASObjectModel("HouseholdSelectAddr"); + if(StringUtils.isNotEmpty(addressId)){ + ASResultSet as2 = Sqlca.getASResultSet(new SqlObject("select address_detail as address ,itemname as area_name, cpt.ap_address_code " + + " from rc_address_info cpt join code_library cl on cpt.ap_address_code = cl.itemno and cl.codeno = 'ZXAreaCode' where cpt.address_id = :addressId ").setParameter("addressId", addressId)); + if(as2.next()){ + doTemp.setDefaultValue("provincename", as2.getString("area_name")); + doTemp.setDefaultValue("dressdetail", as2.getString("address")); + areaCode = as2.getString("ap_address_code"); + doTemp.setDefaultValue("province", areaCode); + } + } + ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request); + dwTemp.Style = "2";//freeform + dwTemp.genHTMLObjectWindow(""); + String sButtons[][] = { + {"true","All","Button","","޸","saveRecord()","","","","btn_icon_save"}, + {"true","","Button","","бҳ","parent.AsDialog.ClosePage('cancel')","","","","btn_icon_return"} + }; + sButtonPosition = "south"; +%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%> + +<%@ include file="/Frame/resources/include/include_end.jspf"%> diff --git a/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp b/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp index 482b7f3a6..322a558ce 100644 --- a/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp +++ b/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp @@ -293,7 +293,7 @@ <%/*~[Describe=ѡƷ;]~*/%> function selectProductModel() { - AsDialog.OpenSelector("SelectCardataBrandNew","","dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", + AsDialog.OpenSelector("RCSelectCardataBrandNew","","dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", function(sReturn){ if(!sReturn||sReturn=="_CANCEL_"||sReturn==""||sReturn=="_NONE_") { @@ -333,14 +333,10 @@ <%/*~[Describe=ѡϵ;]~*/%> function selectCarSeries() { - var brandid=""; if(MyOjbect.brandid){ brandid=MyOjbect.brandid; - let selectType = 'SelectCardataSeriesCYC'; - if (MyOjbect.cartypea == 'SYC') { - selectType = 'SelectCardataSeriesSYC'; - } + let selectType = 'RCSelectCardataSeriesNew'; AsDialog.OpenSelector(selectType,"brandid,"+brandid,"dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", function(sReturn){ if(!sReturn||sReturn=="_CANCEL_"||sReturn==""||sReturn=="_NONE_") @@ -373,10 +369,7 @@ var seriesid=""; if(MyOjbect.seriesid){ seriesid=MyOjbect.seriesid; - let selectType = 'SelectCardataModelCYC'; - if (MyOjbect.cartypea == 'SYC') { - selectType = 'SelectCardataModelSYC'; - } + let selectType = 'RCSelectCardataModelNew'; AsDialog.OpenSelector(selectType,"seriesid,"+seriesid,"dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", function(sReturn){ if(!sReturn||sReturn=="_CANCEL_"||sReturn==""||sReturn=="_NONE_") diff --git a/WebContent/WEB-INF/etc/cache.xml b/WebContent/WEB-INF/etc/cache.xml index 45178d064..1767db05f 100644 --- a/WebContent/WEB-INF/etc/cache.xml +++ b/WebContent/WEB-INF/etc/cache.xml @@ -42,5 +42,8 @@ + + + \ No newline at end of file diff --git a/WebContent/WEB-INF/etc/jbo/jbo_customer.xml b/WebContent/WEB-INF/etc/jbo/jbo_customer.xml index 9d39dfc49..fa37f8490 100644 --- a/WebContent/WEB-INF/etc/jbo/jbo_customer.xml +++ b/WebContent/WEB-INF/etc/jbo/jbo_customer.xml @@ -1,5 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -301,6 +330,15 @@ + + + + + + + + + @@ -442,6 +480,15 @@ + + + + + + + + + @@ -2393,6 +2440,14 @@ + + + + + + + + @@ -2495,6 +2550,15 @@ + + + + + + + + + @@ -2591,6 +2655,26 @@ + + + + + + + + + + + + + + + + + + + + @@ -2632,6 +2716,26 @@ + + + + + + + + + + + + + + + + + + + + @@ -2671,6 +2775,27 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/WebContent/WEB-INF/etc/jbo/jbo_lease.xml b/WebContent/WEB-INF/etc/jbo/jbo_lease.xml index 82450e7da..3fec65962 100644 --- a/WebContent/WEB-INF/etc/jbo/jbo_lease.xml +++ b/WebContent/WEB-INF/etc/jbo/jbo_lease.xml @@ -3684,6 +3684,7 @@ + @@ -4094,6 +4095,27 @@ + + + + + + + + + + + + + + + + + + + + + @@ -4138,6 +4160,27 @@ + + + + + + + + + + + + + + + + + + + + + @@ -4182,6 +4225,27 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/WebContent/WEB-INF/etc/jbo/jbo_oti.xml b/WebContent/WEB-INF/etc/jbo/jbo_oti.xml index 8e0608513..04036f2be 100644 --- a/WebContent/WEB-INF/etc/jbo/jbo_oti.xml +++ b/WebContent/WEB-INF/etc/jbo/jbo_oti.xml @@ -699,5 +699,169 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/WebContent/WEB-INF/lib/bcprov-ext-jdk15-146.jar b/WebContent/WEB-INF/lib/bcprov-ext-jdk15-146.jar deleted file mode 100644 index 2d98d33c9..000000000 Binary files a/WebContent/WEB-INF/lib/bcprov-ext-jdk15-146.jar and /dev/null differ diff --git a/WebContent/WEB-INF/lib/bcprov-jdk15to18-1.76.jar b/WebContent/WEB-INF/lib/bcprov-jdk15to18-1.76.jar new file mode 100644 index 000000000..58310a56e Binary files /dev/null and b/WebContent/WEB-INF/lib/bcprov-jdk15to18-1.76.jar differ diff --git a/WebContent/WEB-INF/lib/xstream-1.3.1.jar b/WebContent/WEB-INF/lib/xstream-1.3.1.jar deleted file mode 100644 index 4ef4219c6..000000000 Binary files a/WebContent/WEB-INF/lib/xstream-1.3.1.jar and /dev/null differ diff --git a/WebContent/WEB-INF/lib/xstream-1.4.9.jar b/WebContent/WEB-INF/lib/xstream-1.4.9.jar new file mode 100644 index 000000000..c754e0ab7 Binary files /dev/null and b/WebContent/WEB-INF/lib/xstream-1.4.9.jar differ diff --git a/WebContent/WEB-INF/web.xml b/WebContent/WEB-INF/web.xml index 570d63cfa..8d0f3b5e1 100644 --- a/WebContent/WEB-INF/web.xml +++ b/WebContent/WEB-INF/web.xml @@ -129,7 +129,18 @@ als - + + AfsResultServlet + com.ample.esb.controller.AfsResultServlet + + + ScoreResultServlet + com.ample.esb.server.ScoreResultServlet + + DataSource + als + + RewriteRunJavaMethodServlet com.tenwa.workflow.RewriteRunJavaMethodServlet @@ -311,7 +322,14 @@ SmsRptServlet /smsRpt - + + AfsResultServlet + /afsResult + + + ScoreResultServlet + /scoreResult + DocDownloadZipServlet /servlet/view/docDownloadZipServlet @@ -512,7 +530,9 @@ org.springframework.web.context.ContextLoaderListener - + + com.tenwa.httpclient.pboc.PbocThreadPool + diff --git a/calc/com/tenwa/reckon/executor/RentCalculateExecutor.java b/calc/com/tenwa/reckon/executor/RentCalculateExecutor.java new file mode 100644 index 000000000..372d03ab9 --- /dev/null +++ b/calc/com/tenwa/reckon/executor/RentCalculateExecutor.java @@ -0,0 +1,121 @@ +package com.tenwa.reckon.executor; + +import java.math.BigDecimal; +import java.util.Date; +import java.util.List; +import java.util.Map; + +import com.tenwa.app.manage.qiyuesuo.v2.ContractSignVtwoUtils; +import jbo.app.tenwa.calc.LC_CALC_CONDITION; +import jbo.app.tenwa.calc.LC_RENT_INCOME; +import jbo.app.tenwa.calc.LC_RENT_PLAN; +import jbo.com.tenwa.lease.comm.LC_CAR_DISPOSE; +import jbo.com.tenwa.lease.comm.LC_OCCUPY_RENT_LIST; + +import com.amarsoft.app.awe.config.InitDBType; +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.BizObjectQuery; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; +import com.amarsoft.are.jbo.JBOTransaction; +import com.amarsoft.are.util.json.JSONEncoder; +import com.amarsoft.are.util.json.JSONObject; +import com.tenwa.reckon.util.Conn; +import com.tenwa.reckon.util.DateUtil; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * ͬУ + * @author tenwapc + * + */ +public class RentCalculateExecutor { + private static final Logger logger = LoggerFactory.getLogger(RentCalculateExecutor.class); + private String contractId; + private String startList; + private String paydayAdjust; + private String paymentnumber; + private String planId; + + /** + * УֹǷϷ + * @return + * @throws Exception + */ + public String checkPaydayAdjust() throws Exception { + JSONObject jsonObject = JSONObject.createObject(); + JBOTransaction tx=null; + try{ + tx=JBOFactory.createJBOTransaction(); + String checkSql = " select min(plan_date) mindate from LC_RENT_PLAN where contract_id = ? and payment_number=?"; + Conn conn = new Conn(tx); + List> results = conn.executeQuery(checkSql, this.contractId,this.getPaymentnumber()); + String mindate = results.get(0).get("mindate"); + logger.info("20211104 УֹǷϷ mindate= " + mindate); + logger.info("20211104 УֹǷϷ paydayAdjust= " + this.paydayAdjust); + //ȡλ ַ + String minDateStr = mindate.substring(mindate.lastIndexOf("/") + 1); + String paydayAdjustStr = this.paydayAdjust.substring(this.paydayAdjust.lastIndexOf("/") + 1); + logger.info("20211104 УֹǷϷ minDateStr= " + minDateStr); + logger.info("20211104 УֹǷϷ paydayAdjustStr= " + paydayAdjustStr); + if(minDateStr.equals(paydayAdjustStr)){ + jsonObject.appendElement("result", "false"); + jsonObject.appendElement("msg","ԼֹղѻƻΣ"); + }else { + jsonObject.appendElement("result", "true"); + } + }catch(Exception e){ + tx.rollback(); + e.printStackTrace(); + jsonObject.appendElement("result", "false"); + jsonObject.appendElement("msg","æԺԣ"); + }finally{ + tx.commit(); + } + return JSONEncoder.encode(jsonObject); + } + + public String getContractId() { + return contractId; + } + + public void setContractId(String contractId) { + this.contractId = contractId; + } + + + public String getStartList() { + return startList; + } + + public void setStartList(String startList) { + this.startList = startList; + } + + public String getPaydayAdjust() { + return paydayAdjust; + } + + public void setPaydayAdjust(String paydayAdjust) { + this.paydayAdjust = paydayAdjust; + } + + public String getPaymentnumber() { + return paymentnumber; + } + + public void setPaymentnumber(String paymentnumber) { + this.paymentnumber = paymentnumber; + } + + public String getPlanId() { + return planId; + } + + public void setPlanId(String planId) { + this.planId = planId; + } + +} diff --git a/config/baic.properties b/config/baic.properties new file mode 100644 index 000000000..800a31786 --- /dev/null +++ b/config/baic.properties @@ -0,0 +1,12 @@ +# esb config +esb_url=http://47.93.34.101/baicfc/trans? +userid=TYJWBY7F +AFS012_serviceid=N9LZG7J8OXSD90B4 +AMP005_serviceid=24LITXVE9LKXANTD + +log_path=D:/tmp/esb/log/ + +## թ +afs_url=http://test-antifraud.baicfc.com/Instinct.UI.WebClient_5.3.1_2023/api/redirect? +RSAPublicKey=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAtmxe7GIws+1RwPtICBi+GKbNEYrqz+xkPZN8Cv3vnyK/cX87n2volMPV1LZBGLyFj2ckyLmIt+uC1SHDio+N9/e695UT2rvTJdP7rho0yA2sXmAqG4pjVA8dPHFgvUIaW/SIwPpqHnPrKTj6YHp5/6Amuvq7W5WujHsM1aq61p0RL6b6CQlwQtXK1MGE95eDJrhY0eO2RcoKBOJgQSa2MdqSSQ9jYuu/9lpoENxvHcHydxFqwzwJtP4Noct9ZplSjxA/OsincK4q6ELSDL3f9ckBXGmZrHDkYVyv0hD1QeC8Pgy3FAppgPPfMXPLUWgswV24/dEJP8qiCTacFfF9iwIDAQAB + diff --git a/config/bigdata.properties b/config/bigdata.properties index cca3cffe4..78377d72d 100644 --- a/config/bigdata.properties +++ b/config/bigdata.properties @@ -25,7 +25,15 @@ t_password = {MD5}i3rx5Ta+2VL5Dj5T866giQ== t_methodType = queryReport - +#pboc canshu +pboc_url = http://9.35.68.228:8080/pbcrs/api/msgDispatchController/postProcess +pboc_txCode = ZXCXA01 +pboc_reqSysCode = CX +pboc_loginUserCode = test +pboc_loginPwd = 123456 +pboc_finDept = a5adabc8ae00417bbe1b4f54423f4d03 +pboc_authArchUrl = www.baidu.com +pboc_certSrcUrl = www.sino.com diff --git a/config/quartz.properties b/config/quartz.properties index 9734a6360..875de3fad 100644 --- a/config/quartz.properties +++ b/config/quartz.properties @@ -1,4 +1,4 @@ -org.quartz.dataSource.zhulhDS.URL=jdbc:mysql://47.93.34.101:10323/apzl?rewriteBatchedStatements=true&useUnicode=true&characterEncoding=GBK&autoReconnectForPools=true&autoReconnect=true&useSSL=false +org.quartz.dataSource.zhulhDS.URL=jdbc:mysql://60.205.189.63:3306/apzl?rewriteBatchedStatements=true&useUnicode=true&characterEncoding=GBK&autoReconnectForPools=true&autoReconnect=true&useSSL=false org.quartz.dataSource.zhulhDS.user=338A48E135315FDBC2DF24EB080903D7 org.quartz.dataSource.zhulhDS.key=431DC9744DEF477868F97C4842F87AB3 org.quartz.dataSource.zhulhDS.driver=com.mysql.jdbc.Driver diff --git a/src/com/ample/esb/bean/afs/AccountSyncRequest.java b/src/com/ample/esb/bean/afs/AccountSyncRequest.java new file mode 100644 index 000000000..0133359c5 --- /dev/null +++ b/src/com/ample/esb/bean/afs/AccountSyncRequest.java @@ -0,0 +1,52 @@ +package com.ample.esb.bean.afs; + +import com.thoughtworks.xstream.annotations.XStreamAlias; +import com.thoughtworks.xstream.annotations.XStreamOmitField; + +@XStreamAlias("REQUEST") +public class AccountSyncRequest { + @XStreamAlias("USER_NAME") + private String userName; + + @XStreamAlias("USER_ID") + private String userId; + + @XStreamAlias("SYSTEM_STATE") + private String systemState; + + @XStreamOmitField + private String operatorId; + + public String getUserName() { + return userName; + } + + public void setUserName(String userName) { + this.userName = userName; + } + + public String getUserId() { + return userId; + } + + public void setUserId(String userId) { + this.userId = userId; + } + + public String getSystemState() { + return systemState; + } + + public void setSystemState(String systemState) { + this.systemState = systemState; + } + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } + +} diff --git a/src/com/ample/esb/bean/afs/AccountSyncResponse.java b/src/com/ample/esb/bean/afs/AccountSyncResponse.java new file mode 100644 index 000000000..3d4553952 --- /dev/null +++ b/src/com/ample/esb/bean/afs/AccountSyncResponse.java @@ -0,0 +1,17 @@ +package com.ample.esb.bean.afs; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +@XStreamAlias("RESPONSE") +public class AccountSyncResponse { + @XStreamAlias("RESULT") + private String result; + + public String getResult() { + return result; + } + + public void setResult(String result) { + this.result = result; + } +} diff --git a/src/com/ample/esb/bean/afs/AfsResultRequest.java b/src/com/ample/esb/bean/afs/AfsResultRequest.java new file mode 100644 index 000000000..645d0bc66 --- /dev/null +++ b/src/com/ample/esb/bean/afs/AfsResultRequest.java @@ -0,0 +1,599 @@ +package com.ample.esb.bean.afs; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class AfsResultRequest { + @XStreamAlias("CMON_ID") + private String cmonId; + + @XStreamAlias("COUNTRY_CODE") + private String countryCode; + + @XStreamAlias("GROUP_MEMBER_CODE") + private String groupMemberCode; + + @XStreamAlias("APPLY_NO") + private String applyNo; + + @XStreamAlias("CAPTURE_DATE") + private String captureDate; + + @XStreamAlias("CAPTURE_TIME") + private String captureTime; + + @XStreamAlias("APPLY_TYPE") + private String applyType; + + @XStreamAlias("FRAUD_SCORE") + private String fraudScore; + + @XStreamAlias("FRAUD_ALERT") + private String fraudAlert; + + @XStreamAlias("ACTION_TAKEN") + private String actionTaken; + + @XStreamAlias("USER_DEFINED_ALERT") + private String userDefinedAlert; + + @XStreamAlias("DECISION_REASON") + private String decisionReason; + + @XStreamAlias("ACTION_USER") + private String actionUser; + + @XStreamAlias("RULE_TRIGGERED_1") + private String ruleTriggered_1; + + @XStreamAlias("RULE_TRIGGERED_2") + private String ruleTriggered_2; + + @XStreamAlias("RULE_TRIGGERED_3") + private String ruleTriggered_3; + + @XStreamAlias("RULE_TRIGGERED_4") + private String ruleTriggered_4; + + @XStreamAlias("RULE_TRIGGERED_5") + private String ruleTriggered_5; + + @XStreamAlias("RULE_TRIGGERED_6") + private String ruleTriggered_6; + + @XStreamAlias("RULE_TRIGGERED_7") + private String ruleTriggered_7; + + @XStreamAlias("RULE_TRIGGERED_8") + private String ruleTriggered_8; + + @XStreamAlias("RULE_TRIGGERED_9") + private String ruleTriggered_9; + + @XStreamAlias("RULE_TRIGGERED_10") + private String ruleTriggered_10; + + @XStreamAlias("RULE_TRIGGERED_11") + private String ruleTriggered_11; + + @XStreamAlias("RULE_TRIGGERED_12") + private String ruleTriggered_12; + + @XStreamAlias("RULE_TRIGGERED_13") + private String ruleTriggered_13; + + @XStreamAlias("RULE_TRIGGERED_14") + private String ruleTriggered_14; + + @XStreamAlias("RULE_TRIGGERED_15") + private String ruleTriggered_15; + + @XStreamAlias("RULE_TRIGGERED_16") + private String ruleTriggered_16; + + @XStreamAlias("RULE_TRIGGERED_17") + private String ruleTriggered_17; + + @XStreamAlias("RULE_TRIGGERED_18") + private String ruleTriggered_18; + + @XStreamAlias("RULE_TRIGGERED_19") + private String ruleTriggered_19; + + @XStreamAlias("RULE_TRIGGERED_20") + private String ruleTriggered_20; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_1") + private String descriptionruletriggered_1; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_2") + private String descriptionruletriggered_2; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_3") + private String descriptionruletriggered_3; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_4") + private String descriptionruletriggered_4; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_5") + private String descriptionruletriggered_5; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_6") + private String descriptionruletriggered_6; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_7") + private String descriptionruletriggered_7; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_8") + private String descriptionruletriggered_8; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_9") + private String descriptionruletriggered_9; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_10") + private String descriptionruletriggered_10; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_11") + private String descriptionruletriggered_11; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_12") + private String descriptionruletriggered_12; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_13") + private String descriptionruletriggered_13; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_14") + private String descriptionruletriggered_14; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_15") + private String descriptionruletriggered_15; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_16") + private String descriptionruletriggered_16; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_17") + private String descriptionruletriggered_17; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_18") + private String descriptionruletriggered_18; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_19") + private String descriptionruletriggered_19; + + @XStreamAlias("DESCRIPTION_RULE_TRIGGERED_20") + private String descriptionruletriggered_20; + + @XStreamAlias("DIARY") + private Diary diary; + + public String getCmonId() { + return cmonId; + } + + public void setCmonId(String cmonId) { + this.cmonId = cmonId; + } + + public String getCountryCode() { + return countryCode; + } + + public void setCountryCode(String countryCode) { + this.countryCode = countryCode; + } + + public String getGroupMemberCode() { + return groupMemberCode; + } + + public void setGroupMemberCode(String groupMemberCode) { + this.groupMemberCode = groupMemberCode; + } + + public String getApplyNo() { + return applyNo; + } + + public void setApplyNo(String applyNo) { + this.applyNo = applyNo; + } + + public String getCaptureDate() { + return captureDate; + } + + public void setCaptureDate(String captureDate) { + this.captureDate = captureDate; + } + + public String getCaptureTime() { + return captureTime; + } + + public void setCaptureTime(String captureTime) { + this.captureTime = captureTime; + } + + public String getApplyType() { + return applyType; + } + + public void setApplyType(String applyType) { + this.applyType = applyType; + } + + public String getFraudScore() { + return fraudScore; + } + + public void setFraudScore(String fraudScore) { + this.fraudScore = fraudScore; + } + + public String getFraudAlert() { + return fraudAlert; + } + + public void setFraudAlert(String fraudAlert) { + this.fraudAlert = fraudAlert; + } + + public String getActionTaken() { + return actionTaken; + } + + public void setActionTaken(String actionTaken) { + this.actionTaken = actionTaken; + } + + public String getUserDefinedAlert() { + return userDefinedAlert; + } + + public void setUserDefinedAlert(String userDefinedAlert) { + this.userDefinedAlert = userDefinedAlert; + } + + public String getDecisionReason() { + return decisionReason; + } + + public void setDecisionReason(String decisionReason) { + this.decisionReason = decisionReason; + } + + public String getActionUser() { + return actionUser; + } + + public void setActionUser(String actionUser) { + this.actionUser = actionUser; + } + + public String getRuleTriggered_1() { + return ruleTriggered_1; + } + + public void setRuleTriggered_1(String ruleTriggered_1) { + this.ruleTriggered_1 = ruleTriggered_1; + } + + public String getRuleTriggered_2() { + return ruleTriggered_2; + } + + public void setRuleTriggered_2(String ruleTriggered_2) { + this.ruleTriggered_2 = ruleTriggered_2; + } + + public String getRuleTriggered_3() { + return ruleTriggered_3; + } + + public void setRuleTriggered_3(String ruleTriggered_3) { + this.ruleTriggered_3 = ruleTriggered_3; + } + + public String getRuleTriggered_4() { + return ruleTriggered_4; + } + + public void setRuleTriggered_4(String ruleTriggered_4) { + this.ruleTriggered_4 = ruleTriggered_4; + } + + public String getRuleTriggered_5() { + return ruleTriggered_5; + } + + public void setRuleTriggered_5(String ruleTriggered_5) { + this.ruleTriggered_5 = ruleTriggered_5; + } + + public String getRuleTriggered_6() { + return ruleTriggered_6; + } + + public void setRuleTriggered_6(String ruleTriggered_6) { + this.ruleTriggered_6 = ruleTriggered_6; + } + + public String getRuleTriggered_7() { + return ruleTriggered_7; + } + + public void setRuleTriggered_7(String ruleTriggered_7) { + this.ruleTriggered_7 = ruleTriggered_7; + } + + public String getRuleTriggered_8() { + return ruleTriggered_8; + } + + public void setRuleTriggered_8(String ruleTriggered_8) { + this.ruleTriggered_8 = ruleTriggered_8; + } + + public String getRuleTriggered_9() { + return ruleTriggered_9; + } + + public void setRuleTriggered_9(String ruleTriggered_9) { + this.ruleTriggered_9 = ruleTriggered_9; + } + + public String getRuleTriggered_10() { + return ruleTriggered_10; + } + + public void setRuleTriggered_10(String ruleTriggered_10) { + this.ruleTriggered_10 = ruleTriggered_10; + } + + public String getRuleTriggered_11() { + return ruleTriggered_11; + } + + public void setRuleTriggered_11(String ruleTriggered_11) { + this.ruleTriggered_11 = ruleTriggered_11; + } + + public String getRuleTriggered_12() { + return ruleTriggered_12; + } + + public void setRuleTriggered_12(String ruleTriggered_12) { + this.ruleTriggered_12 = ruleTriggered_12; + } + + public String getRuleTriggered_13() { + return ruleTriggered_13; + } + + public void setRuleTriggered_13(String ruleTriggered_13) { + this.ruleTriggered_13 = ruleTriggered_13; + } + + public String getRuleTriggered_14() { + return ruleTriggered_14; + } + + public void setRuleTriggered_14(String ruleTriggered_14) { + this.ruleTriggered_14 = ruleTriggered_14; + } + + public String getRuleTriggered_15() { + return ruleTriggered_15; + } + + public void setRuleTriggered_15(String ruleTriggered_15) { + this.ruleTriggered_15 = ruleTriggered_15; + } + + public String getRuleTriggered_16() { + return ruleTriggered_16; + } + + public void setRuleTriggered_16(String ruleTriggered_16) { + this.ruleTriggered_16 = ruleTriggered_16; + } + + public String getRuleTriggered_17() { + return ruleTriggered_17; + } + + public void setRuleTriggered_17(String ruleTriggered_17) { + this.ruleTriggered_17 = ruleTriggered_17; + } + + public String getRuleTriggered_18() { + return ruleTriggered_18; + } + + public void setRuleTriggered_18(String ruleTriggered_18) { + this.ruleTriggered_18 = ruleTriggered_18; + } + + public String getRuleTriggered_19() { + return ruleTriggered_19; + } + + public void setRuleTriggered_19(String ruleTriggered_19) { + this.ruleTriggered_19 = ruleTriggered_19; + } + + public String getRuleTriggered_20() { + return ruleTriggered_20; + } + + public void setRuleTriggered_20(String ruleTriggered_20) { + this.ruleTriggered_20 = ruleTriggered_20; + } + + public String getDescriptionruletriggered_1() { + return descriptionruletriggered_1; + } + + public void setDescriptionruletriggered_1(String descriptionruletriggered_1) { + this.descriptionruletriggered_1 = descriptionruletriggered_1; + } + + public String getDescriptionruletriggered_2() { + return descriptionruletriggered_2; + } + + public void setDescriptionruletriggered_2(String descriptionruletriggered_2) { + this.descriptionruletriggered_2 = descriptionruletriggered_2; + } + + public String getDescriptionruletriggered_3() { + return descriptionruletriggered_3; + } + + public void setDescriptionruletriggered_3(String descriptionruletriggered_3) { + this.descriptionruletriggered_3 = descriptionruletriggered_3; + } + + public String getDescriptionruletriggered_4() { + return descriptionruletriggered_4; + } + + public void setDescriptionruletriggered_4(String descriptionruletriggered_4) { + this.descriptionruletriggered_4 = descriptionruletriggered_4; + } + + public String getDescriptionruletriggered_5() { + return descriptionruletriggered_5; + } + + public void setDescriptionruletriggered_5(String descriptionruletriggered_5) { + this.descriptionruletriggered_5 = descriptionruletriggered_5; + } + + public String getDescriptionruletriggered_6() { + return descriptionruletriggered_6; + } + + public void setDescriptionruletriggered_6(String descriptionruletriggered_6) { + this.descriptionruletriggered_6 = descriptionruletriggered_6; + } + + public String getDescriptionruletriggered_7() { + return descriptionruletriggered_7; + } + + public void setDescriptionruletriggered_7(String descriptionruletriggered_7) { + this.descriptionruletriggered_7 = descriptionruletriggered_7; + } + + public String getDescriptionruletriggered_8() { + return descriptionruletriggered_8; + } + + public void setDescriptionruletriggered_8(String descriptionruletriggered_8) { + this.descriptionruletriggered_8 = descriptionruletriggered_8; + } + + public String getDescriptionruletriggered_9() { + return descriptionruletriggered_9; + } + + public void setDescriptionruletriggered_9(String descriptionruletriggered_9) { + this.descriptionruletriggered_9 = descriptionruletriggered_9; + } + + public String getDescriptionruletriggered_10() { + return descriptionruletriggered_10; + } + + public void setDescriptionruletriggered_10(String descriptionruletriggered_10) { + this.descriptionruletriggered_10 = descriptionruletriggered_10; + } + + public String getDescriptionruletriggered_11() { + return descriptionruletriggered_11; + } + + public void setDescriptionruletriggered_11(String descriptionruletriggered_11) { + this.descriptionruletriggered_11 = descriptionruletriggered_11; + } + + public String getDescriptionruletriggered_12() { + return descriptionruletriggered_12; + } + + public void setDescriptionruletriggered_12(String descriptionruletriggered_12) { + this.descriptionruletriggered_12 = descriptionruletriggered_12; + } + + public String getDescriptionruletriggered_13() { + return descriptionruletriggered_13; + } + + public void setDescriptionruletriggered_13(String descriptionruletriggered_13) { + this.descriptionruletriggered_13 = descriptionruletriggered_13; + } + + public String getDescriptionruletriggered_14() { + return descriptionruletriggered_14; + } + + public void setDescriptionruletriggered_14(String descriptionruletriggered_14) { + this.descriptionruletriggered_14 = descriptionruletriggered_14; + } + + public String getDescriptionruletriggered_15() { + return descriptionruletriggered_15; + } + + public void setDescriptionruletriggered_15(String descriptionruletriggered_15) { + this.descriptionruletriggered_15 = descriptionruletriggered_15; + } + + public String getDescriptionruletriggered_16() { + return descriptionruletriggered_16; + } + + public void setDescriptionruletriggered_16(String descriptionruletriggered_16) { + this.descriptionruletriggered_16 = descriptionruletriggered_16; + } + + public String getDescriptionruletriggered_17() { + return descriptionruletriggered_17; + } + + public void setDescriptionruletriggered_17(String descriptionruletriggered_17) { + this.descriptionruletriggered_17 = descriptionruletriggered_17; + } + + public String getDescriptionruletriggered_18() { + return descriptionruletriggered_18; + } + + public void setDescriptionruletriggered_18(String descriptionruletriggered_18) { + this.descriptionruletriggered_18 = descriptionruletriggered_18; + } + + public String getDescriptionruletriggered_19() { + return descriptionruletriggered_19; + } + + public void setDescriptionruletriggered_19(String descriptionruletriggered_19) { + this.descriptionruletriggered_19 = descriptionruletriggered_19; + } + + public String getDescriptionruletriggered_20() { + return descriptionruletriggered_20; + } + + public void setDescriptionruletriggered_20(String descriptionruletriggered_20) { + this.descriptionruletriggered_20 = descriptionruletriggered_20; + } + + public Diary getDiary() { + return diary; + } + + public void setDiary(Diary diary) { + this.diary = diary; + } +} diff --git a/src/com/ample/esb/bean/afs/Diary.java b/src/com/ample/esb/bean/afs/Diary.java new file mode 100644 index 000000000..a2b015c52 --- /dev/null +++ b/src/com/ample/esb/bean/afs/Diary.java @@ -0,0 +1,49 @@ +package com.ample.esb.bean.afs; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Diary { + @XStreamAlias("DIARY_DATE") + private String diaryDate; + + @XStreamAlias("DIARY_TIME") + private String diaryTime; + + @XStreamAlias("DIARY_USER_ID") + private String diaryUserId; + + @XStreamAlias("DIARY_NOTE") + private String diaryNote; + + public String getDiaryDate() { + return diaryDate; + } + + public void setDiaryDate(String diaryDate) { + this.diaryDate = diaryDate; + } + + public String getDiaryTime() { + return diaryTime; + } + + public void setDiaryTime(String diaryTime) { + this.diaryTime = diaryTime; + } + + public String getDiaryUserId() { + return diaryUserId; + } + + public void setDiaryUserId(String diaryUserId) { + this.diaryUserId = diaryUserId; + } + + public String getDiaryNote() { + return diaryNote; + } + + public void setDiaryNote(String diaryNote) { + this.diaryNote = diaryNote; + } +} diff --git a/src/com/ample/esb/bean/amp/Addr.java b/src/com/ample/esb/bean/amp/Addr.java new file mode 100644 index 000000000..67710463f --- /dev/null +++ b/src/com/ample/esb/bean/amp/Addr.java @@ -0,0 +1,148 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Addr { + @XStreamAlias("PROVINCE") + private String province; + + @XStreamAlias("CITY") + private String city; + + @XStreamAlias("DISTRICT") + private String district; + + @XStreamAlias("PROVINCE_GB") + private String provinceGB; + + @XStreamAlias("CITY_GB") + private String cityGB; + + @XStreamAlias("DISTRICT_GB") + private String districtGB; + + @XStreamAlias("STREET_GB") + private String streetGB; + + @XStreamAlias("ADDRESS") + private String address; + + @XStreamAlias("POSTCODE") + private String postCode; + + @XStreamAlias("ADDRTYPE") + private String addrType; + + @XStreamAlias("ADDRNUM") + private String addrNum; + + @XStreamAlias("PROPERTY_TYPE_CDE") + private String propertyTypeCde; + + @XStreamAlias("HUKOU_ADDRESS") + private String hukouAddress; + + public String getProvince() { + return province; + } + + public void setProvince(String province) { + this.province = province; + } + + public String getCity() { + return city; + } + + public void setCity(String city) { + this.city = city; + } + + public String getDistrict() { + return district; + } + + public void setDistrict(String district) { + this.district = district; + } + + public String getProvinceGB() { + return provinceGB; + } + + public void setProvinceGB(String provinceGB) { + this.provinceGB = provinceGB; + } + + public String getCityGB() { + return cityGB; + } + + public void setCityGB(String cityGB) { + this.cityGB = cityGB; + } + + public String getDistrictGB() { + return districtGB; + } + + public void setDistrictGB(String districtGB) { + this.districtGB = districtGB; + } + + public String getStreetGB() { + return streetGB; + } + + public void setStreetGB(String streetGB) { + this.streetGB = streetGB; + } + + public String getAddress() { + return address; + } + + public void setAddress(String address) { + this.address = address; + } + + public String getPostCode() { + return postCode; + } + + public void setPostCode(String postCode) { + this.postCode = postCode; + } + + public String getAddrType() { + return addrType; + } + + public void setAddrType(String addrType) { + this.addrType = addrType; + } + + public String getAddrNum() { + return addrNum; + } + + public void setAddrNum(String addrNum) { + this.addrNum = addrNum; + } + + public String getPropertyTypeCde() { + return propertyTypeCde; + } + + public void setPropertyTypeCde(String propertyTypeCde) { + this.propertyTypeCde = propertyTypeCde; + } + + public String getHukouAddress() { + return hukouAddress; + } + + public void setHukouAddress(String hukouAddress) { + this.hukouAddress = hukouAddress; + } +} diff --git a/src/com/ample/esb/bean/amp/AmpRequest.java b/src/com/ample/esb/bean/amp/AmpRequest.java new file mode 100644 index 000000000..588bcf7da --- /dev/null +++ b/src/com/ample/esb/bean/amp/AmpRequest.java @@ -0,0 +1,40 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; +import com.thoughtworks.xstream.annotations.XStreamOmitField; + +@XStreamAlias("REQUEST") +public class AmpRequest { + @XStreamAlias("APPLICATION") + private String application; + + @XStreamOmitField + private String operatorId; + + @XStreamOmitField + private String flowUnid; + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } + + public String getFlowUnid() { + return flowUnid; + } + + public void setFlowUnid(String flowUnid) { + this.flowUnid = flowUnid; + } + + public String getApplication() { + return application; + } + + public void setApplication(String application) { + this.application = application; + } +} diff --git a/src/com/ample/esb/bean/amp/AmpResponse.java b/src/com/ample/esb/bean/amp/AmpResponse.java new file mode 100644 index 000000000..9c53c1978 --- /dev/null +++ b/src/com/ample/esb/bean/amp/AmpResponse.java @@ -0,0 +1,16 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; +@XStreamAlias("RESPONSE") +public class AmpResponse { + @XStreamAlias("RESULT") + private String result; + + public String getResult() { + return result; + } + + public void setResult(String result) { + this.result = result; + } +} diff --git a/src/com/ample/esb/bean/amp/Applicant2.java b/src/com/ample/esb/bean/amp/Applicant2.java new file mode 100644 index 000000000..16145c974 --- /dev/null +++ b/src/com/ample/esb/bean/amp/Applicant2.java @@ -0,0 +1,104 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Applicant2 { + @XStreamAlias("DEALERINFO") + private DealerInfo dealerInfo; + + @XStreamAlias("LOANINFO") + private LoanInfo loanInfo; + + @XStreamAlias("VEHICLEINFO") + private VehicleInfo vehicleInfo; + + @XStreamAlias("CUSTOMERINFO") + private CustomerInfo customerInfo; + + @XStreamAlias("COBORROWERS") + private Coborrowers coborrowers; + + @XStreamAlias("GUARANTORINFO") + private GuarantorInfo guarantorInfo; + + @XStreamAlias("CONTINFO") + private ContInfo contInfo; + + @XStreamAlias("APPLICATIONINFO") + private ApplicationInfo applicationInfo; + + @XStreamAlias("PREVIOUSLYVEHICLE") + private PreviouslyVehicle previouslyVehicle; + + public DealerInfo getDealerInfo() { + return dealerInfo; + } + + public void setDealerInfo(DealerInfo dealerInfo) { + this.dealerInfo = dealerInfo; + } + + public LoanInfo getLoanInfo() { + return loanInfo; + } + + public void setLoanInfo(LoanInfo loanInfo) { + this.loanInfo = loanInfo; + } + + public VehicleInfo getVehicleInfo() { + return vehicleInfo; + } + + public void setVehicleInfo(VehicleInfo vehicleInfo) { + this.vehicleInfo = vehicleInfo; + } + + public CustomerInfo getCustomerInfo() { + return customerInfo; + } + + public void setCustomerInfo(CustomerInfo customerInfo) { + this.customerInfo = customerInfo; + } + + public Coborrowers getCoborrowers() { + return coborrowers; + } + + public void setCoborrowers(Coborrowers coborrowers) { + this.coborrowers = coborrowers; + } + + public GuarantorInfo getGuarantorInfo() { + return guarantorInfo; + } + + public void setGuarantorInfo(GuarantorInfo guarantorInfo) { + this.guarantorInfo = guarantorInfo; + } + + public ContInfo getContInfo() { + return contInfo; + } + + public void setContInfo(ContInfo contInfo) { + this.contInfo = contInfo; + } + + public ApplicationInfo getApplicationInfo() { + return applicationInfo; + } + + public void setApplicationInfo(ApplicationInfo applicationInfo) { + this.applicationInfo = applicationInfo; + } + + public PreviouslyVehicle getPreviouslyVehicle() { + return previouslyVehicle; + } + + public void setPreviouslyVehicle(PreviouslyVehicle previouslyVehicle) { + this.previouslyVehicle = previouslyVehicle; + } +} diff --git a/src/com/ample/esb/bean/amp/Application.java b/src/com/ample/esb/bean/amp/Application.java new file mode 100644 index 000000000..2b9d4f42b --- /dev/null +++ b/src/com/ample/esb/bean/amp/Application.java @@ -0,0 +1,17 @@ +package com.ample.esb.bean.amp; + + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Application { + @XStreamAlias("APPLICANT2") + private Applicant2 applicant2; + + public Applicant2 getApplicant2() { + return applicant2; + } + + public void setApplicant2(Applicant2 applicant2) { + this.applicant2 = applicant2; + } +} diff --git a/src/com/ample/esb/bean/amp/ApplicationInfo.java b/src/com/ample/esb/bean/amp/ApplicationInfo.java new file mode 100644 index 000000000..a951f92d2 --- /dev/null +++ b/src/com/ample/esb/bean/amp/ApplicationInfo.java @@ -0,0 +1,302 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class ApplicationInfo { + @XStreamAlias("NUMBER") + private String number; + + @XStreamAlias("APPLICATION_TYPE") + private String applicationType; + + @XStreamAlias("ORIGINAL_SYSTEM_ID") + private String originalSystemId; + + @XStreamAlias("TRAN_NO") + private String tranNo; + + @XStreamAlias("FIRSTPROPOSALDATE") + private String firstProposalDate; + + @XStreamAlias("LASTPROPOSALDATE") + private String lastProposalDate; + + @XStreamAlias("FANAME") + private String faName; + + @XStreamAlias("FAID") + private String faid; + + @XStreamAlias("FACELLPHONE") + private String faCellphone; + + @XStreamAlias("FVNAME") + private String fvName; + + @XStreamAlias("FVCELLPHONE") + private String fvCellphone; + + @XStreamAlias("FVDATEOFFV") + private String fvDateoffv; + + @XStreamAlias("FIELDVISITFLAG") + private String fieldVisitFlag; + + @XStreamAlias("BUSINESSSTEP") + private String businessStep; + + @XStreamAlias("GROUPCUSTOMERUPID") + private String groupCustomerUpId; + + @XStreamAlias("GROUPCUSTOMERSPECIALLIMIT") + private String groupCustomerSpecialLimit; + + @XStreamAlias("LOANVEHICLE_TYPE") + private String loanvehicleType; + + @XStreamAlias("QUERYREASON") + private String queryReason; + + @XStreamAlias("CREDITQUERYTYPE") + private String creditQueryType; + + @XStreamAlias("CREDITQUERYINTERFACE") + private String creditQueryInterface; + + @XStreamAlias("ISVEHICLEGUARANTY") + private String isVehicleGuaranty; + + @XStreamAlias("CVHEADVEHICLECOUNT") + private String cvHeadVehicleCount; + + @XStreamAlias("SOSRANDOMNUMBER") + private String sosRandomNumber; + + @XStreamAlias("APPLICATION_DATE") + private String applicationDate; + + @XStreamAlias("APPLICATION_SUBMIT_DATE") + private String applicationSubmitDate; + + @XStreamAlias("CUSTOMER_TYPE") + private String customerType; + + @XStreamAlias("STATUS_CODE") + private String statusCode; + + public String getOriginalSystemId() { + return originalSystemId; + } + + public void setOriginalSystemId(String originalSystemId) { + this.originalSystemId = originalSystemId; + } + + public String getNumber() { + return number; + } + + public void setNumber(String number) { + this.number = number; + } + + public String getApplicationType() { + return applicationType; + } + + public void setApplicationType(String applicationType) { + this.applicationType = applicationType; + } + + public String getTranNo() { + return tranNo; + } + + public void setTranNo(String tranNo) { + this.tranNo = tranNo; + } + + public String getFirstProposalDate() { + return firstProposalDate; + } + + public void setFirstProposalDate(String firstProposalDate) { + this.firstProposalDate = firstProposalDate; + } + + public String getLastProposalDate() { + return lastProposalDate; + } + + public void setLastProposalDate(String lastProposalDate) { + this.lastProposalDate = lastProposalDate; + } + + public String getFaName() { + return faName; + } + + public void setFaName(String faName) { + this.faName = faName; + } + + public String getFaid() { + return faid; + } + + public void setFaid(String faid) { + this.faid = faid; + } + + public String getFaCellphone() { + return faCellphone; + } + + public void setFaCellphone(String faCellphone) { + this.faCellphone = faCellphone; + } + + public String getFvName() { + return fvName; + } + + public void setFvName(String fvName) { + this.fvName = fvName; + } + + public String getFvCellphone() { + return fvCellphone; + } + + public void setFvCellphone(String fvCellphone) { + this.fvCellphone = fvCellphone; + } + + public String getFvDateoffv() { + return fvDateoffv; + } + + public void setFvDateoffv(String fvDateoffv) { + this.fvDateoffv = fvDateoffv; + } + + public String getFieldVisitFlag() { + return fieldVisitFlag; + } + + public void setFieldVisitFlag(String fieldVisitFlag) { + this.fieldVisitFlag = fieldVisitFlag; + } + + public String getBusinessStep() { + return businessStep; + } + + public void setBusinessStep(String businessStep) { + this.businessStep = businessStep; + } + + public String getGroupCustomerUpId() { + return groupCustomerUpId; + } + + public void setGroupCustomerUpId(String groupCustomerUpId) { + this.groupCustomerUpId = groupCustomerUpId; + } + + public String getGroupCustomerSpecialLimit() { + return groupCustomerSpecialLimit; + } + + public void setGroupCustomerSpecialLimit(String groupCustomerSpecialLimit) { + this.groupCustomerSpecialLimit = groupCustomerSpecialLimit; + } + + public String getLoanvehicleType() { + return loanvehicleType; + } + + public void setLoanvehicleType(String loanvehicleType) { + this.loanvehicleType = loanvehicleType; + } + + public String getQueryReason() { + return queryReason; + } + + public void setQueryReason(String queryReason) { + this.queryReason = queryReason; + } + + public String getCreditQueryType() { + return creditQueryType; + } + + public void setCreditQueryType(String creditQueryType) { + this.creditQueryType = creditQueryType; + } + + public String getCreditQueryInterface() { + return creditQueryInterface; + } + + public void setCreditQueryInterface(String creditQueryInterface) { + this.creditQueryInterface = creditQueryInterface; + } + + public String getIsVehicleGuaranty() { + return isVehicleGuaranty; + } + + public void setIsVehicleGuaranty(String isVehicleGuaranty) { + this.isVehicleGuaranty = isVehicleGuaranty; + } + + public String getCvHeadVehicleCount() { + return cvHeadVehicleCount; + } + + public void setCvHeadVehicleCount(String cvHeadVehicleCount) { + this.cvHeadVehicleCount = cvHeadVehicleCount; + } + + public String getSosRandomNumber() { + return sosRandomNumber; + } + + public void setSosRandomNumber(String sosRandomNumber) { + this.sosRandomNumber = sosRandomNumber; + } + + public String getApplicationDate() { + return applicationDate; + } + + public void setApplicationDate(String applicationDate) { + this.applicationDate = applicationDate; + } + + public String getApplicationSubmitDate() { + return applicationSubmitDate; + } + + public void setApplicationSubmitDate(String applicationSubmitDate) { + this.applicationSubmitDate = applicationSubmitDate; + } + + public String getCustomerType() { + return customerType; + } + + public void setCustomerType(String customerType) { + this.customerType = customerType; + } + + public String getStatusCode() { + return statusCode; + } + + public void setStatusCode(String statusCode) { + this.statusCode = statusCode; + } +} diff --git a/src/com/ample/esb/bean/amp/ApplicationTitle.java b/src/com/ample/esb/bean/amp/ApplicationTitle.java new file mode 100644 index 000000000..b6906e90a --- /dev/null +++ b/src/com/ample/esb/bean/amp/ApplicationTitle.java @@ -0,0 +1,17 @@ +package com.ample.esb.bean.amp; + + +import com.thoughtworks.xstream.annotations.XStreamAlias; +@XStreamAlias("APPLICATION") +public class ApplicationTitle { + @XStreamAlias("APPLICANT2") + private Applicant2 applicant2; + + public Applicant2 getApplicant2() { + return applicant2; + } + + public void setApplicant2(Applicant2 applicant2) { + this.applicant2 = applicant2; + } +} diff --git a/src/com/ample/esb/bean/amp/Coborrower.java b/src/com/ample/esb/bean/amp/Coborrower.java new file mode 100644 index 000000000..99b726a93 --- /dev/null +++ b/src/com/ample/esb/bean/amp/Coborrower.java @@ -0,0 +1,8 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +@XStreamAlias("COBORROWER") +public class Coborrower extends CustomerInfo{ + +} diff --git a/src/com/ample/esb/bean/amp/Coborrowers.java b/src/com/ample/esb/bean/amp/Coborrowers.java new file mode 100644 index 000000000..e0d2ecbd8 --- /dev/null +++ b/src/com/ample/esb/bean/amp/Coborrowers.java @@ -0,0 +1,18 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamImplicit; + +import java.util.List; + +public class Coborrowers { + @XStreamImplicit + private List coborrower; + + public List getCoborrower() { + return coborrower; + } + + public void setCoborrower(List coborrower) { + this.coborrower = coborrower; + } +} diff --git a/src/com/ample/esb/bean/amp/ContInfo.java b/src/com/ample/esb/bean/amp/ContInfo.java new file mode 100644 index 000000000..1a4ddc94a --- /dev/null +++ b/src/com/ample/esb/bean/amp/ContInfo.java @@ -0,0 +1,19 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamImplicit; + +import java.util.List; + + +public class ContInfo { + @XStreamImplicit + private List contrs; + + public List getContrs() { + return contrs; + } + + public void setContrs(List contrs) { + this.contrs = contrs; + } +} diff --git a/src/com/ample/esb/bean/amp/Contr.java b/src/com/ample/esb/bean/amp/Contr.java new file mode 100644 index 000000000..a0701bc57 --- /dev/null +++ b/src/com/ample/esb/bean/amp/Contr.java @@ -0,0 +1,62 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +@XStreamAlias("CONTR") +public class Contr { + + @XStreamAlias("CONTNUM") + private String contNum; + + @XStreamAlias("RELATIONSHIPCODE") + private String relationshipCode; + + @XStreamAlias("CHNAME") + private String chName; + + @XStreamAlias("CELLPHONE") + private String cellPhone; + + @XStreamAlias("MOBILE") + private String mobile; + + public String getContNum() { + return contNum; + } + + public void setContNum(String contNum) { + this.contNum = contNum; + } + + public String getCellPhone() { + return cellPhone; + } + + public void setCellPhone(String cellPhone) { + this.cellPhone = cellPhone; + } + + public String getRelationshipCode() { + return relationshipCode; + } + + public void setRelationshipCode(String relationshipCode) { + this.relationshipCode = relationshipCode; + } + + public String getChName() { + return chName; + } + + public void setChName(String chName) { + this.chName = chName; + } + + public String getMobile() { + return mobile; + } + + public void setMobile(String mobile) { + this.mobile = mobile; + } +} diff --git a/src/com/ample/esb/bean/amp/CustomerInfo.java b/src/com/ample/esb/bean/amp/CustomerInfo.java new file mode 100644 index 000000000..90a94a240 --- /dev/null +++ b/src/com/ample/esb/bean/amp/CustomerInfo.java @@ -0,0 +1,908 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class CustomerInfo { + @XStreamAlias("CHNAME") + private String chName; + + @XStreamAlias("IDTYPECODE") + private String idTypeCode; + + @XStreamAlias("IDCARDNUM") + private String idCardNum; + + @XStreamAlias("AGE_IN_YEAR") + private Integer ageInYear; + + @XStreamAlias("GENDERCODE") + private String genderCode; + + @XStreamAlias("MARITALSTATUSCODE") + private String maritalStatusCode; + + @XStreamAlias("EDUCATIONCODE") + private String educationCode; + + @XStreamAlias("RESIDENTIALSTATUSCODE") + private String residentialStatusCode; + + @XStreamAlias("MONTHLYINCOME") + private String monthlyIncome; + + @XStreamAlias("ANNUALINCOME") + private String annualIncome; + + @XStreamAlias("MONTHLYDTI") + private String monthlyDTI; + + @XStreamAlias("NOOFDEPENDENTS") + private String noOfDependents; + + @XStreamAlias("EMPEMPLOYERNAME") + private String empemployerName; + + @XStreamAlias("EMPBUSINESSTYPECODE") + private String empBusinessTypeCode; + + @XStreamAlias("EMPOCCUPATIONCODE") + private String empOccupationCode; + + @XStreamAlias("EMPPOSITIONCODE") + private String empPositionCode; + + @XStreamAlias("EMPPROFESSIONALRANK") + private String empProfessionalRank; + + @XStreamAlias("WORKSINCE") + private String workSince; + + @XStreamAlias("EMPTIMEOFEMPLOYEE") + private String empTimeOfEmployee; + + @XStreamAlias("PHONECELLPHONE01") + private String phoneCellphone01; + + @XStreamAlias("PHONECELLPHONE02") + private String phoneCellphone02; + + @XStreamAlias("PHONEHOME") + private String phoneHome; + + @XStreamAlias("PHONEOFFICE") + private String phoneOffice; + + @XStreamAlias("BANKSTATEMENTSTATUSCODE") + private String bankStatementStatusCode; + + @XStreamAlias("LOCALRESIDENTFLAG") + private String localResidentFlag; + + @XStreamAlias("LOCALAPPLICANTFLAG") + private String localApplicantFlag; + + @XStreamAlias("VIPCUST") + private String vipCust; + + @XStreamAlias("REPEATEDAPPLICANTTFLAG") + private Integer repeatedApplicantFlag; + + @XStreamAlias("HUKOUTYPE") + private String hukouType; + + @XStreamAlias("HIGHESTEDUCATION") + private String highestEducation; + + @XStreamAlias("HIGHESTDEGREE") + private String highestDegree; + + @XStreamAlias("OFFICEPOSTCODE") + private String officePostCode; + + @XStreamAlias("CURRENTOFFICEENTRYDATE") + private String currentOfficeEntryDate; + + @XStreamAlias("PHSNUMBER") + private String phsNumber; + + @XStreamAlias("EMAIL") + private String email; + + @XStreamAlias("HASDRIVINGLICENCE") + private String hasDrivingLicence; + + @XStreamAlias("ALLOWDRIVINGTYPE") + private String allowDrivingType; + + @XStreamAlias("CHECKED_TYPE") + private String checkedType; + + @XStreamAlias("LOANCARDNUMBER") + private String loanCardNumber; + + @XStreamAlias("LOANCARDPASSWORD") + private String loanCardPassword; + + @XStreamAlias("ARCHIVEURL") + private String archiveUrl; + + @XStreamAlias("AGE_IN_MONTH") + private Integer ageInMonth; + + @XStreamAlias("CHILDREN_FLAG") + private String childrenFlag; + + @XStreamAlias("BLACKLIST_IND") + private String blacklistInd; + + @XStreamAlias("THAI_TITLE_CDE") + private String thaiTitleCde; + + @XStreamAlias("EXPENSE") + private String expense; + + @XStreamAlias("BRITHDAY") + private String brithday; + + @XStreamAlias("LICENSE_EXPIRE_DATE") + private String licenseExpireDate; + + @XStreamAlias("COUNTRY_CODE") + private String countryCode; + + @XStreamAlias("AREA_CODE") + private String areaCode; + + @XStreamAlias("EXTENTION_NBR") + private String extentionNbr; + + @XStreamAlias("PHONE_TYPE_CDE") + private String phoneTypeCde; + + @XStreamAlias("DESIGNATION_CDE") + private String designationCde; + + @XStreamAlias("CITY_CDE") + private String cityCde; + + @XStreamAlias("STATE_CDE") + private String stateCde; + + @XStreamAlias("PROVINCE_GB") + private String provinceGB; + + @XStreamAlias("CITY_GB") + private String cityGB; + + @XStreamAlias("DISTRICT_GB") + private String districtGB; + + @XStreamAlias("STREET_GB") + private String streetGB; + + @XStreamAlias("BUSINESS_NATURE_CDE") + private String businessNatureCde; + + @XStreamAlias("POST_CODE") + private String postCode; + + @XStreamAlias("EMPLOY_ADDRESS") + private String employAddress; + + @XStreamAlias("OCCUPATION_CODE") + private String occupationCode; + + @XStreamAlias("BUSINESS_TYPE_CDE") + private String businessTypeCde; + + @XStreamAlias("TIME_IN_YEAR_2") + private String timeInYear2; + + @XStreamAlias("RANK_CDE") + private String rankCde; + + @XStreamAlias("OCCUPATION_CDE") + private String occupationCde; + + @XStreamAlias("INDUSTRY_TYPE_CDE") + private String industryTypeCde; + + @XStreamAlias("ADDR") + private Addr addr; + + @XStreamAlias("EXPOSURE") + private Exposure exposure; + + @XStreamAlias("ID_CARD_TERM_BEGIN_DATE") + private String idCardTermBeginDate; + + @XStreamAlias("ID_CARD_TERM_END_DATE") + private String idCardTermEndDate; + + @XStreamAlias("RELATIONSHIPCODE") + private String relationshipCode; + + @XStreamAlias("OPEN_BANK_MOBILE_NO") + private String openBankMobileNo; + + @XStreamAlias("CUST_TYPE_ID") + private String custTypeId; + + @XStreamAlias("NATION_ID") + private String nationId; + + @XStreamAlias("CENSUS_REG_ADDR") + private String censusRegAddr; + + @XStreamAlias("TEL_WORK_NO") + private String telWorkNo; + + @XStreamAlias("BORROWERID") + private String borrowerId; + + @XStreamAlias("GUARNUM") + private String guarNum; + + @XStreamAlias("QUERYREASON") + private String queryReason; + + public void setAgeInYear(Integer ageInYear) { + this.ageInYear = ageInYear; + } + + public void setRepeatedApplicantFlag(Integer repeatedApplicantFlag) { + this.repeatedApplicantFlag = repeatedApplicantFlag; + } + + public void setAgeInMonth(Integer ageInMonth) { + this.ageInMonth = ageInMonth; + } + + public String getQueryReason() { + return queryReason; + } + + public void setQueryReason(String queryReason) { + this.queryReason = queryReason; + } + + public String getGuarNum() { + return guarNum; + } + + public void setGuarNum(String guarNum) { + this.guarNum = guarNum; + } + + public String getBorrowerId() { + return borrowerId; + } + + public void setBorrowerId(String borrowerId) { + this.borrowerId = borrowerId; + } + + public String getTelWorkNo() { + return telWorkNo; + } + + public void setTelWorkNo(String telWorkNo) { + this.telWorkNo = telWorkNo; + } + + public String getCensusRegAddr() { + return censusRegAddr; + } + + public void setCensusRegAddr(String censusRegAddr) { + this.censusRegAddr = censusRegAddr; + } + + public String getNationId() { + return nationId; + } + + public void setNationId(String nationId) { + this.nationId = nationId; + } + + public String getCustTypeId() { + return custTypeId; + } + + public void setCustTypeId(String custTypeId) { + this.custTypeId = custTypeId; + } + + public String getOpenBankMobileNo() { + return openBankMobileNo; + } + + public void setOpenBankMobileNo(String openBankMobileNo) { + this.openBankMobileNo = openBankMobileNo; + } + + public String getRelationshipCode() { + return relationshipCode; + } + + public void setRelationshipCode(String relationshipCode) { + this.relationshipCode = relationshipCode; + } + + public String getChName() { + return chName; + } + + public void setChName(String chName) { + this.chName = chName; + } + + public String getIdTypeCode() { + return idTypeCode; + } + + public void setIdTypeCode(String idTypeCode) { + this.idTypeCode = idTypeCode; + } + + public String getIdCardNum() { + return idCardNum; + } + + public void setIdCardNum(String idCardNum) { + this.idCardNum = idCardNum; + } + + public int getAgeInYear() { + return ageInYear; + } + + public void setAgeInYear(int ageInYear) { + this.ageInYear = ageInYear; + } + + public String getGenderCode() { + return genderCode; + } + + public void setGenderCode(String genderCode) { + this.genderCode = genderCode; + } + + public String getMaritalStatusCode() { + return maritalStatusCode; + } + + public void setMaritalStatusCode(String maritalStatusCode) { + this.maritalStatusCode = maritalStatusCode; + } + + public String getEducationCode() { + return educationCode; + } + + public void setEducationCode(String educationCode) { + this.educationCode = educationCode; + } + + public String getResidentialStatusCode() { + return residentialStatusCode; + } + + public void setResidentialStatusCode(String residentialStatusCode) { + this.residentialStatusCode = residentialStatusCode; + } + + public String getMonthlyIncome() { + return monthlyIncome; + } + + public void setMonthlyIncome(String monthlyIncome) { + this.monthlyIncome = monthlyIncome; + } + + public String getAnnualIncome() { + return annualIncome; + } + + public void setAnnualIncome(String annualIncome) { + this.annualIncome = annualIncome; + } + + public String getMonthlyDTI() { + return monthlyDTI; + } + + public void setMonthlyDTI(String monthlyDTI) { + this.monthlyDTI = monthlyDTI; + } + + public String getNoOfDependents() { + return noOfDependents; + } + + public void setNoOfDependents(String noOfDependents) { + this.noOfDependents = noOfDependents; + } + + public String getEmpemployerName() { + return empemployerName; + } + + public void setEmpemployerName(String empemployerName) { + this.empemployerName = empemployerName; + } + + public String getEmpBusinessTypeCode() { + return empBusinessTypeCode; + } + + public void setEmpBusinessTypeCode(String empBusinessTypeCode) { + this.empBusinessTypeCode = empBusinessTypeCode; + } + + public String getEmpOccupationCode() { + return empOccupationCode; + } + + public void setEmpOccupationCode(String empOccupationCode) { + this.empOccupationCode = empOccupationCode; + } + + public String getEmpPositionCode() { + return empPositionCode; + } + + public void setEmpPositionCode(String empPositionCode) { + this.empPositionCode = empPositionCode; + } + + public String getEmpProfessionalRank() { + return empProfessionalRank; + } + + public void setEmpProfessionalRank(String empProfessionalRank) { + this.empProfessionalRank = empProfessionalRank; + } + + public String getWorkSince() { + return workSince; + } + + public void setWorkSince(String workSince) { + this.workSince = workSince; + } + + public String getEmpTimeOfEmployee() { + return empTimeOfEmployee; + } + + public void setEmpTimeOfEmployee(String empTimeOfEmployee) { + this.empTimeOfEmployee = empTimeOfEmployee; + } + + public String getPhoneCellphone01() { + return phoneCellphone01; + } + + public void setPhoneCellphone01(String phoneCellphone01) { + this.phoneCellphone01 = phoneCellphone01; + } + + public String getPhoneCellphone02() { + return phoneCellphone02; + } + + public void setPhoneCellphone02(String phoneCellphone02) { + this.phoneCellphone02 = phoneCellphone02; + } + + public String getPhoneHome() { + return phoneHome; + } + + public void setPhoneHome(String phoneHome) { + this.phoneHome = phoneHome; + } + + public String getPhoneOffice() { + return phoneOffice; + } + + public void setPhoneOffice(String phoneOffice) { + this.phoneOffice = phoneOffice; + } + + public String getBankStatementStatusCode() { + return bankStatementStatusCode; + } + + public void setBankStatementStatusCode(String bankStatementStatusCode) { + this.bankStatementStatusCode = bankStatementStatusCode; + } + + public String getLocalResidentFlag() { + return localResidentFlag; + } + + public void setLocalResidentFlag(String localResidentFlag) { + this.localResidentFlag = localResidentFlag; + } + + public String getLocalApplicantFlag() { + return localApplicantFlag; + } + + public void setLocalApplicantFlag(String localApplicantFlag) { + this.localApplicantFlag = localApplicantFlag; + } + + public String getVipCust() { + return vipCust; + } + + public void setVipCust(String vipCust) { + this.vipCust = vipCust; + } + + public int getRepeatedApplicantFlag() { + return repeatedApplicantFlag; + } + + public void setRepeatedApplicantFlag(int repeatedApplicantFlag) { + this.repeatedApplicantFlag = repeatedApplicantFlag; + } + + public String getHukouType() { + return hukouType; + } + + public void setHukouType(String hukouType) { + this.hukouType = hukouType; + } + + public String getHighestEducation() { + return highestEducation; + } + + public void setHighestEducation(String highestEducation) { + this.highestEducation = highestEducation; + } + + public String getHighestDegree() { + return highestDegree; + } + + public void setHighestDegree(String highestDegree) { + this.highestDegree = highestDegree; + } + + public String getOfficePostCode() { + return officePostCode; + } + + public void setOfficePostCode(String officePostCode) { + this.officePostCode = officePostCode; + } + + public String getCurrentOfficeEntryDate() { + return currentOfficeEntryDate; + } + + public void setCurrentOfficeEntryDate(String currentOfficeEntryDate) { + this.currentOfficeEntryDate = currentOfficeEntryDate; + } + + public String getPhsNumber() { + return phsNumber; + } + + public void setPhsNumber(String phsNumber) { + this.phsNumber = phsNumber; + } + + public String getEmail() { + return email; + } + + public void setEmail(String email) { + this.email = email; + } + + public String getHasDrivingLicence() { + return hasDrivingLicence; + } + + public void setHasDrivingLicence(String hasDrivingLicence) { + this.hasDrivingLicence = hasDrivingLicence; + } + + public String getAllowDrivingType() { + return allowDrivingType; + } + + public void setAllowDrivingType(String allowDrivingType) { + this.allowDrivingType = allowDrivingType; + } + + public String getCheckedType() { + return checkedType; + } + + public void setCheckedType(String checkedType) { + this.checkedType = checkedType; + } + + public String getLoanCardNumber() { + return loanCardNumber; + } + + public void setLoanCardNumber(String loanCardNumber) { + this.loanCardNumber = loanCardNumber; + } + + public String getLoanCardPassword() { + return loanCardPassword; + } + + public void setLoanCardPassword(String loanCardPassword) { + this.loanCardPassword = loanCardPassword; + } + + public String getArchiveUrl() { + return archiveUrl; + } + + public void setArchiveUrl(String archiveUrl) { + this.archiveUrl = archiveUrl; + } + + public int getAgeInMonth() { + return ageInMonth; + } + + public void setAgeInMonth(int ageInMonth) { + this.ageInMonth = ageInMonth; + } + + public String getChildrenFlag() { + return childrenFlag; + } + + public void setChildrenFlag(String childrenFlag) { + this.childrenFlag = childrenFlag; + } + + public String getBlacklistInd() { + return blacklistInd; + } + + public void setBlacklistInd(String blacklistInd) { + this.blacklistInd = blacklistInd; + } + + public String getThaiTitleCde() { + return thaiTitleCde; + } + + public void setThaiTitleCde(String thaiTitleCde) { + this.thaiTitleCde = thaiTitleCde; + } + + public String getExpense() { + return expense; + } + + public void setExpense(String expense) { + this.expense = expense; + } + + public String getBrithday() { + return brithday; + } + + public void setBrithday(String brithday) { + this.brithday = brithday; + } + + public String getLicenseExpireDate() { + return licenseExpireDate; + } + + public void setLicenseExpireDate(String licenseExpireDate) { + this.licenseExpireDate = licenseExpireDate; + } + + public String getCountryCode() { + return countryCode; + } + + public void setCountryCode(String countryCode) { + this.countryCode = countryCode; + } + + public String getAreaCode() { + return areaCode; + } + + public void setAreaCode(String areaCode) { + this.areaCode = areaCode; + } + + public String getExtentionNbr() { + return extentionNbr; + } + + public void setExtentionNbr(String extentionNbr) { + this.extentionNbr = extentionNbr; + } + + public String getPhoneTypeCde() { + return phoneTypeCde; + } + + public void setPhoneTypeCde(String phoneTypeCde) { + this.phoneTypeCde = phoneTypeCde; + } + + public String getDesignationCde() { + return designationCde; + } + + public void setDesignationCde(String designationCde) { + this.designationCde = designationCde; + } + + public String getCityCde() { + return cityCde; + } + + public void setCityCde(String cityCde) { + this.cityCde = cityCde; + } + + public String getStateCde() { + return stateCde; + } + + public void setStateCde(String stateCde) { + this.stateCde = stateCde; + } + + public String getProvinceGB() { + return provinceGB; + } + + public void setProvinceGB(String provinceGB) { + this.provinceGB = provinceGB; + } + + public String getCityGB() { + return cityGB; + } + + public void setCityGB(String cityGB) { + this.cityGB = cityGB; + } + + public String getDistrictGB() { + return districtGB; + } + + public void setDistrictGB(String districtGB) { + this.districtGB = districtGB; + } + + public String getStreetGB() { + return streetGB; + } + + public void setStreetGB(String streetGB) { + this.streetGB = streetGB; + } + + public String getBusinessNatureCde() { + return businessNatureCde; + } + + public void setBusinessNatureCde(String businessNatureCde) { + this.businessNatureCde = businessNatureCde; + } + + public String getPostCode() { + return postCode; + } + + public void setPostCode(String postCode) { + this.postCode = postCode; + } + + public String getEmployAddress() { + return employAddress; + } + + public void setEmployAddress(String employAddress) { + this.employAddress = employAddress; + } + + public String getOccupationCode() { + return occupationCode; + } + + public void setOccupationCode(String occupationCode) { + this.occupationCode = occupationCode; + } + + public String getBusinessTypeCde() { + return businessTypeCde; + } + + public void setBusinessTypeCde(String businessTypeCde) { + this.businessTypeCde = businessTypeCde; + } + + public String getTimeInYear2() { + return timeInYear2; + } + + public void setTimeInYear2(String timeInYear2) { + this.timeInYear2 = timeInYear2; + } + + public String getRankCde() { + return rankCde; + } + + public void setRankCde(String rankCde) { + this.rankCde = rankCde; + } + + public String getOccupationCde() { + return occupationCde; + } + + public void setOccupationCde(String occupationCde) { + this.occupationCde = occupationCde; + } + + public String getIndustryTypeCde() { + return industryTypeCde; + } + + public void setIndustryTypeCde(String industryTypeCde) { + this.industryTypeCde = industryTypeCde; + } + + public Addr getAddr() { + return addr; + } + + public void setAddr(Addr addr) { + this.addr = addr; + } + + public Exposure getExposure() { + return exposure; + } + + public void setExposure(Exposure exposure) { + this.exposure = exposure; + } + + public String getIdCardTermBeginDate() { + return idCardTermBeginDate; + } + + public void setIdCardTermBeginDate(String idCardTermBeginDate) { + this.idCardTermBeginDate = idCardTermBeginDate; + } + + public String getIdCardTermEndDate() { + return idCardTermEndDate; + } + + public void setIdCardTermEndDate(String idCardTermEndDate) { + this.idCardTermEndDate = idCardTermEndDate; + } +} diff --git a/src/com/ample/esb/bean/amp/DealerInfo.java b/src/com/ample/esb/bean/amp/DealerInfo.java new file mode 100644 index 000000000..ea7503187 --- /dev/null +++ b/src/com/ample/esb/bean/amp/DealerInfo.java @@ -0,0 +1,258 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class DealerInfo { + @XStreamAlias("DEALERNAME") + private String dealerName; + + @XStreamAlias("DEALERID") + private String dealerId; + + @XStreamAlias("DEALERMODE") + private String dealerMode; + + @XStreamAlias("DEALERPROVINCE") + private String dealerProvince; + + @XStreamAlias("DEALERCITY") + private String dealerCity; + + @XStreamAlias("DEALERPROVINCE_GB") + private String dealerProvince_gb; + + @XStreamAlias("DEALERCITY_GB") + private String dealerCity_gb; + + @XStreamAlias("DEALERDISTRICT_GB") + private String dealerDistrict_gb; + + @XStreamAlias("DEALERSTREET_GB") + private String dealerStreet_gb; + + @XStreamAlias("SUBDEALERNAME") + private String subDealerName; + + @XStreamAlias("DEALERGUARANTEERATIO") + private String dealerGuaranteeRatio; + + @XStreamAlias("DEALERFILEDVISITFLAG") + private String dealerFiledVisitFlag; + + @XStreamAlias("SUBDEALERAPPFLAG") + private String subDealerAppFlag; + + @XStreamAlias("DEALERAREA") + private String dealerArea; + + @XStreamAlias("SUBDEALERCODE") + private String subDealerCode; + + @XStreamAlias("DEALERTOTALUSEDAMOUNT") + private String dealerTotalUsedAmount; + + @XStreamAlias("DEALERAVAILABLEAMOUNT") + private String dealerAvailableAmount; + + @XStreamAlias("APPROVALCOUNTTHISMONTH") + private int approvalCountThisMonth; + + @XStreamAlias("REFUSECOUNTTHISMONTH") + private int refuseCountThisMonth; + + @XStreamAlias("LOANCOUNTTHISMONTH") + private int loanCountThisMonth; + + @XStreamAlias("APPROVALCOUNTTHISYEAR") + private int approvalCountThisYear; + + @XStreamAlias("REFUSECOUNTTHISYEAR") + private int refuseCountThisYear; + + @XStreamAlias("LOANCOUNTTHISYEAR") + private int loanCountThisYear; + + public String getDealerName() { + return dealerName; + } + + public void setDealerName(String dealerName) { + this.dealerName = dealerName; + } + + public String getDealerId() { + return dealerId; + } + + public void setDealerId(String dealerId) { + this.dealerId = dealerId; + } + + public String getDealerMode() { + return dealerMode; + } + + public void setDealerMode(String dealerMode) { + this.dealerMode = dealerMode; + } + + public String getDealerProvince() { + return dealerProvince; + } + + public void setDealerProvince(String dealerProvince) { + this.dealerProvince = dealerProvince; + } + + public String getDealerCity() { + return dealerCity; + } + + public void setDealerCity(String dealerCity) { + this.dealerCity = dealerCity; + } + + public String getDealerProvince_gb() { + return dealerProvince_gb; + } + + public void setDealerProvince_gb(String dealerProvince_gb) { + this.dealerProvince_gb = dealerProvince_gb; + } + + public String getDealerCity_gb() { + return dealerCity_gb; + } + + public void setDealerCity_gb(String dealerCity_gb) { + this.dealerCity_gb = dealerCity_gb; + } + + public String getDealerDistrict_gb() { + return dealerDistrict_gb; + } + + public void setDealerDistrict_gb(String dealerDistrict_gb) { + this.dealerDistrict_gb = dealerDistrict_gb; + } + + public String getDealerStreet_gb() { + return dealerStreet_gb; + } + + public void setDealerStreet_gb(String dealerStreet_gb) { + this.dealerStreet_gb = dealerStreet_gb; + } + + public String getSubDealerName() { + return subDealerName; + } + + public void setSubDealerName(String subDealerName) { + this.subDealerName = subDealerName; + } + + public String getDealerGuaranteeRatio() { + return dealerGuaranteeRatio; + } + + public void setDealerGuaranteeRatio(String dealerGuaranteeRatio) { + this.dealerGuaranteeRatio = dealerGuaranteeRatio; + } + + public String getDealerFiledVisitFlag() { + return dealerFiledVisitFlag; + } + + public void setDealerFiledVisitFlag(String dealerFiledVisitFlag) { + this.dealerFiledVisitFlag = dealerFiledVisitFlag; + } + + public String getSubDealerAppFlag() { + return subDealerAppFlag; + } + + public void setSubDealerAppFlag(String subDealerAppFlag) { + this.subDealerAppFlag = subDealerAppFlag; + } + + public String getDealerArea() { + return dealerArea; + } + + public void setDealerArea(String dealerArea) { + this.dealerArea = dealerArea; + } + + public String getSubDealerCode() { + return subDealerCode; + } + + public void setSubDealerCode(String subDealerCode) { + this.subDealerCode = subDealerCode; + } + + public String getDealerTotalUsedAmount() { + return dealerTotalUsedAmount; + } + + public void setDealerTotalUsedAmount(String dealerTotalUsedAmount) { + this.dealerTotalUsedAmount = dealerTotalUsedAmount; + } + + public String getDealerAvailableAmount() { + return dealerAvailableAmount; + } + + public void setDealerAvailableAmount(String dealerAvailableAmount) { + this.dealerAvailableAmount = dealerAvailableAmount; + } + + public int getApprovalCountThisMonth() { + return approvalCountThisMonth; + } + + public void setApprovalCountThisMonth(int approvalCountThisMonth) { + this.approvalCountThisMonth = approvalCountThisMonth; + } + + public int getRefuseCountThisMonth() { + return refuseCountThisMonth; + } + + public void setRefuseCountThisMonth(int refuseCountThisMonth) { + this.refuseCountThisMonth = refuseCountThisMonth; + } + + public int getLoanCountThisMonth() { + return loanCountThisMonth; + } + + public void setLoanCountThisMonth(int loanCountThisMonth) { + this.loanCountThisMonth = loanCountThisMonth; + } + + public int getApprovalCountThisYear() { + return approvalCountThisYear; + } + + public void setApprovalCountThisYear(int approvalCountThisYear) { + this.approvalCountThisYear = approvalCountThisYear; + } + + public int getRefuseCountThisYear() { + return refuseCountThisYear; + } + + public void setRefuseCountThisYear(int refuseCountThisYear) { + this.refuseCountThisYear = refuseCountThisYear; + } + + public int getLoanCountThisYear() { + return loanCountThisYear; + } + + public void setLoanCountThisYear(int loanCountThisYear) { + this.loanCountThisYear = loanCountThisYear; + } +} diff --git a/src/com/ample/esb/bean/amp/Exposure.java b/src/com/ample/esb/bean/amp/Exposure.java new file mode 100644 index 000000000..c838172ec --- /dev/null +++ b/src/com/ample/esb/bean/amp/Exposure.java @@ -0,0 +1,49 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Exposure { + @XStreamAlias("OUTSTANDING") + private String outstanding; + + @XStreamAlias("APPROVAL_AMT") + private String approvalAmt; + + @XStreamAlias("OS_NUM") + private int osNum; + + @XStreamAlias("APPROVAL_NUM") + private int approvalNum; + + public String getOutstanding() { + return outstanding; + } + + public void setOutstanding(String outstanding) { + this.outstanding = outstanding; + } + + public String getApprovalAmt() { + return approvalAmt; + } + + public void setApprovalAmt(String approvalAmt) { + this.approvalAmt = approvalAmt; + } + + public int getOsNum() { + return osNum; + } + + public void setOsNum(int osNum) { + this.osNum = osNum; + } + + public int getApprovalNum() { + return approvalNum; + } + + public void setApprovalNum(int approvalNum) { + this.approvalNum = approvalNum; + } +} diff --git a/src/com/ample/esb/bean/amp/Guar.java b/src/com/ample/esb/bean/amp/Guar.java new file mode 100644 index 000000000..ce96af8c3 --- /dev/null +++ b/src/com/ample/esb/bean/amp/Guar.java @@ -0,0 +1,8 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +@XStreamAlias("GUAR") +public class Guar extends CustomerInfo{ + +} diff --git a/src/com/ample/esb/bean/amp/GuarantorInfo.java b/src/com/ample/esb/bean/amp/GuarantorInfo.java new file mode 100644 index 000000000..87849851a --- /dev/null +++ b/src/com/ample/esb/bean/amp/GuarantorInfo.java @@ -0,0 +1,18 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamImplicit; + +import java.util.List; + +public class GuarantorInfo { + @XStreamImplicit + private List Guars; + + public List getGuars() { + return Guars; + } + + public void setGuars(List guars) { + Guars = guars; + } +} diff --git a/src/com/ample/esb/bean/amp/LoanInfo.java b/src/com/ample/esb/bean/amp/LoanInfo.java new file mode 100644 index 000000000..1bc7130ca --- /dev/null +++ b/src/com/ample/esb/bean/amp/LoanInfo.java @@ -0,0 +1,644 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class LoanInfo { + @XStreamAlias("PRODUCTID") + private String productId; + + @XStreamAlias("PRODUCTNAME") + private String productName; + + @XStreamAlias("PRODUCTTYPE") + private String productType; + + @XStreamAlias("SUBSITYTYPECODE") + private String subsityTypeCode; + + @XStreamAlias("INTERESTRATE") + private String interestRate; + + @XStreamAlias("DOWNPAYMENTPERCENTAGE") + private String downPaymentPercentage; + + @XStreamAlias("DOWNPAYMENTBYFINANCEPERCENTAGE") + private String downPaymentByFinancePercentage; + + @XStreamAlias("DOWNPAYMENTTOTALAMOUNT") + private String downPaymentTotalAmount; + + @XStreamAlias("FINANCEAMOUNTUNIT") + private String financeAmountUnit; + + @XStreamAlias("FINANCEAMOUNTTOTAL") + private String financeAmountTotal; + + @XStreamAlias("TERMS") + private String terms; + + @XStreamAlias("INSTALLMENTUNIT") + private String installmentUnit; + + @XStreamAlias("INSTALLMENTTOTAL") + private double installmentTotal; + + @XStreamAlias("INTERESTUNIT") + private String interestUnit; + + @XStreamAlias("INTERESTTOTAL") + private Double interestTotal; + + @XStreamAlias("CUSTINTERESTUNIT") + private String custInterestUnit; + + @XStreamAlias("CUSTINTERESTTOTAL") + private double custInterestTotal; + + @XStreamAlias("CUSTINTERESTTOTALDEPOSIT") + private String custInterestTotalDeposit; + + @XStreamAlias("DEALERINTERESTUNIT") + private String dealerInterestUnit; + + @XStreamAlias("DEALERINTERESTTOTAL") + private String dealerInterestTotal; + + @XStreamAlias("DEALERINTERESTTOTALDEPOSIT") + private String dealerInterestTotalDeposit; + + @XStreamAlias("MAKERINTERESTUNIT") + private String makerInterestUnit; + + @XStreamAlias("MAKERINTERESTTOTAL") + private double makerInterestTotal; + + @XStreamAlias("MAKERINTERESTTOTALDEPOSIT") + private String makerInterestTotalDeposit; + + @XStreamAlias("ISSUBSITY") + private String isSubsity; + + @XStreamAlias("CONTRACTPRICETOTAL") + private String contractPriceTotal; + + @XStreamAlias("MONTHINTERESTRATE") + private String monthInterestRate; + + @XStreamAlias("PAYTYPE") + private String payType; + + @XStreamAlias("PAYREMARK") + private String payRemark; + + @XStreamAlias("ISLINKED") + private String isLinked; + + @XStreamAlias("LINKEDCOMPANY") + private String linkedCompany; + + @XStreamAlias("LINKEDCOMPANYTYPE") + private String linkedCompanyType; + + @XStreamAlias("RESERVESTRING1") + private String reserveString1; + + @XStreamAlias("RESERVESTRING2") + private String reserveString2; + + @XStreamAlias("RESERVESTRING3") + private String reserveString3; + + @XStreamAlias("RESERVESTRING4") + private String reserveString4; + + @XStreamAlias("RESERVESTRING5") + private String reserveString5; + + @XStreamAlias("ASSET_PURPOSE") + private String assetPurpose; + + @XStreamAlias("BALLOON_PERCENTAGE") + private String balloonPercentage; + + @XStreamAlias("BALLOON_AMOUNT") + private String balloonAmount; + + @XStreamAlias("FINANCED_AMT_PCT") + private String financedAmtPct; + + @XStreamAlias("RENTAL_CALCULATION_MTD") + private String rentalCalculationMtd; + + @XStreamAlias("BASE_CUSTOMER_RATE") + private String baseCustomerRate; + + @XStreamAlias("SUBSIDY_RTE") + private String subsidyRte; + + @XStreamAlias("CALC_SUBSIDY_RTE") + private String calcSubsidyRte; + + @XStreamAlias("CALC_SUBSIDY_AMT") + private String calcSubsidyAmt; + + @XStreamAlias("ACTUAL_RTE") + private String actualRte; + + @XStreamAlias("PAYMENT_SCHEME") + private String paymentScheme; + + @XStreamAlias("DEALER_SUBSIDY_PCT") + private String dealerSubsidyPct; + + @XStreamAlias("MANUFACTURER_SUBSIDY_PCT") + private String manufacturerSubsidyPct; + + @XStreamAlias("CALC_DEALER_SUBSIDY_AMT") + private double calcDealerSubsidyAmt; + + @XStreamAlias("CALC_MANUFACTURER_SUBSIDY_AMT") + private double calcManufacturerSubsidyAmt; + + @XStreamAlias("CAR_COUNT") + private int carCount; + + @XStreamAlias("EXPOSURES_NUMBER") + private int exposuresNumber; + + @XStreamAlias("EXPOSURE_AMOUNT") + private String exposureAmount; + + @XStreamAlias("CAR_REAL_DOWN_PAYMENT_RATIO") + private String carRealDownPaymentRatio; + + @XStreamAlias("CAR_REAL_DOWN_PAYMENT_AMT") + private String carRealDownPaymentAmt; + + @XStreamAlias("FINANCING_RATIO") + private double financingRatio; + + public String getCarRealDownPaymentRatio() { + return carRealDownPaymentRatio; + } + + public void setCarRealDownPaymentRatio(String carRealDownPaymentRatio) { + this.carRealDownPaymentRatio = carRealDownPaymentRatio; + } + + public String getCarRealDownPaymentAmt() { + return carRealDownPaymentAmt; + } + + public void setCarRealDownPaymentAmt(String carRealDownPaymentAmt) { + this.carRealDownPaymentAmt = carRealDownPaymentAmt; + } + + public double getFinancingRatio() { + return financingRatio; + } + + public void setFinancingRatio(double financingRatio) { + this.financingRatio = financingRatio; + } + + public int getCarCount() { + return carCount; + } + + public void setCarCount(int carCount) { + this.carCount = carCount; + } + + public int getExposuresNumber() { + return exposuresNumber; + } + + public void setExposuresNumber(int exposuresNumber) { + this.exposuresNumber = exposuresNumber; + } + + public String getExposureAmount() { + return exposureAmount; + } + + public void setExposureAmount(String exposureAmount) { + this.exposureAmount = exposureAmount; + } + + public String getProductId() { + return productId; + } + + public void setProductId(String productId) { + this.productId = productId; + } + + public String getProductName() { + return productName; + } + + public void setProductName(String productName) { + this.productName = productName; + } + + public String getProductType() { + return productType; + } + + public void setProductType(String productType) { + this.productType = productType; + } + + public String getSubsityTypeCode() { + return subsityTypeCode; + } + + public void setSubsityTypeCode(String subsityTypeCode) { + this.subsityTypeCode = subsityTypeCode; + } + + public String getInterestRate() { + return interestRate; + } + + public void setInterestRate(String interestRate) { + this.interestRate = interestRate; + } + + public String getDownPaymentPercentage() { + return downPaymentPercentage; + } + + public void setDownPaymentPercentage(String downPaymentPercentage) { + this.downPaymentPercentage = downPaymentPercentage; + } + + public String getDownPaymentTotalAmount() { + return downPaymentTotalAmount; + } + + public void setDownPaymentTotalAmount(String downPaymentTotalAmount) { + this.downPaymentTotalAmount = downPaymentTotalAmount; + } + + public String getFinanceAmountUnit() { + return financeAmountUnit; + } + + public void setFinanceAmountUnit(String financeAmountUnit) { + this.financeAmountUnit = financeAmountUnit; + } + + public String getFinanceAmountTotal() { + return financeAmountTotal; + } + + public void setFinanceAmountTotal(String financeAmountTotal) { + this.financeAmountTotal = financeAmountTotal; + } + + public String getTerms() { + return terms; + } + + public void setTerms(String terms) { + this.terms = terms; + } + + public String getInstallmentUnit() { + return installmentUnit; + } + + public void setInstallmentUnit(String installmentUnit) { + this.installmentUnit = installmentUnit; + } + + public double getInstallmentTotal() { + return installmentTotal; + } + + public void setInstallmentTotal(double installmentTotal) { + this.installmentTotal = installmentTotal; + } + + public String getInterestUnit() { + return interestUnit; + } + + public void setInterestUnit(String interestUnit) { + this.interestUnit = interestUnit; + } + + public Double getInterestTotal() { + return interestTotal; + } + + public void setInterestTotal(Double interestTotal) { + this.interestTotal = interestTotal; + } + + public String getCustInterestUnit() { + return custInterestUnit; + } + + public void setCustInterestUnit(String custInterestUnit) { + this.custInterestUnit = custInterestUnit; + } + + public double getCustInterestTotal() { + return custInterestTotal; + } + + public void setCustInterestTotal(double custInterestTotal) { + this.custInterestTotal = custInterestTotal; + } + + public String getCustInterestTotalDeposit() { + return custInterestTotalDeposit; + } + + public void setCustInterestTotalDeposit(String custInterestTotalDeposit) { + this.custInterestTotalDeposit = custInterestTotalDeposit; + } + + public String getDealerInterestUnit() { + return dealerInterestUnit; + } + + public void setDealerInterestUnit(String dealerInterestUnit) { + this.dealerInterestUnit = dealerInterestUnit; + } + + public String getDealerInterestTotal() { + return dealerInterestTotal; + } + + public void setDealerInterestTotal(String dealerInterestTotal) { + this.dealerInterestTotal = dealerInterestTotal; + } + + public String getDealerInterestTotalDeposit() { + return dealerInterestTotalDeposit; + } + + public void setDealerInterestTotalDeposit(String dealerInterestTotalDeposit) { + this.dealerInterestTotalDeposit = dealerInterestTotalDeposit; + } + + public String getMakerInterestUnit() { + return makerInterestUnit; + } + + public void setMakerInterestUnit(String makerInterestUnit) { + this.makerInterestUnit = makerInterestUnit; + } + + public double getMakerInterestTotal() { + return makerInterestTotal; + } + + public void setMakerInterestTotal(double makerInterestTotal) { + this.makerInterestTotal = makerInterestTotal; + } + + public String getMakerInterestTotalDeposit() { + return makerInterestTotalDeposit; + } + + public void setMakerInterestTotalDeposit(String makerInterestTotalDeposit) { + this.makerInterestTotalDeposit = makerInterestTotalDeposit; + } + + public String getIsSubsity() { + return isSubsity; + } + + public void setIsSubsity(String isSubsity) { + this.isSubsity = isSubsity; + } + + public String getContractPriceTotal() { + return contractPriceTotal; + } + + public void setContractPriceTotal(String contractPriceTotal) { + this.contractPriceTotal = contractPriceTotal; + } + + public String getMonthInterestRate() { + return monthInterestRate; + } + + public void setMonthInterestRate(String monthInterestRate) { + this.monthInterestRate = monthInterestRate; + } + + public String getPayType() { + return payType; + } + + public void setPayType(String payType) { + this.payType = payType; + } + + public String getPayRemark() { + return payRemark; + } + + public void setPayRemark(String payRemark) { + this.payRemark = payRemark; + } + + public String getIsLinked() { + return isLinked; + } + + public void setIsLinked(String isLinked) { + this.isLinked = isLinked; + } + + public String getLinkedCompany() { + return linkedCompany; + } + + public void setLinkedCompany(String linkedCompany) { + this.linkedCompany = linkedCompany; + } + + public String getLinkedCompanyType() { + return linkedCompanyType; + } + + public void setLinkedCompanyType(String linkedCompanyType) { + this.linkedCompanyType = linkedCompanyType; + } + + public String getReserveString1() { + return reserveString1; + } + + public void setReserveString1(String reserveString1) { + this.reserveString1 = reserveString1; + } + + public String getReserveString2() { + return reserveString2; + } + + public void setReserveString2(String reserveString2) { + this.reserveString2 = reserveString2; + } + + public String getReserveString3() { + return reserveString3; + } + + public void setReserveString3(String reserveString3) { + this.reserveString3 = reserveString3; + } + + public String getReserveString4() { + return reserveString4; + } + + public void setReserveString4(String reserveString4) { + this.reserveString4 = reserveString4; + } + + public String getReserveString5() { + return reserveString5; + } + + public void setReserveString5(String reserveString5) { + this.reserveString5 = reserveString5; + } + + public String getAssetPurpose() { + return assetPurpose; + } + + public void setAssetPurpose(String assetPurpose) { + this.assetPurpose = assetPurpose; + } + + public String getBalloonPercentage() { + return balloonPercentage; + } + + public void setBalloonPercentage(String balloonPercentage) { + this.balloonPercentage = balloonPercentage; + } + + public String getBalloonAmount() { + return balloonAmount; + } + + public void setBalloonAmount(String balloonAmount) { + this.balloonAmount = balloonAmount; + } + + public String getFinancedAmtPct() { + return financedAmtPct; + } + + public void setFinancedAmtPct(String financedAmtPct) { + this.financedAmtPct = financedAmtPct; + } + + public String getRentalCalculationMtd() { + return rentalCalculationMtd; + } + + public void setRentalCalculationMtd(String rentalCalculationMtd) { + this.rentalCalculationMtd = rentalCalculationMtd; + } + + public String getBaseCustomerRate() { + return baseCustomerRate; + } + + public void setBaseCustomerRate(String baseCustomerRate) { + this.baseCustomerRate = baseCustomerRate; + } + + public String getSubsidyRte() { + return subsidyRte; + } + + public void setSubsidyRte(String subsidyRte) { + this.subsidyRte = subsidyRte; + } + + public String getCalcSubsidyRte() { + return calcSubsidyRte; + } + + public void setCalcSubsidyRte(String calcSubsidyRte) { + this.calcSubsidyRte = calcSubsidyRte; + } + + public String getCalcSubsidyAmt() { + return calcSubsidyAmt; + } + + public void setCalcSubsidyAmt(String calcSubsidyAmt) { + this.calcSubsidyAmt = calcSubsidyAmt; + } + + public String getActualRte() { + return actualRte; + } + + public void setActualRte(String actualRte) { + this.actualRte = actualRte; + } + + public String getPaymentScheme() { + return paymentScheme; + } + + public void setPaymentScheme(String paymentScheme) { + this.paymentScheme = paymentScheme; + } + + public String getDealerSubsidyPct() { + return dealerSubsidyPct; + } + + public void setDealerSubsidyPct(String dealerSubsidyPct) { + this.dealerSubsidyPct = dealerSubsidyPct; + } + + public String getManufacturerSubsidyPct() { + return manufacturerSubsidyPct; + } + + public void setManufacturerSubsidyPct(String manufacturerSubsidyPct) { + this.manufacturerSubsidyPct = manufacturerSubsidyPct; + } + + public double getCalcDealerSubsidyAmt() { + return calcDealerSubsidyAmt; + } + + public void setCalcDealerSubsidyAmt(double calcDealerSubsidyAmt) { + this.calcDealerSubsidyAmt = calcDealerSubsidyAmt; + } + + public double getCalcManufacturerSubsidyAmt() { + return calcManufacturerSubsidyAmt; + } + + public void setCalcManufacturerSubsidyAmt(double calcManufacturerSubsidyAmt) { + this.calcManufacturerSubsidyAmt = calcManufacturerSubsidyAmt; + } + + + public String getDownPaymentByFinancePercentage() { + return downPaymentByFinancePercentage; + } + + public void setDownPaymentByFinancePercentage(String downPaymentByFinancePercentage) { + this.downPaymentByFinancePercentage = downPaymentByFinancePercentage; + } +} diff --git a/src/com/ample/esb/bean/amp/PreviouslyVehicle.java b/src/com/ample/esb/bean/amp/PreviouslyVehicle.java new file mode 100644 index 000000000..cc283d4eb --- /dev/null +++ b/src/com/ample/esb/bean/amp/PreviouslyVehicle.java @@ -0,0 +1,38 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class PreviouslyVehicle { + @XStreamAlias("WORKING_TIME") + private String workingTime; + + @XStreamAlias("PREVIOUSLY_VEHICLE_TYPE") + private String previouslyVehicleType; + + @XStreamAlias("PREVIOUSLY_VEHICLE_LICENSE") + private String previouslyVehicleLicense; + + public String getWorkingTime() { + return workingTime; + } + + public void setWorkingTime(String workingTime) { + this.workingTime = workingTime; + } + + public String getPreviouslyVehicleType() { + return previouslyVehicleType; + } + + public void setPreviouslyVehicleType(String previouslyVehicleType) { + this.previouslyVehicleType = previouslyVehicleType; + } + + public String getPreviouslyVehicleLicense() { + return previouslyVehicleLicense; + } + + public void setPreviouslyVehicleLicense(String previouslyVehicleLicense) { + this.previouslyVehicleLicense = previouslyVehicleLicense; + } +} diff --git a/src/com/ample/esb/bean/amp/SingleVehicleType.java b/src/com/ample/esb/bean/amp/SingleVehicleType.java new file mode 100644 index 000000000..df3d58f05 --- /dev/null +++ b/src/com/ample/esb/bean/amp/SingleVehicleType.java @@ -0,0 +1,324 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamAlias; +@XStreamAlias("SINGLEVEHICLETYPE") +public class SingleVehicleType { + @XStreamAlias("MAKER") + private String maker; + + @XStreamAlias("BRAND") + private String brand; + + @XStreamAlias("SERIES") + private String series; + + @XStreamAlias("MODEL") + private String model; + + @XStreamAlias("QUANTITY") + private String quantity; + + @XStreamAlias("PRICEUNIT") + private String priceUnit; + + @XStreamAlias("PRICETOTAL") + private String priceTotal; + + @XStreamAlias("GPS") + private String gps; + + @XStreamAlias("CHASSISVEHICLEMODEL") + private String chassisVehicleModel; + + @XStreamAlias("SUBSITYVEHICLEMODEL") + private String subsityVehicleModel; + + @XStreamAlias("VEHICLETYPE") + private String vehicleType; + + @XStreamAlias("OTHERFEE") + private String otherFee; + + @XStreamAlias("PRODUCER") + private String producer; + + @XStreamAlias("NEW_PRICE") + private String newPrice; + + @XStreamAlias("VIN_NUMBER") + private String vinNumber; + + @XStreamAlias("ENGINE_NUMBER") + private String engineNumber; + + @XStreamAlias("PURPOSE") + private String purpose; + + @XStreamAlias("COMMENTS") + private String comments; + + @XStreamAlias("TRANSMISSION") + private String transmission; + + @XStreamAlias("IS_AFFILIATED") + private String isAffiliated; + + @XStreamAlias("AFFILIATED_COMP_NAME") + private String affiliatedCompName; + + @XStreamAlias("AFFILIATED_COMP_CRDCODE") + private String affiliatedCompCrdcode; + + @XStreamAlias("ROAD_OPERATION_LICENSE_CODE") + private String roadOperationLicenseCode; + + @XStreamAlias("CAR_TYPE") + private String carType; + + @XStreamAlias("BUY_USE_TYPE") + private String buyUseType; + + @XStreamAlias("PURCHASE_TAX") + private String purchaseTax; + + @XStreamAlias("CAR_PRICE") + private String carPrice; + + @XStreamAlias("CAR_REAL_PRICE") + private String carRealPrice; + + @XStreamAlias("SIDE_PRICE") + private String sidePprice; + + public String getRoadOperationLicenseCode() { + return roadOperationLicenseCode; + } + + public void setRoadOperationLicenseCode(String roadOperationLicenseCode) { + this.roadOperationLicenseCode = roadOperationLicenseCode; + } + + public String getCarType() { + return carType; + } + + public void setCarType(String carType) { + this.carType = carType; + } + + public String getBuyUseType() { + return buyUseType; + } + + public void setBuyUseType(String buyUseType) { + this.buyUseType = buyUseType; + } + + public String getPurchaseTax() { + return purchaseTax; + } + + public void setPurchaseTax(String purchaseTax) { + this.purchaseTax = purchaseTax; + } + + public String getCarPrice() { + return carPrice; + } + + public void setCarPrice(String carPrice) { + this.carPrice = carPrice; + } + + public String getCarRealPrice() { + return carRealPrice; + } + + public void setCarRealPrice(String carRealPrice) { + this.carRealPrice = carRealPrice; + } + + public String getSidePprice() { + return sidePprice; + } + + public void setSidePprice(String sidePprice) { + this.sidePprice = sidePprice; + } + + public String getMaker() { + return maker; + } + + public void setMaker(String maker) { + this.maker = maker; + } + + public String getBrand() { + return brand; + } + + public void setBrand(String brand) { + this.brand = brand; + } + + public String getSeries() { + return series; + } + + public void setSeries(String series) { + this.series = series; + } + + public String getModel() { + return model; + } + + public void setModel(String model) { + this.model = model; + } + + public String getQuantity() { + return quantity; + } + + public void setQuantity(String quantity) { + this.quantity = quantity; + } + + public String getPriceUnit() { + return priceUnit; + } + + public void setPriceUnit(String priceUnit) { + this.priceUnit = priceUnit; + } + + public String getPriceTotal() { + return priceTotal; + } + + public void setPriceTotal(String priceTotal) { + this.priceTotal = priceTotal; + } + + public String getGps() { + return gps; + } + + public void setGps(String gps) { + this.gps = gps; + } + + public String getChassisVehicleModel() { + return chassisVehicleModel; + } + + public void setChassisVehicleModel(String chassisVehicleModel) { + this.chassisVehicleModel = chassisVehicleModel; + } + + public String getSubsityVehicleModel() { + return subsityVehicleModel; + } + + public void setSubsityVehicleModel(String subsityVehicleModel) { + this.subsityVehicleModel = subsityVehicleModel; + } + + public String getVehicleType() { + return vehicleType; + } + + public void setVehicleType(String vehicleType) { + this.vehicleType = vehicleType; + } + + public String getOtherFee() { + return otherFee; + } + + public void setOtherFee(String otherFee) { + this.otherFee = otherFee; + } + + public String getProducer() { + return producer; + } + + public void setProducer(String producer) { + this.producer = producer; + } + + public String getNewPrice() { + return newPrice; + } + + public void setNewPrice(String newPrice) { + this.newPrice = newPrice; + } + + public String getVinNumber() { + return vinNumber; + } + + public void setVinNumber(String vinNumber) { + this.vinNumber = vinNumber; + } + + public String getEngineNumber() { + return engineNumber; + } + + public void setEngineNumber(String engineNumber) { + this.engineNumber = engineNumber; + } + + public String getPurpose() { + return purpose; + } + + public void setPurpose(String purpose) { + this.purpose = purpose; + } + + public String getComments() { + return comments; + } + + public void setComments(String comments) { + this.comments = comments; + } + + public String getTransmission() { + return transmission; + } + + public void setTransmission(String transmission) { + this.transmission = transmission; + } + + public String getIsAffiliated() { + return isAffiliated; + } + + public void setIsAffiliated(String isAffiliated) { + this.isAffiliated = isAffiliated; + } + + public String getAffiliatedCompName() { + return affiliatedCompName; + } + + public void setAffiliatedCompName(String affiliatedCompName) { + this.affiliatedCompName = affiliatedCompName; + } + + public String getAffiliatedCompCrdcode() { + return affiliatedCompCrdcode; + } + + public void setAffiliatedCompCrdcode(String affiliatedCompCrdcode) { + this.affiliatedCompCrdcode = affiliatedCompCrdcode; + } +} diff --git a/src/com/ample/esb/bean/amp/VehicleInfo.java b/src/com/ample/esb/bean/amp/VehicleInfo.java new file mode 100644 index 000000000..773577997 --- /dev/null +++ b/src/com/ample/esb/bean/amp/VehicleInfo.java @@ -0,0 +1,18 @@ +package com.ample.esb.bean.amp; + +import com.thoughtworks.xstream.annotations.XStreamImplicit; + +import java.util.List; + +public class VehicleInfo { + @XStreamImplicit + private List SingleVehicleTypes; + + public List getSingleVehicleTypes() { + return SingleVehicleTypes; + } + + public void setSingleVehicleTypes(List singleVehicleTypes) { + SingleVehicleTypes = singleVehicleTypes; + } +} diff --git a/src/com/ample/esb/bean/esb/MessageAppHead.java b/src/com/ample/esb/bean/esb/MessageAppHead.java new file mode 100644 index 000000000..c5eb04f78 --- /dev/null +++ b/src/com/ample/esb/bean/esb/MessageAppHead.java @@ -0,0 +1,220 @@ +package com.ample.esb.bean.esb; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class MessageAppHead { + /** + * ĿǰֻһŲ޹˾:20 + */ + @XStreamAlias("BRANCH_CODE") + private String branchCode; + + @XStreamAlias("CORPORATE_CODE") + private String corporateCode; + + /** + * ¼˻id + */ + @XStreamAlias("OPERATOR_ID") + private String operatorId; + + @XStreamAlias("CUSTOMER_ID") + private String customerId; + + @XStreamAlias("SOURCE_BUSINESS_CODE") + private String sourceBusinessCode; + + @XStreamAlias("ORIGINAL_BUSINESS_CODE") + private String originalBusinessCode; + + /** + * ϵͳҵ + */ + @XStreamAlias("SOURCE_TRAN_DATE") + private String sourceTranDate; + + /** + * ϵͳҵʱ + */ + @XStreamAlias("SOURCE_TRAN_TIME") + private String sourceTranTime; + + @XStreamAlias("AUTH_TELLER") + private String authTeller; + + @XStreamAlias("AUTH_FALG") + private String authFalg; + + @XStreamAlias("AUTH_CODE") + private String authCode; + + @XStreamAlias("AUTH_MSG") + private String authMsg; + + @XStreamAlias("PER_PAGE_NUM") + private String perPageNum; + + @XStreamAlias("CURR_PAGE_NUM") + private String currPageNum; + + @XStreamAlias("PAGE_UPDOWN_FALG") + private String pageUpdownFalg; + + @XStreamAlias("APP_EXPAND_CONTENT") + private String appExpandContent; + /** + * ϵͳҵ + */ + @XStreamAlias("TARGET_TRAN_DATE") + private String targetTranDate; + + /** + * ϵͳҵʱ + */ + @XStreamAlias("TARGET_TRAN_TIME") + private String targetTranTime; + + public String getBranchCode() { + return branchCode; + } + + public void setBranchCode(String branchCode) { + this.branchCode = branchCode; + } + + public String getCorporateCode() { + return corporateCode; + } + + public void setCorporateCode(String corporateCode) { + this.corporateCode = corporateCode; + } + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } + + public String getCustomerId() { + return customerId; + } + + public void setCustomerId(String customerId) { + this.customerId = customerId; + } + + public String getSourceBusinessCode() { + return sourceBusinessCode; + } + + public void setSourceBusinessCode(String sourceBusinessCode) { + this.sourceBusinessCode = sourceBusinessCode; + } + + public String getOriginalBusinessCode() { + return originalBusinessCode; + } + + public void setOriginalBusinessCode(String originalBusinessCode) { + this.originalBusinessCode = originalBusinessCode; + } + + public String getSourceTranDate() { + return sourceTranDate; + } + + public void setSourceTranDate(String sourceTranDate) { + this.sourceTranDate = sourceTranDate; + } + + public String getSourceTranTime() { + return sourceTranTime; + } + + public void setSourceTranTime(String sourceTranTime) { + this.sourceTranTime = sourceTranTime; + } + + public String getAuthTeller() { + return authTeller; + } + + public void setAuthTeller(String authTeller) { + this.authTeller = authTeller; + } + + public String getAuthFalg() { + return authFalg; + } + + public void setAuthFalg(String authFalg) { + this.authFalg = authFalg; + } + + public String getAuthCode() { + return authCode; + } + + public void setAuthCode(String authCode) { + this.authCode = authCode; + } + + public String getAuthMsg() { + return authMsg; + } + + public void setAuthMsg(String authMsg) { + this.authMsg = authMsg; + } + + public String getPerPageNum() { + return perPageNum; + } + + public void setPerPageNum(String perPageNum) { + this.perPageNum = perPageNum; + } + + public String getCurrPageNum() { + return currPageNum; + } + + public void setCurrPageNum(String currPageNum) { + this.currPageNum = currPageNum; + } + + public String getPageUpdownFalg() { + return pageUpdownFalg; + } + + public void setPageUpdownFalg(String pageUpdownFalg) { + this.pageUpdownFalg = pageUpdownFalg; + } + + public String getTargetTranDate() { + return targetTranDate; + } + + public void setTargetTranDate(String targetTranDate) { + this.targetTranDate = targetTranDate; + } + + public String getTargetTranTime() { + return targetTranTime; + } + + public void setTargetTranTime(String targetTranTime) { + this.targetTranTime = targetTranTime; + } + + public String getAppExpandContent() { + return appExpandContent; + } + + public void setAppExpandContent(String appExpandContent) { + this.appExpandContent = appExpandContent; + } +} diff --git a/src/com/ample/esb/bean/esb/MessageBody.java b/src/com/ample/esb/bean/esb/MessageBody.java new file mode 100644 index 000000000..e7fd636b3 --- /dev/null +++ b/src/com/ample/esb/bean/esb/MessageBody.java @@ -0,0 +1,54 @@ +package com.ample.esb.bean.esb; + +import com.ample.esb.bean.afs.AccountSyncRequest; +import com.ample.esb.bean.afs.AfsResultRequest; +import com.ample.esb.bean.amp.AmpRequest; +import com.thoughtworks.xstream.annotations.XStreamAlias; + + +public class MessageBody { + + @XStreamAlias("REQUEST") + private AccountSyncRequest request; + + public AccountSyncRequest getRequest() { + return request; + } + public void setRequest(AccountSyncRequest request) { + this.request = request; + } + + @XStreamAlias("REQUEST") + private AmpRequest ampRequest; + + public AmpRequest getAmpRequest() { + return ampRequest; + } + + public void setAmpRequest(AmpRequest ampRequest) { + this.ampRequest = ampRequest; + } + + @XStreamAlias("RESPONSE") + private Response response; + + public Response getResponse() { + return response; + } + + public void setResponse(Response response) { + this.response = response; + } + + @XStreamAlias("REQUEST") + private AfsResultRequest afsResultRequest; + + public AfsResultRequest getAfsResultRequest() { + return afsResultRequest; + } + + public void setAfsResultRequest(AfsResultRequest afsResultRequest) { + this.afsResultRequest = afsResultRequest; + } + +} diff --git a/src/com/ample/esb/bean/esb/MessageEsbHead.java b/src/com/ample/esb/bean/esb/MessageEsbHead.java new file mode 100644 index 000000000..0137cceda --- /dev/null +++ b/src/com/ample/esb/bean/esb/MessageEsbHead.java @@ -0,0 +1,327 @@ +package com.ample.esb.bean.esb; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + + +public class MessageEsbHead { + @XStreamAlias("SOURCE_SYSTEM_ID") + private String sourceSystemId; + + @XStreamAlias("ORIGINAL_SYSTEM_ID") + private String originalSystemId; + + @XStreamAlias("TARGET_SYSTEM_ID") + private String targetSystemId; + + @XStreamAlias("SERVICE_ID") + private String serviceId; + + @XStreamAlias("SERVICE_VERSION") + private String serviceVersion; + + @XStreamAlias("SCENES_ID") + private String scenesId; + + @XStreamAlias("SCENES_VERSION") + private String scenesVersion; + + /** + * + */ + @XStreamAlias("TRAN_CODE") + private String tranCode; + + /** + * ؽʱͬ첽 00:ͬ10첽 + */ + @XStreamAlias("COMM_TYPE") + private String commType; + + @XStreamAlias("TERMINAL_ID") + private String terminalId; + + /** + * 09:۽ڿͻˣǰˣ;91:ϵͳˣϵͳ˷Ľף + */ + @XStreamAlias("CHANNEL_ID") + private String channelId; + + @XStreamAlias("GLOBAL_SEQ_NO") + private String globalSeqNo; + + @XStreamAlias("SOURCE_SEQ_NO") + private String sourceSeqNo; + + @XStreamAlias("SOURCE_MACHINE_DATE") + private String sourceMachineDate; + + @XStreamAlias("SOURCE_MACHINE_TIME") + private String sourceMachineTime; + + @XStreamAlias("SOURCE_SECURITY_NODE") + private String sourceSecurityNode; + + @XStreamAlias("TARGET_SECURITY_NODE") + private String targetSecurityNode; + + /** + * 0:漰ļ1漰ļ + */ + @XStreamAlias("FILE_FLAG") + private String fileFlag; + + @XStreamAlias("ESB_EXPAND_CONTENT") + private String esbExpandContent; + + @XStreamAlias("TARGET_RECIVE_DATE") + private String targetReciveDate; + + @XStreamAlias("TARGET_RECIVE_TIME") + private String targetReciveTime; + + @XStreamAlias("TARGET_MACHINE_DATE") + private String targetMachineDate; + + @XStreamAlias("TARGET_MACHINE_TIME") + private String targetMachineTime; + + @XStreamAlias("TARGET_SEQ_NO") + private String targetSeqNo; + + @XStreamAlias("RET_COMM_STATUS") + private String retCommStatus; + + @XStreamAlias("RET_CODE") + private String retCode; + + @XStreamAlias("RET_SYSTEM_ID") + private String retSystemId; + + @XStreamAlias("RET_MSG") + private String retMsg; + + + public String getSourceSystemId() { + return sourceSystemId; + } + + public void setSourceSystemId(String sourceSystemId) { + this.sourceSystemId = sourceSystemId; + } + + public String getOriginalSystemId() { + return originalSystemId; + } + + public void setOriginalSystemId(String originalSystemId) { + this.originalSystemId = originalSystemId; + } + + public String getTargetSystemId() { + return targetSystemId; + } + + public void setTargetSystemId(String targetSystemId) { + this.targetSystemId = targetSystemId; + } + + public String getServiceId() { + return serviceId; + } + + public void setServiceId(String serviceId) { + this.serviceId = serviceId; + } + + public String getServiceVersion() { + return serviceVersion; + } + + public void setServiceVersion(String serviceVersion) { + this.serviceVersion = serviceVersion; + } + + public String getScenesId() { + return scenesId; + } + + public void setScenesId(String scenesId) { + this.scenesId = scenesId; + } + + public String getScenesVersion() { + return scenesVersion; + } + + public void setScenesVersion(String scenesVersion) { + this.scenesVersion = scenesVersion; + } + + public String getTranCode() { + return tranCode; + } + + public void setTranCode(String tranCode) { + this.tranCode = tranCode; + } + + public String getCommType() { + return commType; + } + + public void setCommType(String commType) { + this.commType = commType; + } + + public String getTerminalId() { + return terminalId; + } + + public void setTerminalId(String terminalId) { + this.terminalId = terminalId; + } + + public String getChannelId() { + return channelId; + } + + public void setChannelId(String channelId) { + this.channelId = channelId; + } + + public String getGlobalSeqNo() { + return globalSeqNo; + } + + public void setGlobalSeqNo(String globalSeqNo) { + this.globalSeqNo = globalSeqNo; + } + + public String getSourceSeqNo() { + return sourceSeqNo; + } + + public void setSourceSeqNo(String sourceSeqNo) { + this.sourceSeqNo = sourceSeqNo; + } + + public String getSourceMachineDate() { + return sourceMachineDate; + } + + public void setSourceMachineDate(String sourceMachineDate) { + this.sourceMachineDate = sourceMachineDate; + } + + public String getSourceMachineTime() { + return sourceMachineTime; + } + + public void setSourceMachineTime(String sourceMachineTime) { + this.sourceMachineTime = sourceMachineTime; + } + + public String getSourceSecurityNode() { + return sourceSecurityNode; + } + + public void setSourceSecurityNode(String sourceSecurityNode) { + this.sourceSecurityNode = sourceSecurityNode; + } + + public String getTargetSecurityNode() { + return targetSecurityNode; + } + + public void setTargetSecurityNode(String targetSecurityNode) { + this.targetSecurityNode = targetSecurityNode; + } + + public String getFileFlag() { + return fileFlag; + } + + public void setFileFlag(String fileFlag) { + this.fileFlag = fileFlag; + } + + public String getEsbExpandContent() { + return esbExpandContent; + } + + public void setEsbExpandContent(String esbExpandContent) { + this.esbExpandContent = esbExpandContent; + } + + public String getTargetReciveDate() { + return targetReciveDate; + } + + public void setTargetReciveDate(String targetReciveDate) { + this.targetReciveDate = targetReciveDate; + } + + public String getTargetMachineTime() { + return targetMachineTime; + } + + public void setTargetMachineTime(String targetMachineTime) { + this.targetMachineTime = targetMachineTime; + } + + public String getTargetSeqNo() { + return targetSeqNo; + } + + public void setTargetSeqNo(String targetSeqNo) { + this.targetSeqNo = targetSeqNo; + } + + public String getRetCommStatus() { + return retCommStatus; + } + + public void setRetCommStatus(String retCommStatus) { + this.retCommStatus = retCommStatus; + } + + public String getRetCode() { + return retCode; + } + + public void setRetCode(String retCode) { + this.retCode = retCode; + } + + public String getRetSystemId() { + return retSystemId; + } + + public void setRetSystemId(String retSystemId) { + this.retSystemId = retSystemId; + } + + public String getRetMsg() { + return retMsg; + } + + public void setRetMsg(String retMsg) { + this.retMsg = retMsg; + } + + public String getTargetReciveTime() { + return targetReciveTime; + } + + public void setTargetReciveTime(String targetReciveTime) { + this.targetReciveTime = targetReciveTime; + } + + public String getTargetMachineDate() { + return targetMachineDate; + } + + public void setTargetMachineDate(String targetMachineDate) { + this.targetMachineDate = targetMachineDate; + } +} diff --git a/src/com/ample/esb/bean/esb/Response.java b/src/com/ample/esb/bean/esb/Response.java new file mode 100644 index 000000000..15442105d --- /dev/null +++ b/src/com/ample/esb/bean/esb/Response.java @@ -0,0 +1,16 @@ +package com.ample.esb.bean.esb; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +public class Response { + @XStreamAlias("RESULT") + private String result; + + public String getResult() { + return result; + } + + public void setResult(String result) { + this.result = result; + } +} diff --git a/src/com/ample/esb/bean/esb/Transaction.java b/src/com/ample/esb/bean/esb/Transaction.java new file mode 100644 index 000000000..510303b7e --- /dev/null +++ b/src/com/ample/esb/bean/esb/Transaction.java @@ -0,0 +1,39 @@ +package com.ample.esb.bean.esb; + +import com.thoughtworks.xstream.annotations.XStreamAlias; + +@XStreamAlias("TRANSACTION") +public class Transaction { + @XStreamAlias("MESSAGE_ESB_HEAD") + private MessageEsbHead messageEsbHead; + + @XStreamAlias("MESSAGE_APP_HEAD") + private MessageAppHead messageAppHead; + + @XStreamAlias("MESSAGE_BODY") + private MessageBody messageBody; + + public MessageEsbHead getMessageEsbHead() { + return messageEsbHead; + } + + public void setMessageEsbHead(MessageEsbHead messageEsbHead) { + this.messageEsbHead = messageEsbHead; + } + + public MessageAppHead getMessageAppHead() { + return messageAppHead; + } + + public void setMessageAppHead(MessageAppHead messageAppHead) { + this.messageAppHead = messageAppHead; + } + + public MessageBody getMessageBody() { + return messageBody; + } + + public void setMessageBody(MessageBody messageBody) { + this.messageBody = messageBody; + } +} diff --git a/src/com/ample/esb/common/EsbCommon.java b/src/com/ample/esb/common/EsbCommon.java new file mode 100644 index 000000000..1947592aa --- /dev/null +++ b/src/com/ample/esb/common/EsbCommon.java @@ -0,0 +1,192 @@ +package com.ample.esb.common; + +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; +import com.ample.esb.bean.esb.MessageAppHead; +import com.ample.esb.bean.esb.MessageBody; +import com.ample.esb.bean.esb.MessageEsbHead; +import com.ample.esb.bean.esb.Transaction; +import com.ample.esb.service.EsbServise; +import com.ample.esb.util.BaicPropertiesUtil; +import com.ample.esb.util.DateUtils; +import com.ample.esb.util.GlobalSeqNo; +import com.ample.esb.util.XstreamUtil; +import com.ample.sms.FileUtil; +import org.apache.http.HttpResponse; +import org.apache.http.HttpStatus; +import org.apache.http.client.config.RequestConfig; +import org.apache.http.client.methods.HttpPost; +import org.apache.http.entity.StringEntity; +import org.apache.http.impl.client.CloseableHttpClient; +import org.apache.http.impl.client.HttpClients; +import org.apache.http.util.EntityUtils; +import org.bouncycastle.crypto.digests.SM3Digest; + +import java.io.IOException; +import java.nio.charset.StandardCharsets; + +public class EsbCommon implements EsbServise { + public Transaction createEsbTransaction() { + Transaction transaction = new Transaction(); + transaction.setMessageEsbHead(esbHead()); + transaction.setMessageAppHead(appHead()); + transaction.setMessageBody(messgeBody()); + return transaction; + } + public MessageEsbHead getCommonEsbHead(MessageEsbHead esbHead) { + esbHead.setSourceSystemId("APF"); + esbHead.setOriginalSystemId("APF"); + esbHead.setSourceMachineDate(DateUtils.dateNow()); + esbHead.setSourceMachineTime(DateUtils.TimeNowAccurate()); + String globalSeqNo = new GlobalSeqNo().getGlobalSeqNo(); + esbHead.setGlobalSeqNo(globalSeqNo); + esbHead.setSourceSeqNo(globalSeqNo); + esbHead.setTerminalId(""); + esbHead.setSourceSecurityNode(""); + esbHead.setTargetSecurityNode(""); + esbHead.setEsbExpandContent(""); + return esbHead; + } + public MessageAppHead getCommonAppHead(MessageAppHead appHead){ + appHead.setBranchCode("20"); + appHead.setSourceTranDate(DateUtils.dateNow()); + appHead.setSourceTranTime(DateUtils.TimeNowAccurate()); + appHead.setCorporateCode(""); + appHead.setCustomerId(""); + appHead.setSourceBusinessCode(""); + appHead.setOriginalBusinessCode(""); + appHead.setAuthCode(""); + appHead.setAuthMsg(""); + appHead.setAuthFalg(""); + appHead.setAuthTeller(""); + appHead.setPerPageNum(""); + appHead.setCurrPageNum(""); + appHead.setPageUpdownFalg(""); + appHead.setAppExpandContent(""); + return appHead; + } + public MessageBody getCommonBody(MessageBody msgBody){ + return msgBody; + } + public MessageEsbHead esbHead(){ + return this.getCommonEsbHead(new MessageEsbHead()); + } + public MessageAppHead appHead(){ + return this.getCommonAppHead(new MessageAppHead()); + } + public MessageBody messgeBody(){ + return this.getCommonBody(new MessageBody()); + } + + public String httpSend(String url , String xmlValue){ + String result = null; + HttpPost httppost = new HttpPost(url); + httppost.setHeader("Connection", "close"); + httppost.setHeader("Content-Type", "application/x-www-form-urlencoded"); + //setConnectTimeoutӳʱʱ䣬λ롣setConnectionRequestTimeoutôconnect Manager(ӳ)ȡConnection ʱʱ䣬λ롣¼ӵԣΪĿǰ汾ǿԹӳصġsetSocketTimeoutȡݵijʱʱ(Ӧʱ)λ롣 + RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(65000).setConnectionRequestTimeout(65000).setSocketTimeout(65000).build(); + httppost.setConfig(requestConfig); + System.out.println("ESBģ\n"+xmlValue); + StringEntity stringEntity = new StringEntity(xmlValue, "UTF-8"); + httppost.setEntity(stringEntity); + CloseableHttpClient client = HttpClients.createDefault(); + try { + HttpResponse response = client.execute(httppost); + if(response.getStatusLine().getStatusCode() == HttpStatus.SC_OK){ + result = EntityUtils.toString(response.getEntity()); + byte[] xmlByte = result.getBytes(StandardCharsets.ISO_8859_1); + result = new String(xmlByte,"utf-8"); + System.out.println("ESBӦģ\n"+result); + } + } catch (IOException e) { + e.printStackTrace(); + } + return result; + } + + /** + * ժҪ + * @param srcData + * @return + */ + public byte[] hash(byte[] srcData){ + SM3Digest digest = new SM3Digest(); + digest.update(srcData,0,srcData.length); + byte[] hash = new byte[digest.getDigestSize()]; + digest.doFinal(hash,0); + return hash; + } + @Override + public Transaction transactionDo(){ + String logPath = BaicPropertiesUtil.get("log_path"); + //.ʵ + Transaction tranRequest = createEsbTransaction(); + //.תΪxml + String xmlRrquest = XstreamUtil.xmlConvert(tranRequest); + //.xmlĴΪļ + FileUtil.writeFile(logPath+tranRequest.getMessageEsbHead().getGlobalSeqNo()+"_request.txt", xmlRrquest); + //.Ϣ + saveEsbLog(tranRequest); + //.url + String url = this.getUrl(tranRequest); + //.õӦ + String xmlResopnse= this.httpSend(url,xmlRrquest); + //.xmlӦĴΪļ + FileUtil.writeFile(logPath+tranRequest.getMessageEsbHead().getGlobalSeqNo()+"_response.txt", xmlResopnse); + //.תΪʵ + Transaction tranResponse = (Transaction)XstreamUtil.objectConvert(xmlResopnse); + //.ӦϢ + updateEsbLog(tranResponse); + return tranResponse; + } + public String getUrl(Transaction tran){ + String tranCode = tran.getMessageEsbHead().getTranCode(); + String serviceId = BaicPropertiesUtil.get(tranCode+"_serviceid"); + String userId = BaicPropertiesUtil.get("userid"); + String url = BaicPropertiesUtil.get("esb_url")+"userid="+userId+"&serviceid="+serviceId; + return url; + } + public void updateEsbLog(Transaction tran) { + BizObjectManager bom = null; + try { + MessageEsbHead esbHead = tran.getMessageEsbHead(); + String globalSeqNo = esbHead.getGlobalSeqNo(); + if(globalSeqNo.length()==0){ + return; + } + bom = JBOFactory.getBizObjectManager("jbo.oti.ESB_LOG"); + BizObject bo = bom.createQuery("GLOBAL_SEQ_NO=:GLOBAL_SEQ_NO").setParameter("GLOBAL_SEQ_NO",globalSeqNo).getSingleResult(true); + if(bo==null||bo.getAttribute("GLOBAL_SEQ_NO")==null||"".equals(bo.getAttribute("GLOBAL_SEQ_NO").toString())){ + return; + } + bo.setAttributeValue("RET_CODE",esbHead.getRetCode()); + bo.setAttributeValue("RET_MSG",esbHead.getRetMsg()); + bo.setAttributeValue("RET_SYSTEM_ID",esbHead.getRetSystemId()); + bo.setAttributeValue("SOURCE_MACHINE_DATE",esbHead.getSourceMachineDate()); + bo.setAttributeValue("UPDATETIME", DateUtils.dateTimeNow()); + bom.saveObject(bo); + } catch (JBOException e) { + e.printStackTrace(); + } + } + + public void saveEsbLog(Transaction tran){ + BizObjectManager bom = null; + try { + bom = JBOFactory.getBizObjectManager("jbo.oti.ESB_LOG"); + MessageEsbHead esbHead = tran.getMessageEsbHead(); + BizObject bo = bom.newObject(); + bo.setAttributeValue("GLOBAL_SEQ_NO",esbHead.getGlobalSeqNo()); + bo.setAttributeValue("TARGET_SEQ_NO",esbHead.getTargetSeqNo()); + bo.setAttributeValue("TARGET_SYSTEM_ID",esbHead.getTargetSystemId()); + bo.setAttributeValue("SERVICE_ID",esbHead.getServiceId()); + bo.setAttributeValue("TRAN_CODE",esbHead.getTranCode()); + bo.setAttributeValue("INPUTTIME", DateUtils.dateTimeNow()); + bom.saveObject(bo); + } catch (JBOException e) { + e.printStackTrace(); + } + } +} diff --git a/src/com/ample/esb/common/ParamDataUtils.java b/src/com/ample/esb/common/ParamDataUtils.java new file mode 100644 index 000000000..3b5704798 --- /dev/null +++ b/src/com/ample/esb/common/ParamDataUtils.java @@ -0,0 +1,183 @@ +package com.ample.esb.common; + +import com.ample.esb.common.cache.EsbParamCache; +import org.apache.commons.lang3.StringUtils; + +import java.util.Map; + +/** + * ̨Խӣ + */ +public class ParamDataUtils { + + /** + * ϵͳöݻȡö + * @param codeNo + * @param itemNo + * @param extend չֶΣĿǰѯ״̬ʱӴŮ + * @return + */ + public static String queryBcEnumType(String codeNo, String itemNo, String extend){ + if(StringUtils.isNotEmpty(extend) && "marry".equals(codeNo) && "01".equals(itemNo)){//״ ѻ 01 + /** + * 00001 ѻŮ + * 00006 ѻŮ + */ + if(Integer.parseInt(extend) > 0){// Ů0 + return "00006"; + }else { + return "00001"; + } + } + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + return resMap.get("bc_item_no"); + } + } + return ""; + } + + /** + * ϵͳöݻȡö + * @param codeNo + * @param itemNo + * @return + */ + public static String queryBcEnumType(String codeNo, String itemNo){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if("duties".equals(codeNo) || "personContact".equals(codeNo)){ + if(null != libraryMapRes){ + for(String key : libraryMapRes.keySet()){ + Map resMap = (Map) libraryMapRes.get(key); + if(itemNo.equals(resMap.get("ap_item_value"))){ + return resMap.get("bc_item_no"); + } + } + } + if("duties".equals(codeNo)){ + return "00006"; + }else { + return "00122"; + } + + } + + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + return resMap.get("bc_item_no"); + } + } + return ""; + } + + + /** + * ϵͳֵַȡƵַ + * @param codeNo + * @param itemNo + * @return + */ + public static String queryMapBcProvinceCode(String codeNo, String itemNo){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + if(StringUtils.isEmpty(resMap.get("grant_address_code"))){ + if(StringUtils.isEmpty(resMap.get("parent_address_code"))){ + return resMap.get("address_code"); + } + return resMap.get("parent_address_code"); + } + return resMap.get("grant_address_code"); + } + } + return ""; + } + + /** + * ϵͳֵַȡƵַ + * @param codeNo + * @param itemNo + * @return + */ + public static String queryMapBcCityCode(String codeNo, String itemNo){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + if("1".equals(resMap.get("address_code_level"))){ + return ""; + } + if("2".equals(resMap.get("address_code_level"))){ + return resMap.get("address_code"); + } + if("3".equals(resMap.get("address_code_level"))){ + return resMap.get("parent_address_code"); + } + } + } + return ""; + } + + /** + * ϵͳֵַȡƵַ + * @param codeNo + * @param itemNo + * @return + */ + public static String queryMapBcCountyCode(String codeNo, String itemNo){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + return resMap.get("address_code"); + } + } + return ""; + } + + /** + * ϵͳֵַȡƵַ + * @param codeNo + * @param itemNo + * @return + */ + public static Map queryMapEntity(String codeNo, String itemNo){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + return (Map) libraryMapRes.get(itemNo); + } + return null; + } + + /** + * ϵͳַ롢ֵ롢ַȫ ȡϸַ + * @param codeNo + * @param itemNo + * @param fullAddress + * @return + */ + public static String queryMapDetailAddress(String codeNo, String itemNo, String fullAddress){ + Map libraryMap = EsbParamCache.getEsbParamCachePool(); + Map libraryMapRes = (Map) libraryMap.get(codeNo); + if(null != libraryMapRes){ + Map resMap = (Map) libraryMapRes.get(itemNo); + if(null != resMap){ + String apAddress = resMap.get("ap_address_value"); + fullAddress = fullAddress.replaceAll(apAddress, ""); + return fullAddress; + } + } + return ""; + } + +} diff --git a/src/com/ample/esb/common/RCRequiredDataCheck.java b/src/com/ample/esb/common/RCRequiredDataCheck.java new file mode 100644 index 000000000..1dcecf5ac --- /dev/null +++ b/src/com/ample/esb/common/RCRequiredDataCheck.java @@ -0,0 +1,62 @@ +package com.ample.esb.common; + +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOFactory; +import com.amarsoft.awe.util.Transaction; +import com.tenwa.template.check.DefaultBussinessCheck; +import jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR_TEMP; +import org.apache.commons.collections.CollectionUtils; +import org.apache.commons.lang3.StringUtils; + +import java.util.List; + +/** + * ̨Խӱֶμ + * + */ +public class RCRequiredDataCheck extends DefaultBussinessCheck{ + @Override + public Object run(Transaction Sqlca) throws Exception { + String ObjectNo = this.getAttribute("ObjectNo").toString(); + + BizObjectManager lbEquipmentCarTemp = JBOFactory.getBizObjectManager(LB_EQUIPMENT_CAR_TEMP.CLASS_NAME);// ĿϢ + List lbEquipmentCarTempBizObjectList = lbEquipmentCarTemp.createQuery("FLOWUNID=:FLOWUNID") + .setParameter("FLOWUNID", ObjectNo).getResultList(false); + if(CollectionUtils.isEmpty(lbEquipmentCarTempBizObjectList)){ + putMsg("Ϣδѡ"); + setPass(false); + return null; + } + for(BizObject lbEquipmentCarTempBizObject : lbEquipmentCarTempBizObjectList){ + if(null == lbEquipmentCarTempBizObject.getAttribute("car_use_type") + || StringUtils.isEmpty(lbEquipmentCarTempBizObject.getAttribute("car_use_type").toString())){ + putMsg("ϢбֶΣ;δд"); + setPass(false); + return null; + } + + if(null == lbEquipmentCarTempBizObject.getAttribute("MANUFACTURER_NAME") + || StringUtils.isEmpty(lbEquipmentCarTempBizObject.getAttribute("MANUFACTURER_NAME").toString())){ + putMsg("ϢбֶΣδд"); + setPass(false); + return null; + } + + if(null == lbEquipmentCarTempBizObject.getAttribute("EQUIP_PRICE") + || StringUtils.isEmpty(lbEquipmentCarTempBizObject.getAttribute("EQUIP_PRICE").toString())){ + putMsg("ϢбֶΣ׼۸δд"); + setPass(false); + return null; + } + if("0.00".equals(lbEquipmentCarTempBizObject.getAttribute("EQUIP_PRICE").toString())){ + putMsg("ϢбֶΣ׼۸Ϊ㣡"); + setPass(false); + return null; + } + } + putMsg("֤ͨ"); + setPass(true); + return null; + } +} diff --git a/src/com/ample/esb/common/address/PersonAddressController.java b/src/com/ample/esb/common/address/PersonAddressController.java new file mode 100644 index 000000000..dfc426601 --- /dev/null +++ b/src/com/ample/esb/common/address/PersonAddressController.java @@ -0,0 +1,99 @@ +package com.ample.esb.common.address; + +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.*; +import com.ample.esb.common.ParamDataUtils; +import com.tenwa.reckon.util.UUIDUtil; +import jbo.oti.RC_ADDRESS_INFO; +import jbo.oti.RC_ADDRESS_LIBRARY; +import org.apache.commons.lang3.StringUtils; + +import java.util.Map; + +public class PersonAddressController { + + private String id=""; + private String province=""; + private String provinceName=""; + private String dressDetail=""; + + public String getProvince() { + return province; + } + + public void setProvince(String province) { + this.province = province; + } + + public String getProvinceName() { + return provinceName; + } + + public void setProvinceName(String provinceName) { + this.provinceName = provinceName; + } + + public String getDressDetail() { + return dressDetail; + } + + public void setDressDetail(String dressDetail) { + this.dressDetail = dressDetail; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + + /** + * µַ + * @param tx + * @return + * */ + public String saveOrUpdate(JBOTransaction tx)throws Exception { + ARE.getLog().info("[PersonAddressController] saveOrUpdate bulid Begin ................."); + BizObjectManager rcAddressInfo = JBOFactory.getBizObjectManager(RC_ADDRESS_INFO.CLASS_NAME,tx); + Map rcAddressLibraryBizObject = ParamDataUtils.queryMapEntity("ZXAreaCode", province); + if(null == rcAddressLibraryBizObject){ + return "false@ϵͳ쳣"; + } + BizObject rcAddressInfoBizObject = rcAddressInfo.newObject(); + // : 2023-8-17 ж޸ + if(StringUtils.isNotEmpty(id)){ + rcAddressInfoBizObject = rcAddressInfo.createQuery("address_id=:id").setParameter("id", id).getSingleResult(true); + }else { + id = UUIDUtil.getUUID(); + rcAddressInfoBizObject.setAttributeValue("address_id", id); + } + makeRcAddressInfoByLibrary(rcAddressLibraryBizObject, rcAddressInfoBizObject); + rcAddressInfo.saveObject(rcAddressInfoBizObject); + ARE.getLog().info("[PersonAddressController] saveOrUpdate bulid Begin ................."); + // : 2023-8-17 idֵ + return "true@"+id; + } + + /** + * ʵת + * @param rcAddressLibraryBizObject + * @param rcAddressInfoBizObject + */ + private void makeRcAddressInfoByLibrary(Map rcAddressLibraryBizObject, BizObject rcAddressInfoBizObject) throws JBOException { + rcAddressInfoBizObject.setAttributeValue("ap_address_value", rcAddressLibraryBizObject.get("ap_address_value")); + rcAddressInfoBizObject.setAttributeValue("ap_address_code", rcAddressLibraryBizObject.get("ap_address_code")); + rcAddressInfoBizObject.setAttributeValue("full_address", provinceName + dressDetail); + rcAddressInfoBizObject.setAttributeValue("address_detail", dressDetail); + rcAddressInfoBizObject.setAttributeValue("district_value", rcAddressLibraryBizObject.get("address_value")); + rcAddressInfoBizObject.setAttributeValue("district_code", rcAddressLibraryBizObject.get("address_code")); + rcAddressInfoBizObject.setAttributeValue("city_value", rcAddressLibraryBizObject.get("parent_address_value")); + rcAddressInfoBizObject.setAttributeValue("city_code", rcAddressLibraryBizObject.get("parent_address_code")); + rcAddressInfoBizObject.setAttributeValue("province_value", rcAddressLibraryBizObject.get("grant_address_value")); + rcAddressInfoBizObject.setAttributeValue("province_code", rcAddressLibraryBizObject.get("grant_address_code")); + } + + +} diff --git a/src/com/ample/esb/common/cache/EsbParamCache.java b/src/com/ample/esb/common/cache/EsbParamCache.java new file mode 100644 index 000000000..8a2df8a7e --- /dev/null +++ b/src/com/ample/esb/common/cache/EsbParamCache.java @@ -0,0 +1,118 @@ +package com.ample.esb.common.cache; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import jbo.oti.RC_ADDRESS_LIBRARY; +import jbo.oti.RC_LIBRARY; +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; +import com.amarsoft.awe.util.Transaction; +import com.amarsoft.dict.als.cache.AbstractCache; + +public class EsbParamCache extends AbstractCache { + private static Map esbParamCachePool = null; + private static EsbParamCache instance = null; + + public static synchronized EsbParamCache getInstance() { + if (instance == null) { + instance = new EsbParamCache(); + } + return instance; + } + + public static Map getEsbParamCachePool() { + return esbParamCachePool; + } + + public synchronized Map getCacheMapPool() { + if (esbParamCachePool == null) + esbParamCachePool = new HashMap(); + return esbParamCachePool; + } + + @Override + public synchronized void clear() throws Exception { + getCacheMapPool().clear(); + esbParamCachePool = null; + } + + @Override + public synchronized boolean load(Transaction arg0) throws Exception { + ARE.getLog().info("[CACHE] EsbParamCache20230823 bulid Begin ................."); + initCodeCachePool(); + ARE.getLog().info("[CACHE] EsbParamCache20230823 bulid End ..................."); + return true; + } + + @SuppressWarnings("unchecked") + private synchronized void initCodeCachePool() throws JBOException { + esbParamCachePool = new HashMap(); + Map liveAddressMap = new HashMap();//סַ AreaCode + Map idAddressMap = new HashMap();//ַ ZXAreaCode + BizObjectManager rcAddressLibrary = JBOFactory.getBizObjectManager(RC_ADDRESS_LIBRARY.CLASS_NAME); + // : 2023-8-17 province ѯ RC_ADDRESS_LIBRARY + List rcAddressList= rcAddressLibrary.createQuery("1=1 ").getResultList(false); + for (BizObject address : rcAddressList) { + String apLibraryCode = address.getAttribute("ap_library_code") == null ? "" : address.getAttribute("ap_library_code").toString(); + if("AreaCode".equals(apLibraryCode)){//סַ + Map liveMap = initMapLibrary(address); + ARE.getLog().info("[CACHE] EsbParamCache20230823 bulid info .......סַ..........liveMap.ap_address_value=" + liveMap.get("ap_address_value")); + liveAddressMap.put(liveMap.get("ap_address_code"), liveMap); + }else if("ZXAreaCode".equals(apLibraryCode)){//ַ + Map idMap = initMapLibrary(address); + ARE.getLog().info("[CACHE] EsbParamCache20230823 bulid info .......ַ..........idMap.ap_address_value=" + idMap.get("ap_address_value")); + idAddressMap.put(idMap.get("ap_address_code"), idMap); + }else { + ARE.getLog().info("[CACHE] EsbParamCache20230823 error ap_library_code쳣 ...................id=" + address.getAttribute("id").toString()); + } + } + esbParamCachePool.put("AreaCode", liveAddressMap); + esbParamCachePool.put("ZXAreaCode", idAddressMap); + + BizObjectManager rcLibrary = JBOFactory.getBizObjectManager(RC_LIBRARY.CLASS_NAME); + // : 2023-8-17 province ѯ RC_ADDRESS_LIBRARY + List rcLibraryList= rcLibrary.createQuery("1=1 ").getResultList(false); + for (BizObject library : rcLibraryList) { + Map libraryItemMap = initRcLibrary(library); + ARE.getLog().info("[CACHE] EsbParamCache20230823 bulid info .......ֵ..........libraryItemMap.ap_address_value=" + libraryItemMap.get("ap_item_value")); + Map othersMap = (Map) esbParamCachePool.get(libraryItemMap.get("library_no"));//ֵ + if(null == othersMap){ + othersMap = new HashMap();//ֵ + esbParamCachePool.put(libraryItemMap.get("library_no"), othersMap); + } + othersMap.put(libraryItemMap.get("ap_item_no"), libraryItemMap); + } + } + + private Map initRcLibrary(BizObject library) throws JBOException { + Map map = new HashMap<>(); + map.put("id", library.getAttribute("id") == null ? "" : library.getAttribute("id").toString()); + map.put("library_no", library.getAttribute("library_no") == null ? "" : library.getAttribute("library_no").toString()); + map.put("library_value", library.getAttribute("library_value") == null ? "" : library.getAttribute("library_value").toString()); + map.put("ap_item_value", library.getAttribute("ap_item_value") == null ? "" : library.getAttribute("ap_item_value").toString()); + map.put("ap_item_no", library.getAttribute("ap_item_no") == null ? "" : library.getAttribute("ap_item_no").toString()); + map.put("bc_item_no", library.getAttribute("bc_item_no") == null ? "" : library.getAttribute("bc_item_no").toString()); + map.put("bc_item_value", library.getAttribute("bc_item_value") == null ? "" : library.getAttribute("bc_item_value").toString()); + return map; + } + + private Map initMapLibrary(BizObject address) throws JBOException { + Map map = new HashMap<>(); + map.put("id", address.getAttribute("id") == null ? "" : address.getAttribute("id").toString()); + map.put("address_code", address.getAttribute("address_code") == null ? "" : address.getAttribute("address_code").toString()); + map.put("address_value", address.getAttribute("address_value") == null ? "" : address.getAttribute("address_value").toString()); + map.put("parent_address_code", address.getAttribute("parent_address_code") == null ? "" : address.getAttribute("parent_address_code").toString()); + map.put("parent_address_value", address.getAttribute("parent_address_value") == null ? "" : address.getAttribute("parent_address_value").toString()); + map.put("grant_address_code", address.getAttribute("grant_address_code") == null ? "" : address.getAttribute("grant_address_code").toString()); + map.put("grant_address_value", address.getAttribute("grant_address_value") == null ? "" : address.getAttribute("grant_address_value").toString()); + map.put("address_code_level", address.getAttribute("address_code_level") == null ? "" : address.getAttribute("address_code_level").toString()); + map.put("ap_library_code", address.getAttribute("ap_library_code") == null ? "" : address.getAttribute("ap_library_code").toString()); + map.put("ap_address_code", address.getAttribute("ap_address_code") == null ? "" : address.getAttribute("ap_address_code").toString()); + map.put("ap_address_value", address.getAttribute("ap_address_value") == null ? "" : address.getAttribute("ap_address_value").toString()); + return map; + } +} diff --git a/src/com/ample/esb/common/cache/EsbParamLoader.java b/src/com/ample/esb/common/cache/EsbParamLoader.java new file mode 100644 index 000000000..59f20fa61 --- /dev/null +++ b/src/com/ample/esb/common/cache/EsbParamLoader.java @@ -0,0 +1,10 @@ +package com.ample.esb.common.cache; + +import com.amarsoft.dict.als.cache.AbstractCache; +import com.amarsoft.dict.als.cache.loader.AbstractLoader; + +public class EsbParamLoader extends AbstractLoader { + public AbstractCache getCacheInstance() { + return EsbParamCache.getInstance(); + } +} diff --git a/src/com/ample/esb/controller/AccountSyncController.java b/src/com/ample/esb/controller/AccountSyncController.java new file mode 100644 index 000000000..5d0f263eb --- /dev/null +++ b/src/com/ample/esb/controller/AccountSyncController.java @@ -0,0 +1,84 @@ +package com.ample.esb.controller; + +import com.amarsoft.are.jbo.*; +import com.ample.esb.bean.afs.AccountSyncRequest; +import com.ample.esb.bean.esb.Transaction; +import com.ample.esb.service.EsbServise; +import com.ample.esb.service.impl.AccountSyncServiceImpl; +import jbo.sys.USER_INFO; + +public class AccountSyncController { + private String operatorId; + private String userId; + private String userName; + private String afsState; + public String accountSyncDo(JBOTransaction tx) { + EsbServise es = new AccountSyncServiceImpl(getRequestBody()); + Transaction tran = es.transactionDo(); + String result = resultAnalysis(tran); + return result; + } + public AccountSyncRequest getRequestBody(){ + AccountSyncRequest accountSyncRequest = new AccountSyncRequest(); + accountSyncRequest.setOperatorId(operatorId); + accountSyncRequest.setUserId(userId); + accountSyncRequest.setUserName(userName); + accountSyncRequest.setSystemState(afsState); + return accountSyncRequest; + } + public String resultAnalysis(Transaction tran){ + String response = ""; + String retCode = tran.getMessageEsbHead().getRetCode(); + if("000000".equals(retCode)){ + String result = tran.getMessageBody().getResponse().getResult(); + if("Successful".equals(result)){ + BizObjectManager bm = null; + try { + bm = JBOFactory.getBizObjectManager(USER_INFO.CLASS_NAME); + BizObject bo = bm.createQuery("USERID=:USERID").setParameter("USERID",userId).getSingleResult(true); + bo.setAttributeValue("ATTRIBUTE1",afsState); + bm.saveObject(bo); + } catch (JBOException e) { + e.printStackTrace(); + } + + response = "ɹ"; + } + }else{ + response = "ִ󣬴룺"+retCode+".ϵϵͳԱ"; + } + return response; + } + + public String getUserId() { + return userId; + } + + public void setUserId(String userId) { + this.userId = userId; + } + + public String getUserName() { + return userName; + } + + public void setUserName(String userName) { + this.userName = userName; + } + + public String getAfsState() { + return afsState; + } + + public void setAfsState(String afsState) { + this.afsState = afsState; + } + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } +} diff --git a/src/com/ample/esb/controller/AfsResultServlet.java b/src/com/ample/esb/controller/AfsResultServlet.java new file mode 100644 index 000000000..a5c38ec78 --- /dev/null +++ b/src/com/ample/esb/controller/AfsResultServlet.java @@ -0,0 +1,113 @@ +package com.ample.esb.controller; + +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; +import com.ample.esb.bean.esb.*; +import com.ample.esb.util.BaicPropertiesUtil; +import com.ample.esb.util.DateUtils; +import com.ample.esb.util.XstreamUtil; +import com.ample.sms.FileUtil; +import jbo.oti.RC_SCORE_RESULT; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStreamReader; +import java.io.PrintWriter; + +public class AfsResultServlet extends HttpServlet { + private static final long serialVersionUID = 1L; + public void doPost(HttpServletRequest request, HttpServletResponse response) { + System.out.println("============թ˹жصʼ!============"); + response.setContentType("application/xml;charset:utf-8"); + response.setHeader("Cache-Control", "no-store"); + response.setHeader("Pragma", "no-cache"); + response.setDateHeader("Expires", 0L); + response.setCharacterEncoding("utf-8"); + PrintWriter out = null; + String resultXml = null; + try { + out = response.getWriter(); + BufferedReader in = new BufferedReader(new InputStreamReader(request.getInputStream(), "UTF-8")); + StringBuilder sb = new StringBuilder(); + String line = null; + while ((line = in.readLine()) != null) { + sb.append(line); + } + resultXml = sb.toString(); + ARE.getLog().info("յRpt¼" + resultXml); + } catch (IOException e) { + e.printStackTrace(); + } + + out.print(updateResult(resultXml)); + out.close(); + System.out.println("============թ˹жص!============"); + } + + public String updateResult(String requestXml){ + Transaction tran = (Transaction)XstreamUtil.objectConvert(requestXml); + String logPath = BaicPropertiesUtil.get("log_path"); + String globalSeqNo = tran.getMessageEsbHead().getGlobalSeqNo(); + String projectNo = tran.getMessageBody().getAfsResultRequest().getApplyNo(); + FileUtil.writeFile(logPath + projectNo +"_"+ globalSeqNo +"_request.txt", requestXml); + String fraudAlert = tran.getMessageBody().getAfsResultRequest().getFraudAlert(); + String actionTaken = tran.getMessageBody().getAfsResultRequest().getActionTaken(); + + String RetCommStatus = "S"; + Response rs = new Response(); + rs.setResult("Successful"); + MessageBody mb = new MessageBody(); + mb.setResponse(rs); + tran.setMessageBody(mb); + MessageEsbHead esbHead = tran.getMessageEsbHead(); + esbHead.setTargetMachineDate(DateUtils.dateNow()); + esbHead.setTargetMachineTime(DateUtils.TimeNowAccurate()); + esbHead.setTargetReciveDate(DateUtils.dateNow()); + esbHead.setTargetReciveTime(DateUtils.TimeNowAccurate()); + esbHead.setRetSystemId("APF"); + + esbHead.setRetCode("000000"); + esbHead.setRetMsg("ɹ"); + + BizObjectManager bom = null; + BizObject boRsr = null; + try { + bom = JBOFactory.getBizObjectManager(RC_SCORE_RESULT.CLASS_NAME); + boRsr = bom.createQuery("project_no=:projectNo").setParameter("projectNo",projectNo).getSingleResult(true); + boRsr.setAttributeValue("fraud_alert_code",fraudAlert); + boRsr.setAttributeValue("fraud_taken_code",actionTaken); + boRsr.setAttributeValue("update_time", DateUtils.dateTimeNowCore()); + bom.saveObject(boRsr); + } catch (JBOException e) { + e.printStackTrace(); + tran.setMessageBody(null); + RetCommStatus = "F"; + esbHead.setRetCode("99999"); + esbHead.setRetMsg("ʧܣ"+e.getErrorMessage()); + } + + esbHead.setRetCommStatus(RetCommStatus); + MessageAppHead appHead = tran.getMessageAppHead(); + appHead.setTargetTranDate(DateUtils.dateNow()); + appHead.setTargetTranTime(DateUtils.TimeNowAccurate()); + + String responseXml = XstreamUtil.xmlConvert(tran); + FileUtil.writeFile(logPath + projectNo +"_"+ globalSeqNo + RetCommStatus +"_response.txt", responseXml); + + return responseXml; + + } + + public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { + doPost(request, response); + } + + +} diff --git a/src/com/ample/esb/controller/AfsUrlController.java b/src/com/ample/esb/controller/AfsUrlController.java new file mode 100644 index 000000000..08139915a --- /dev/null +++ b/src/com/ample/esb/controller/AfsUrlController.java @@ -0,0 +1,99 @@ +package com.ample.esb.controller; + +import com.ample.esb.util.BaicPropertiesUtil; +import com.ample.esb.util.DateUtils; +import org.apache.commons.codec.binary.Hex; +import org.bouncycastle.util.io.pem.PemObject; +import org.bouncycastle.util.io.pem.PemReader; + +import javax.crypto.BadPaddingException; +import javax.crypto.Cipher; +import javax.crypto.IllegalBlockSizeException; +import javax.crypto.NoSuchPaddingException; +import java.io.FileReader; +import java.io.IOException; +import java.nio.charset.StandardCharsets; +import java.security.*; +import java.security.spec.InvalidKeySpecException; +import java.security.spec.X509EncodedKeySpec; +import java.util.Base64; + +public class AfsUrlController { + + public String encryptUrl() throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidKeySpecException, IllegalBlockSizeException, BadPaddingException, IOException { + String RSAPublicKey = BaicPropertiesUtil.get("RSAPublicKey"); + String sysId= "APF"; + String appKey = "BAFCN" + projectNo + "FLS"; + String dateTime = DateUtils.dateTimeNow(); + String hashString = BaicPropertiesUtil.get("afs_url")+"sysid="+sysId+"&appkey="+appKey+"&userId="+userId+"&datetime="+dateTime; + System.out.println("ƴӣ"+hashString); + MessageDigest md = MessageDigest.getInstance("SHA-256"); + byte[] bytes = md.digest(hashString.getBytes(StandardCharsets.UTF_8)); + String hashValue = Hex.encodeHexString(bytes); + String rsaString = hashString.substring(hashString.indexOf("redirect?")+"redirect?".length())+"&hash="+hashValue; + System.out.println("RSAܵݣ"+rsaString); + //todo Կļַ + //PublicKey publicKey = encryptRsaByFile(""); + PublicKey publicKey = encryptRsaByString(RSAPublicKey); + Cipher cipher = Cipher.getInstance("RSA"); + cipher.init(Cipher.ENCRYPT_MODE,publicKey); + byte[] encryptBytes = cipher.doFinal(rsaString.getBytes(StandardCharsets.UTF_8)); + System.out.println(Base64.getEncoder().encodeToString(encryptBytes)); + + return Base64.getEncoder().encodeToString(encryptBytes); + } + private String userId; + private String projectNo; + + public String getAfsUrl(){ + String ipAddress = BaicPropertiesUtil.get("afs_url"); + String encryptData = ""; + try { + encryptData = this.encryptUrl(); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } catch (NoSuchPaddingException e) { + e.printStackTrace(); + } catch (InvalidKeyException e) { + e.printStackTrace(); + } catch (InvalidKeySpecException e) { + e.printStackTrace(); + } catch (IllegalBlockSizeException e) { + e.printStackTrace(); + } catch (BadPaddingException e) { + e.printStackTrace(); + } catch (IOException e) { + e.printStackTrace(); + } + System.out.println(ipAddress+encryptData); + return ipAddress+encryptData; + } + public PublicKey encryptRsaByFile(String publicKeyPem) throws IOException, NoSuchAlgorithmException, InvalidKeySpecException { + PemReader pemReader = new PemReader(new FileReader(publicKeyPem)); + PemObject pemObject = pemReader.readPemObject(); + byte[] privateKeyBytes = pemObject.getContent(); + pemReader.close(); + PublicKey key = KeyFactory.getInstance("RSA").generatePublic(new X509EncodedKeySpec(privateKeyBytes)); + return key; + } + public PublicKey encryptRsaByString(String publicKey) throws NoSuchAlgorithmException, InvalidKeySpecException { + byte[] keyByte = Base64.getMimeDecoder().decode(publicKey.getBytes()); + PublicKey key = KeyFactory.getInstance("RSA").generatePublic(new X509EncodedKeySpec(keyByte)); + return key; + } + public String getUserId() { + return userId; + } + + public void setUserId(String userId) { + this.userId = userId; + } + + public String getProjectNo() { + return projectNo; + } + + public void setProjectNo(String projectNo) { + this.projectNo = projectNo; + } +} diff --git a/src/com/ample/esb/controller/AmpController.java b/src/com/ample/esb/controller/AmpController.java new file mode 100644 index 000000000..29e57caf2 --- /dev/null +++ b/src/com/ample/esb/controller/AmpController.java @@ -0,0 +1,54 @@ +package com.ample.esb.controller; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.ample.esb.bean.esb.Transaction; +import com.ample.esb.service.AmpService; +import com.ample.esb.service.impl.AmpServiceImpl; + +import java.util.HashMap; +import java.util.Map; + +public class AmpController { + private String operatorId; + private String flowUnid; + public String ampDo(JBOTransaction tx) throws Exception { + Map map = new HashMap(); + map.put("flowUnid",flowUnid); + map.put("operatorId",operatorId); + AmpService as = new AmpServiceImpl(map); + Transaction tran = as.transactionDo(); + String result = resultAnalysis(tran); + return result; + } + + public String resultAnalysis(Transaction tran){ + String response = ""; + String retCode = tran.getMessageEsbHead().getRetCode(); + if("000000".equals(retCode)){ + response = "ɹ"; + }else{ + response = "ִ󣬴룺"+retCode+".ϵϵͳԱ"; + } + return response; + } + + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } + + public String getFlowUnid() { + return flowUnid; + } + + public void setFlowUnid(String flowUnid) { + this.flowUnid = flowUnid; + } + + + +} diff --git a/src/com/ample/esb/server/ScoreResultServlet.java b/src/com/ample/esb/server/ScoreResultServlet.java new file mode 100644 index 000000000..641fd6388 --- /dev/null +++ b/src/com/ample/esb/server/ScoreResultServlet.java @@ -0,0 +1,157 @@ +package com.ample.esb.server; +import com.alibaba.fastjson.JSONObject; +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.*; +import com.ample.esb.bean.esb.*; +import com.ample.esb.util.BaicPropertiesUtil; +import com.ample.esb.util.DateUtils; +import com.ample.esb.util.XstreamUtil; +import com.ample.sms.FileUtil; +import com.ample.sms.WriteRptThread; +import com.tenwa.httpclient.pboc.PbocXmlUtils; +import com.tenwa.reckon.util.UUIDUtil; +import jbo.oti.RC_CALLBACK_LOG; +import jbo.oti.RC_SCORE_RESULT; +import jbo.oti.RC_SCORE_RESULT_LOG; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.*; +import java.text.SimpleDateFormat; +import java.util.Date; + +/** + * ֽͽսӿ + */ +public class ScoreResultServlet extends HttpServlet { + public ScoreResultServlet() { + } + + private static final long serialVersionUID = 1L; + public void doPost(HttpServletRequest request, HttpServletResponse response) { + System.out.println("ֽͽսӿصʼ!"); + response.setContentType("application/xml;charset:utf-8"); + response.setHeader("Cache-Control", "no-store"); + response.setHeader("Pragma", "no-cache"); + response.setDateHeader("Expires", 0L); + response.setCharacterEncoding("utf-8"); + PrintWriter out = null; + String resultXml = null; + String res = null; + try { + out = response.getWriter(); + BufferedReader in = new BufferedReader(new InputStreamReader(request.getInputStream(), "UTF-8")); + StringBuilder sb = new StringBuilder(); + String line = null; + while ((line = in.readLine()) != null) { + sb.append(line); + } + resultXml = sb.toString(); + ARE.getLog().info("յRpt¼" + resultXml); + } catch (Exception e) { + e.printStackTrace(); + } + out.print(updateResult(resultXml)); + System.out.println("ֽͽսӿص!"); + out.close(); + + } + + private void savePushLog(String xmlRes) throws Exception{ + JBOTransaction tx = null; + try{ + if (!WriteScoreResultThread.rptIsAlive()) { + WriteScoreResultThread.getRptthread().start(); + } + tx = JBOFactory.createJBOTransaction(); + JSONObject resStrJson = PbocXmlUtils.toJson(xmlRes); + JSONObject resJsonTransaction = resStrJson.getJSONObject("TRANSACTION");// + JSONObject resJsonMessageBody = resJsonTransaction.getJSONObject("MESSAGE_BODY");// + JSONObject resJsonRequest = resJsonMessageBody.getJSONObject("REQUEST");// + JSONObject resJson = resJsonRequest.getJSONObject("APPLICATION");// +// JSONObject resJson = resStrJson.getJSONObject("APPLICATION");// + JSONObject baseInfoJson = resJson.getJSONObject("BASE_INFO");// + String projectNo = baseInfoJson.getString("APPLICATION_NUMBER");// + BizObjectManager rcCallbackLog = JBOFactory.getBizObjectManager(RC_CALLBACK_LOG.CLASS_NAME, tx); + BizObject rcCallbackLogBizObject = rcCallbackLog.newObject(); + rcCallbackLogBizObject.setAttributeValue("project_no", projectNo); + rcCallbackLogBizObject.setAttributeValue("callback_data", xmlRes); + // ͽֽͣ score, թ fraud + rcCallbackLogBizObject.setAttributeValue("callback_type", "score"); + rcCallbackLogBizObject.setAttributeValue("handle_sts", "0"); + rcCallbackLogBizObject.setAttributeValue("handle_value", ""); + String callBackLogId = UUIDUtil.getUUID(); + rcCallbackLogBizObject.setAttributeValue("callback_id", callBackLogId); + SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss"); //ڸʽ + String date = sdf.format(new Date()); //ϵͳʱתϷָ + rcCallbackLogBizObject.setAttributeValue("input_time", date); + rcCallbackLogBizObject.setAttributeValue("update_time", date); + rcCallbackLog.saveObject(rcCallbackLogBizObject); + resStrJson.put("callBackLogId", callBackLogId); + WriteScoreResultThread.scoreResultQueue.put(resStrJson); + } catch (Exception e) { + tx.rollback(); + e.printStackTrace(); + throw new RuntimeException(e); + } finally { + try { + if (tx != null) { + tx.commit(); + } + } catch (JBOException e) { + e.printStackTrace(); + throw new RuntimeException(e); + } + } + + + } + + public String updateResult(String requestXml) { + Transaction tran = (Transaction) XstreamUtil.objectConvert(requestXml); + String logPath = BaicPropertiesUtil.get("log_path"); + String globalSeqNo = tran.getMessageEsbHead().getGlobalSeqNo(); + String projectNo = tran.getMessageBody().getAfsResultRequest().getApplyNo(); + FileUtil.writeFile(logPath + projectNo +"_"+ globalSeqNo +"_request.txt", requestXml); + String RetCommStatus = "S"; + Response rs = new Response(); + rs.setResult("Successful"); + MessageBody mb = new MessageBody(); + mb.setResponse(rs); + tran.setMessageBody(mb); + MessageEsbHead esbHead = tran.getMessageEsbHead(); + esbHead.setTargetMachineDate(DateUtils.dateNow()); + esbHead.setTargetMachineTime(DateUtils.TimeNowAccurate()); + esbHead.setTargetReciveDate(DateUtils.dateNow()); + esbHead.setTargetReciveTime(DateUtils.TimeNowAccurate()); + esbHead.setRetCode("000000"); + esbHead.setRetMsg("ɹ"); + esbHead.setRetSystemId("APF"); + try { + savePushLog(requestXml); + } catch (Exception e) { + e.printStackTrace(); + tran.setMessageBody(null); + RetCommStatus = "F"; + esbHead.setRetCode("99999"); + esbHead.setRetMsg("ʧܣ"+e.getMessage()); + } + esbHead.setRetCommStatus(RetCommStatus); + MessageAppHead appHead = tran.getMessageAppHead(); + appHead.setTargetTranDate(DateUtils.dateNow()); + appHead.setTargetTranTime(DateUtils.TimeNowAccurate()); + + String responseXml = XstreamUtil.xmlConvert(tran); + FileUtil.writeFile(logPath + projectNo +"_"+ globalSeqNo +"_response.txt", responseXml); + + return responseXml; + + } + + public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { + doPost(request, response); + } + +} diff --git a/src/com/ample/esb/server/WriteScoreResultThread.java b/src/com/ample/esb/server/WriteScoreResultThread.java new file mode 100644 index 000000000..e8b3fbc1b --- /dev/null +++ b/src/com/ample/esb/server/WriteScoreResultThread.java @@ -0,0 +1,345 @@ +package com.ample.esb.server; + +import com.alibaba.fastjson.JSONArray; +import com.alibaba.fastjson.JSONObject; +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.*; +import com.ample.sms.FileUtil; +import com.tenwa.httpclient.pboc.PbocXmlUtils; +import com.tenwa.reckon.util.UUIDUtil; +import jbo.app.tenwa.customer.CUSTOMER_FAMILY_TEMP; +import jbo.app.tenwa.customer.CUSTOMER_PERSON; +import jbo.app.tenwa.customer.CUSTOMER_PERSON_TEMP; +import jbo.com.tenwa.lease.comm.LB_GUARANTEE_UNIT_TEMP; +import jbo.com.tenwa.lease.comm.LB_PROJECT_INFO_TEMP; +import jbo.com.tenwa.lease.comm.LB_SMS_NOTICE_TASKS; +import jbo.oti.*; +import org.apache.commons.collections.CollectionUtils; +import org.dom4j.DocumentException; + +import java.text.SimpleDateFormat; +import java.util.*; +import java.util.concurrent.LinkedBlockingQueue; + +public class WriteScoreResultThread extends Thread{ + public static LinkedBlockingQueue scoreResultQueue = new LinkedBlockingQueue<>(); + private static boolean STOP = false; + private static Thread rptThread = new WriteScoreResultThread(); + private SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); + + private WriteScoreResultThread() { + } + + public void run() { + STOP = false; + try { + while(!STOP) { + JSONObject resJson = scoreResultQueue.take(); + saveSmsRpt(resJson); + } + } catch (Exception var5) { + var5.printStackTrace(); + STOP = true; + rptThread = null; + } + + } + + public static boolean rptIsAlive() { + return rptThread.isAlive(); + } + + public static Thread getRptthread() { + if (rptThread == null) { + rptThread = new WriteScoreResultThread(); + } + + return rptThread; + } + public void saveSmsRpt(JSONObject resJson) throws JBOException, DocumentException { + saveUpdateScoreResult("score", resJson); + + + } + + /** + * ݵʵ + * @param type ֽͣ score, թ fraud + * @param resStrJson + */ + private void saveUpdateScoreResult(String type, JSONObject resStrJson) throws JBOException { + JBOTransaction tx = null; + try{ + tx = JBOFactory.createJBOTransaction(); + JSONObject resJsonTransaction = resStrJson.getJSONObject("TRANSACTION");// + JSONObject resJsonMessageBody = resJsonTransaction.getJSONObject("MESSAGE_BODY");// + JSONObject resJsonRequest = resJsonMessageBody.getJSONObject("REQUEST");// + JSONObject resJson = resJsonRequest.getJSONObject("APPLICATION");// +// JSONObject resJson = resStrJson.getJSONObject("APPLICATION");// + JSONObject baseInfoJson = resJson.getJSONObject("BASE_INFO");// + String projectNo = baseInfoJson.getString("APPLICATION_NUMBER");// + String tranNo = baseInfoJson.getString("TRAN_NO");//ˮ + String flowNo = queryProjectTemp(projectNo); + ARE.getLog().info("WriteScoreResultThread#saveUpdateScoreResulttranNo=" + tranNo); + // : 2023-8-24 + SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss"); //ڸʽ + String date = sdf.format(new Date()); //ϵͳʱתϷָ + String resultId = UUIDUtil.getUUID(); + JSONObject blazeResultJson = resJson.getJSONObject("BLAZERESULT");//ֽ + String resultCode = blazeResultJson.getString("RESULT_CODE");// ֽ״̬ 1000Ϊɹʧ + String result = blazeResultJson.getString("RESULT");//ֽ AA RR RD DD + String thirdResultUrl = "http://10.91.122.11:8081/baicaplcredit/businessFlow/rzzlCreditResultForThirdParty.jsp?applicationNo=" + + projectNo + "&transNo=" + tranNo; + + JSONObject fraudResultJson = resJson.getJSONObject("FRAUD_RESULT");// թ + String fraudAlert = null;// թԤHSC + String actionTaken = null;// թжFKS + if(null != fraudResultJson){ + fraudAlert = fraudResultJson.getString("FRAUD_ALERT");// թԤHSC + actionTaken = fraudResultJson.getString("ACTION_TAKEN");// թжFKS + }else { + ARE.getLog().error("WriteScoreResultThread#saveUpdateScoreResult ---FRAUD_ALERT-թΪա-----------tranNo=" + tranNo); + } + + //ֽ + BizObjectManager rcScoreResult = JBOFactory.getBizObjectManager(RC_SCORE_RESULT.CLASS_NAME, tx); + BizObject rcScoreResultBizObject = rcScoreResult.createQuery("project_no=:project_no").setParameter("project_no", projectNo).getSingleResult(true); + if(null == rcScoreResultBizObject){ + rcScoreResultBizObject = rcScoreResult.newObject(); + rcScoreResultBizObject.setAttributeValue("score_result_id", resultId); + rcScoreResultBizObject.setAttributeValue("project_no", projectNo); + rcScoreResultBizObject.setAttributeValue("flow_no", flowNo); + rcScoreResultBizObject.setAttributeValue("input_time", date); + }else { + resultId = rcScoreResultBizObject.getAttribute("score_result_id").toString(); + } + rcScoreResultBizObject.setAttributeValue("tran_no", tranNo);//ˮ + rcScoreResultBizObject.setAttributeValue("score_result_code", result);// ֽ AA RR RD DD + rcScoreResultBizObject.setAttributeValue("score_result_url", thirdResultUrl);// ֽ + rcScoreResultBizObject.setAttributeValue("fraud_alert_code", fraudAlert);// թԤHSC + rcScoreResultBizObject.setAttributeValue("fraud_taken_code", actionTaken);// թжFKS + rcScoreResultBizObject.setAttributeValue("update_time", date); + rcScoreResult.saveObject(rcScoreResultBizObject); + + // ֽϸ + if("score".equals(type)){ + BizObjectManager rcScoreResultDetail = JBOFactory.getBizObjectManager(RC_SCORE_RESULT_DETAIL.CLASS_NAME, tx); + List rcScoreResultDetailBizObjectList = rcScoreResultDetail.createQuery("project_no=:project_no").setParameter("project_no", projectNo).getResultList(true); + if(CollectionUtils.isEmpty(rcScoreResultDetailBizObjectList)){ + rcScoreResultDetailBizObjectList = initScoreResultDetailBizObjectList(rcScoreResultDetail, flowNo, projectNo, tranNo, resultId, date); + } + JSONObject personListObj = resJson.getJSONObject("NCIICS");//ʵ֤б + if(null == personListObj) { + ARE.getLog().warn("WriteScoreResultThread#saveUpdateScoreResultNCIICS is null 1 projectNo=" + projectNo); + }else{ + JSONArray personList = parseArray(personListObj, "NCIIC");;//ʵ֤б + if(null == personList) { + ARE.getLog().warn("WriteScoreResultThread#saveUpdateScoreResultNCIICS is null 2 projectNo=" + projectNo); + }else { + for(int i = 0; i < personList.size(); i++){ + for(BizObject scoreResBiz : rcScoreResultDetailBizObjectList){ + if(personList.getJSONObject(i).getString("APPLICANTIDNUMBER").equals(scoreResBiz.getAttribute("person_card_no").toString())){ + scoreResBiz.setAttributeValue("third_state_code", personList.getJSONObject(i).getString("THIRDSTATECODE")); + scoreResBiz.setAttributeValue("name_result", personList.getJSONObject(i).getString("NAMERESULT")); + scoreResBiz.setAttributeValue("cert_id_result", personList.getJSONObject(i).getString("CERTINORESULT")); + scoreResBiz.setAttributeValue("error_message", personList.getJSONObject(i).getString("ERRORMESSAGE")); + } + } + } + } + } + + JSONObject scoreResultsObj = resJson.getJSONObject("BLAZERESULT");//б + if(null == scoreResultsObj) { + ARE.getLog().warn("WriteScoreResultThread#saveUpdateScoreResultBLAZERESULT is null 1 projectNo=" + projectNo); + }else { + JSONObject scoreResultsObjRes = scoreResultsObj.getJSONObject("SCORERESULTS");//б + if (null == scoreResultsObjRes) { + ARE.getLog().warn("WriteScoreResultThread#saveUpdateScoreResultBLAZERESULT is null 2 projectNo=" + projectNo); + } else { + JSONArray scoreResults = parseArray(scoreResultsObjRes, "SCORERESULT"); + if (null == scoreResults) { + ARE.getLog().warn("WriteScoreResultThread#saveUpdateScoreResultBLAZERESULT is null 3 projectNo=" + projectNo); + } else { + for(int i = 0; i < scoreResults.size(); i++){ + JSONObject indexResJson = scoreResults.getJSONObject(i); + String idCard = indexResJson.getString("ID_CARD_NBR"); + for(BizObject scoreResBiz : rcScoreResultDetailBizObjectList){ + if(idCard.equals(scoreResBiz.getAttribute("person_card_no").toString())){ + scoreResBiz.setAttributeValue("score_level", scoreResults.getJSONObject(i).getString("SCORE_LEVEL")); + } + } + } + for(BizObject scoreResBiz : rcScoreResultDetailBizObjectList){//ϸ + scoreResBiz.setAttributeValue("update_time", date); + scoreResBiz.setAttributeValue("third_result_url", thirdResultUrl); + scoreResBiz.setAttributeValue("tran_no", tranNo);//ˮ + scoreResBiz.setAttributeValue("pboc_result_url", "www.baidu.com"); + rcScoreResultDetail.saveObject(scoreResBiz); + } + } + } + } + } + // ־ + BizObjectManager rcScoreResultLog = JBOFactory.getBizObjectManager(RC_SCORE_RESULT_LOG.CLASS_NAME, tx); + BizObject rcScoreResultLogBizObject = rcScoreResultLog.newObject(); + rcScoreResultLogBizObject.setAttributeValue("score_result_id", resultId); + rcScoreResultLogBizObject.setAttributeValue("project_no", projectNo); + rcScoreResultLogBizObject.setAttributeValue("tran_no", tranNo); + rcScoreResultLogBizObject.setAttributeValue("flow_no", flowNo); + rcScoreResultLogBizObject.setAttributeValue("score_result_url", thirdResultUrl);// ֽ + rcScoreResultLogBizObject.setAttributeValue("score_result_code", result);// ֽ AA RR RD DD + rcScoreResultLogBizObject.setAttributeValue("fraud_alert_code", fraudAlert);// թԤHSC + rcScoreResultLogBizObject.setAttributeValue("fraud_taken_code", actionTaken);// թжFKS + rcScoreResultLogBizObject.setAttributeValue("input_time", date); + rcScoreResultLog.saveObject(rcScoreResultLogBizObject); + + // »صӿִ״̬ + String callBackLogId = resStrJson.getString("callBackLogId");//־logID + BizObjectManager rcCallbackLog = JBOFactory.getBizObjectManager(RC_CALLBACK_LOG.CLASS_NAME, tx); + BizObject rcCallbackLogBizObject = rcCallbackLog.createQuery("callback_id=:callback_id").setParameter("callback_id", callBackLogId).getSingleResult(true); + rcCallbackLogBizObject.setAttributeValue("handle_sts", "1"); + rcCallbackLogBizObject.setAttributeValue("handle_value", "Ѵ"); + rcCallbackLogBizObject.setAttributeValue("update_time", date); + rcCallbackLog.saveObject(rcCallbackLogBizObject); + + } catch (Exception e) { + tx.rollback(); + e.printStackTrace(); + } finally { + try { + if (tx != null) { + tx.commit(); + } + } catch (JBOException e) { + e.printStackTrace(); + } + } + } + + private JSONArray parseArray(JSONObject jsonObject, String key){ + JSONArray resArr = null; + try { + if(isJsonArray(jsonObject, key)){ + resArr = jsonObject.getJSONArray(key);//б + }else { + resArr = new JSONArray(); + resArr.add(jsonObject.getJSONObject(key)); + } + }catch (Exception e){ + e.printStackTrace(); + } + return resArr; + } + + private boolean isJsonArray(JSONObject jsonObject, String key){ + try { + jsonObject.getJSONArray(key); + }catch (Exception e){ + e.printStackTrace(); + return false; + } + return true; + } + + + private String queryProjectTemp(String projectNo) throws JBOException { + String flowNo = null; + ARE.getLog().info("WriteScoreResultThread#saveUpdateScoreResultflowNo=" + flowNo); + BizObjectManager lbProjectInfo = JBOFactory.getBizObjectManager(LB_PROJECT_INFO_TEMP.CLASS_NAME);// ĿϢ + List lbProjectInfoBizObjectList = lbProjectInfo.createQuery("PROJECT_NO=:PROJECT_NO").setParameter("PROJECT_NO", projectNo).getResultList(false); + if(CollectionUtils.isNotEmpty(lbProjectInfoBizObjectList)){ + for(BizObject lbProject : lbProjectInfoBizObjectList){ + if(null == flowNo){ + flowNo = lbProject.getAttribute("FLOWUNID").toString(); + ARE.getLog().info("WriteScoreResultThread#saveUpdateScoreResultflowNoTempLong=" + flowNo.substring(3)); + }else { + String flowNoTemp = lbProject.getAttribute("FLOWUNID").toString(); + ARE.getLog().info("WriteScoreResultThread#saveUpdateScoreResultflowNoTemp=" + flowNo); + if(Long.parseLong(flowNo.substring(3)) < Long.parseLong(flowNoTemp.substring(3))){ + flowNo = flowNoTemp; + } + } + } + } + return flowNo; + } + + + /** + * ϸ + * @param rcScoreResultDetail + * @param flowNo + * @param projectNo + * @param tranNo ˮ + * @param resultId + * @return + * @throws JBOException + */ + private List initScoreResultDetailBizObjectList(BizObjectManager rcScoreResultDetail, String flowNo, String projectNo, String tranNo, String resultId, String date) throws JBOException { + List rcScoreResultDetailBizObjectList = new ArrayList<>(); + // + BizObjectManager customerPerson = JBOFactory.getBizObjectManager(CUSTOMER_PERSON_TEMP.CLASS_NAME); + BizObject customerPersonBizObject = customerPerson.createQuery("flowunid=:flowunid").setParameter("flowunid", flowNo).getSingleResult(false); + BizObject rcScoreResultDetailCustomerPersonBizObject = rcScoreResultDetail.newObject(); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("score_result_detail_id", UUIDUtil.getUUID()); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("score_result_id", resultId); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("project_no", projectNo); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("tran_no", tranNo); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("flow_no", flowNo); + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("person_type", "01");// + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("person_name", + customerPersonBizObject.getAttribute("FULLNAME").toString());// + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("person_card_type", + customerPersonBizObject.getAttribute("CERTTYPE").toString());// + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("person_card_no", + customerPersonBizObject.getAttribute("CERTID").toString());// + rcScoreResultDetailCustomerPersonBizObject.setAttributeValue("input_time", date); + rcScoreResultDetailBizObjectList.add(rcScoreResultDetailCustomerPersonBizObject); + // ͬ + BizObjectManager customerFamily = JBOFactory.getBizObjectManager(CUSTOMER_FAMILY_TEMP.CLASS_NAME); + BizObject customerFamilyBizObject = customerFamily.createQuery("flowunid=:flowunid and Partner_='Y'") + .setParameter("flowunid", flowNo).getSingleResult(false); + if(null != customerFamilyBizObject){ + BizObject rcScoreResultDetailCustomerFamilyBizObject = rcScoreResultDetail.newObject(); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("score_result_detail_id", UUIDUtil.getUUID()); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("score_result_id", resultId); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("project_no", projectNo); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("tran_no", tranNo); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("flow_no", flowNo); + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("person_type", "02");//ͬ + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("person_name", + customerFamilyBizObject.getAttribute("name").toString());//ͬ + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("person_card_type", + customerFamilyBizObject.getAttribute("certtype").toString());//ͬ + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("person_card_no", + customerFamilyBizObject.getAttribute("certid").toString());//ͬ + rcScoreResultDetailCustomerFamilyBizObject.setAttributeValue("input_time", date); + rcScoreResultDetailBizObjectList.add(rcScoreResultDetailCustomerFamilyBizObject); + } + // + BizObjectManager guaranteeUnit = JBOFactory.getBizObjectManager(LB_GUARANTEE_UNIT_TEMP.CLASS_NAME); + List guaranteeUnitBizObjectList = guaranteeUnit.createQuery("FLOWUNID=:FLOWUNID").setParameter("FLOWUNID", flowNo).getResultList(false); + if(CollectionUtils.isNotEmpty(guaranteeUnitBizObjectList)){ + for(BizObject guarantee : guaranteeUnitBizObjectList){ + BizObject rcScoreResultDetailGuaranteeUnitBizObject = rcScoreResultDetail.newObject(); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("score_result_detail_id", UUIDUtil.getUUID()); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("score_result_id", resultId); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("project_no", projectNo); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("tran_no", tranNo); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("flow_no", flowNo); + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("person_type", "03");// + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("person_name", + guarantee.getAttribute("FULLNAME").toString());// + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("person_card_type", + guarantee.getAttribute("CERTTYPE").toString());// + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("person_card_no", + guarantee.getAttribute("CERTID").toString());// + rcScoreResultDetailGuaranteeUnitBizObject.setAttributeValue("input_time", date); + rcScoreResultDetailBizObjectList.add(rcScoreResultDetailGuaranteeUnitBizObject); + } + } + return rcScoreResultDetailBizObjectList; + } +} diff --git a/src/com/ample/esb/service/AmpService.java b/src/com/ample/esb/service/AmpService.java new file mode 100644 index 000000000..8b845f67c --- /dev/null +++ b/src/com/ample/esb/service/AmpService.java @@ -0,0 +1,8 @@ +package com.ample.esb.service; + +import com.ample.esb.bean.amp.ApplicationTitle; + +public interface AmpService extends EsbServise{ + ApplicationTitle getApplicationTitle() throws Exception; + +} diff --git a/src/com/ample/esb/service/EsbServise.java b/src/com/ample/esb/service/EsbServise.java new file mode 100644 index 000000000..fba9d6e93 --- /dev/null +++ b/src/com/ample/esb/service/EsbServise.java @@ -0,0 +1,7 @@ +package com.ample.esb.service; + +import com.ample.esb.bean.esb.Transaction; + +public interface EsbServise { + Transaction transactionDo(); +} diff --git a/src/com/ample/esb/service/impl/AccountSyncServiceImpl.java b/src/com/ample/esb/service/impl/AccountSyncServiceImpl.java new file mode 100644 index 000000000..1dadd7938 --- /dev/null +++ b/src/com/ample/esb/service/impl/AccountSyncServiceImpl.java @@ -0,0 +1,55 @@ +package com.ample.esb.service.impl; + +import com.ample.esb.bean.afs.AccountSyncRequest; +import com.ample.esb.bean.esb.MessageAppHead; +import com.ample.esb.bean.esb.MessageBody; +import com.ample.esb.bean.esb.MessageEsbHead; +import com.ample.esb.common.EsbCommon; + +public class AccountSyncServiceImpl extends EsbCommon { + + private AccountSyncRequest accountSyncRequest; + + public AccountSyncServiceImpl(AccountSyncRequest asr) { + setAccountSyncRequest(asr); + } + @Override + public MessageEsbHead esbHead() { + MessageEsbHead head = new MessageEsbHead(); + head = super.getCommonEsbHead(head); + head.setTargetSystemId("AFS"); + head.setServiceId("SCN0003"); + head.setServiceVersion("1.0.0"); + head.setScenesId("019"); + head.setScenesVersion("1.0"); + head.setTranCode("AFS012"); + head.setCommType("00"); + head.setChannelId("09"); + head.setFileFlag("0"); + return head; + } + + @Override + public MessageAppHead appHead() { + MessageAppHead head = new MessageAppHead(); + head = super.getCommonAppHead(head); + head.setOperatorId(accountSyncRequest.getOperatorId()); + return head; + } + + @Override + public MessageBody messgeBody() { + MessageBody body = new MessageBody(); + body = super.getCommonBody(body); + body.setRequest(accountSyncRequest); + return body; + } + + public AccountSyncRequest getAccountSyncRequest() { + return accountSyncRequest; + } + + public void setAccountSyncRequest(AccountSyncRequest accountSyncRequest) { + this.accountSyncRequest = accountSyncRequest; + } +} diff --git a/src/com/ample/esb/service/impl/AmpServiceImpl.java b/src/com/ample/esb/service/impl/AmpServiceImpl.java new file mode 100644 index 000000000..c9059d19e --- /dev/null +++ b/src/com/ample/esb/service/impl/AmpServiceImpl.java @@ -0,0 +1,1128 @@ +package com.ample.esb.service.impl; + +import com.amarsoft.app.util.ProductParamUtil; +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.BizObjectManager; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; +import com.amarsoft.dict.als.manage.CodeManager; +import com.ample.esb.bean.amp.*; +import com.ample.esb.bean.esb.MessageAppHead; +import com.ample.esb.bean.esb.MessageBody; +import com.ample.esb.bean.esb.MessageEsbHead; +import com.ample.esb.common.EsbCommon; +import com.ample.esb.common.ParamDataUtils; +import com.ample.esb.service.AmpService; +import com.ample.esb.util.DateUtils; +import com.ample.esb.util.XstreamUtil; +import jbo.app.tenwa.calc.*; +import jbo.app.tenwa.customer.*; +import jbo.com.tenwa.lease.comm.*; +import jbo.oti.RC_ADDRESS_INFO; +import jbo.prd.PRD_SPECIFIC_LIBRARY; +import jbo.sys.FLOW_TASK; + +import java.math.BigDecimal; +import java.util.*; + +public class AmpServiceImpl extends EsbCommon implements AmpService { + private String flowUnid; + private String operatorId; + public AmpServiceImpl(Map map){ + setFlowUnid(map.get("flowUnid")); + setOperatorId(map.get("operatorId")); + } + @Override + public MessageEsbHead esbHead() { + MessageEsbHead head = new MessageEsbHead(); + head = super.getCommonEsbHead(head); + head.setTargetSystemId("AMP"); + head.setServiceId("SCN0003"); + head.setServiceVersion("1.0.0"); + head.setScenesId("018"); + head.setScenesVersion("1.0"); + head.setTranCode("AMP005"); + head.setCommType("10"); + head.setChannelId("09"); + head.setFileFlag("0"); + return head; + } + + @Override + public MessageAppHead appHead() { + MessageAppHead head = new MessageAppHead(); + head = super.getCommonAppHead(head); + head.setOperatorId(operatorId); + return head; + } + + @Override + public MessageBody messgeBody() { + MessageBody body = new MessageBody(); + body = super.getCommonBody(body); + body.setAmpRequest(getRequestBody()); + return body; + } + + public AmpRequest getRequestBody() { + String requestInfo = XstreamUtil.xmlConvertNotTitle(getApplicationTitle()); + requestInfo = "" + requestInfo + "]]>"; + AmpRequest ampRequest = new AmpRequest(); + ampRequest.setApplication(requestInfo); + return ampRequest; + } + @Override + public ApplicationTitle getApplicationTitle() { + ApplicationTitle app = new ApplicationTitle(); + try{ + this.init(); + Applicant2 app2 = new Applicant2(); + app2.setDealerInfo(getDealerInfo()); + app2.setLoanInfo(getLoanInfo()); + app2.setVehicleInfo(getVehicleInfo()); + app2.setCustomerInfo(getCustomerInfo()); + app2.setCoborrowers(getCoborrowers()); + app2.setGuarantorInfo(getGuarantorInfo()); + app2.setContInfo(getContInfo()); + app2.setApplicationInfo(getApplicationInfo()); + app2.setPreviouslyVehicle(getPreviouslyVehicle()); + app.setApplicant2(app2); + }catch (Exception e){ + e.printStackTrace(); + } + return app; + } + // + //ʱ + private BizObject boLpit; + //ʱ + private BizObject boCpt; + //ʱ + private BizObject boLcct; + //ʱ + private List boLects; + + private List boLguts; + + private BizObjectManager bomLpi; + + private BizObject boCft; + //ʽ + private BizObject boDi; + /** + * beanֵ + * @throws JBOException + */ + public void init() throws JBOException { + boLpit = JBOFactory.createBizObjectQuery(LB_PROJECT_INFO_TEMP.CLASS_NAME,"FLOWUNID=:FLOWUNID").setParameter("FLOWUNID",flowUnid).getSingleResult(false); + /*if(boLpit==null||boLpit.getAttribute("ID")==null||"".equals(boLpit.getAttribute("ID").toString())){ + return; + }*/ + boCpt = JBOFactory.createBizObjectQuery(CUSTOMER_PERSON_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + + boLects = JBOFactory.createBizObjectQuery(LB_EQUIPMENT_CAR_TEMP.CLASS_NAME,"FLOWUNID=:FLOWUNID").setParameter("FLOWUNID",flowUnid).getResultList(false); + + boLcct = JBOFactory.createBizObjectQuery(LC_CALC_CONDITION_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + + bomLpi = JBOFactory.getBizObjectManager(LB_PROJECT_INFO.CLASS_NAME); + + String distributorNo = boLpit.getAttribute("distributor_id").toString(); + boDi = JBOFactory.createBizObjectQuery(DISTRIBUTOR_INFO.CLASS_NAME,"DISTRIBUTOR_NO=:distributorNo").setParameter("distributorNo",distributorNo).getSingleResult(false); + boCft = JBOFactory.createBizObjectQuery(CUSTOMER_FAMILY_TEMP.CLASS_NAME,"FLOWUNID=:flowunid and Partner_='Y'").setParameter("flowunid",flowUnid).getSingleResult(false); + boLguts = JBOFactory.createBizObjectQuery(LB_GUARANTEE_UNIT_TEMP.CLASS_NAME,"FLOWUNID=:flowunid ").setParameter("flowunid",flowUnid).getResultList(false); + + } + public DealerInfo getDealerInfo() throws JBOException { + if(boDi==null||boDi.getAttribute("ID")==null||"".equals(boDi.getAttribute("ID").toString())){ + return null; + } + String distributorNo = boLpit.getAttribute("distributor_id").toString(); + DealerInfo di = new DealerInfo(); + // + di.setDealerName(boDi.getAttribute("DISTRIBUTOR_NAME").toString()); + //̱ + di.setDealerId(distributorNo); + di.setDealerMode(""); + String addressCode = boDi.getAttribute("DISTRIBUTOR_ADDRESS").getString(); + String dealerProvince = ParamDataUtils.queryMapBcProvinceCode("AreaCode",addressCode); + String dealerCity = ParamDataUtils.queryMapBcCityCode("AreaCode",addressCode); + di.setDealerProvince_gb(dealerProvince); + di.setDealerCity_gb(dealerCity); + di.setDealerDistrict_gb(""); + di.setDealerStreet_gb(""); + di.setSubDealerName(""); + di.setDealerGuaranteeRatio(""); + di.setDealerFiledVisitFlag(""); + di.setSubDealerAppFlag(""); + di.setDealerArea(""); + di.setSubDealerCode(""); + di.setDealerTotalUsedAmount(""); + di.setDealerAvailableAmount(""); + + + int monthApproveCount = bomLpi.createQuery("select 1 from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.id where o.distributor_id=:distributor_id and o.project_status='13' and left(o.INPUTTIME,7)=:curMonth").setParameter("distributor_id",distributorNo).setParameter("curMonth", DateUtils.monthNowCore()).getTotalCount(); + int monthFailCount = bomLpi.createQuery("select 1 from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.id where o.distributor_id=:distributor_id and o.PROJECT_STATUS<>'13' and left(o.INPUTTIME,7)=:curMonth").setParameter("distributor_id",distributorNo).setParameter("curMonth",DateUtils.monthNowCore()).getTotalCount(); + di.setApprovalCountThisMonth(monthApproveCount); + di.setRefuseCountThisMonth(monthFailCount); + BizObjectManager bomLfi = JBOFactory.getBizObjectManager(LC_FUND_INCOME.CLASS_NAME); + int monthLoanCount = bomLfi.createQuery("select 1 from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.project_id left join jbo.com.tenwa.lease.comm.LB_PROJECT_INFO lpi on lpi.id=o.project_id where o.pay_type = 'pay_type_out' and o.PAY_STATUS='have_paid' and o.FEE_TYPE='feetype10' and o.SETTLE_METHOD='settlemethod6' and left(o.fact_date,7)=:curMonth and lpi.distributor_id=:distributor_id").setParameter("distributor_id",distributorNo).setParameter("curMonth",DateUtils.monthNowCore()).getTotalCount(); + di.setLoanCountThisMonth(monthLoanCount); + int yearApproveCount = bomLpi.createQuery("select 1 from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.id where o.distributor_id=:distributor_id and o.project_status='13' and left(o.INPUTTIME,4)=:curYear").setParameter("distributor_id",distributorNo).setParameter("curYear",DateUtils.yearNow()).getTotalCount(); + int yearFailCount = bomLpi.createQuery("select 1 from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.id where o.distributor_id=:distributor_id and o.PROJECT_STATUS<>'13' and left(o.INPUTTIME,4)=:curYear").setParameter("distributor_id",distributorNo).setParameter("curYear",DateUtils.yearNow()).getTotalCount(); + int yearLoanCount = bomLfi.createQuery("select FACT_MONEY from o left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on lec.project_id=o.project_id left join jbo.com.tenwa.lease.comm.LB_PROJECT_INFO lpi on lpi.id=o.project_id where o.pay_type = 'pay_type_out' and o.PAY_STATUS='have_paid' and o.FEE_TYPE='feetype10' and o.SETTLE_METHOD='settlemethod6' and left(o.fact_date,4)=:curYear and lpi.distributor_id=:distributor_id").setParameter("distributor_id",distributorNo).setParameter("curYear",DateUtils.yearNow()).getTotalCount(); + di.setApprovalCountThisYear(yearApproveCount); + di.setRefuseCountThisYear(yearFailCount); + di.setLoanCountThisYear(yearLoanCount); + + return di; + } + public LoanInfo getLoanInfo() throws Exception { + + LoanInfo li = new LoanInfo(); + li.setProductId(boLpit.getAttribute("PRODUCT_ID").toString()); + li.setProductName(boLpit.getAttribute("PRODUCT_NAME").toString()); + String settleMethod = boLcct.getAttribute("SETTLE_METHOD").toString(); + li.setProductType(ParamDataUtils.queryBcEnumType("SETTLE_METHOD",settleMethod)); + li.setSubsityTypeCode(""); + //ʣƷʣ + String productRate = ProductParamUtil.getProductParameterValue(boLpit.getAttribute("PRODUCT_ID").toString(),"PRD0350","product_rate","ProductRate"); + if("".equals(productRate)){ + BizObject boLcsit = JBOFactory.createBizObjectQuery(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + productRate = boLcsit.getAttribute("DISCOUNT_RATE").toString(); + } + BigDecimal interestRate = new BigDecimal(productRate).divide(new BigDecimal("100"),4,BigDecimal.ROUND_HALF_UP); + li.setInterestRate(interestRate.toString()); + + //׸ۺϣ + double firstRatio = boLcct.getAttribute("ALL_FIRST_PAYMENT_RATIO").getDouble()/100; + li.setDownPaymentPercentage(new BigDecimal(firstRatio).setScale(4,BigDecimal.ROUND_HALF_UP).toString()); + //׸ + li.setDownPaymentTotalAmount(boLcct.getAttribute("ALL_FIRST_PAYMENT").toString()); + li.setFinanceAmountUnit(""); + String finaAmountTotal = boLcct.getAttribute("CLEAN_LEASE_MONEY").toString(); + li.setFinanceAmountTotal(finaAmountTotal); + // + li.setTerms(boLcct.getAttribute("INCOME_NUMBER").toString()); + List boLrps = JBOFactory.createBizObjectQuery(LC_RENT_PLAN_TEMP.CLASS_NAME,"select o.interest,o.rent from o where o.FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getResultList(false); + BigDecimal interestTotal = new BigDecimal("0"); + double firstRent = 0; + for(int i=0;i 0) { + IsSubsity="1"; + } + } + //ҳеϢܶϢ + li.setMakerInterestTotal(makerInterestTotal); + li.setMakerInterestTotalDeposit(""); + li.setIsSubsity(IsSubsity); + li.setContractPriceTotal(boLcct.getAttribute("EQUIP_AMT").toString()); + li.setMonthInterestRate(interestRate.divide(new BigDecimal("12"),4,BigDecimal.ROUND_HALF_UP).toString()); + li.setPayType("пֱ"); + li.setPayRemark(""); + li.setIsLinked(ParamDataUtils.queryBcEnumType("TrueFalse",boLpit.getAttribute("IS_NETCAR").toString())); + li.setLinkedCompany(boLpit.getAttribute("AFFILIATEDNAME").toString()); + li.setLinkedCompanyType(boLpit.getAttribute("LEGALPERSONID").toString()); + li.setReserveString1("0"); + li.setReserveString2(""); + li.setReserveString3(""); + li.setReserveString4(""); + li.setReserveString5(""); + //; óá 0óĿǰȡTCFóTCCó + String carType = boLpit.getAttribute("car_type").toString(); + li.setAssetPurpose("ó".equals(carType)?"TCC":"TCF"); + li.setBalloonPercentage(""); + li.setBalloonAmount(""); + String financedAmtPct = new BigDecimal(finaAmountTotal).divide(new BigDecimal(boLcct.getAttribute("TOTAL_ALL").toString()),4,BigDecimal.ROUND_HALF_UP).toString(); + li.setFinancedAmtPct(financedAmtPct); + li.setRentalCalculationMtd(""); + //ͻе + String yearRate = boLcct.getAttribute("YEAR_RATE").toString(); + li.setBaseCustomerRate(yearRate); + //Ϣ + li.setSubsidyRte(interestRate.subtract(new BigDecimal(yearRate)).toString()); + li.setCalcSubsidyRte(""); + li.setCalcSubsidyAmt(""); + //ʵʣӢƷ + li.setActualRte(interestRate.toString()); + li.setPaymentScheme(ParamDataUtils.queryBcEnumType("income_number_year",boLcct.getAttribute("INCOME_NUMBER_YEAR").toString())); + li.setDealerSubsidyPct("0"); + li.setManufacturerSubsidyPct("0"); + li.setCalcDealerSubsidyAmt(interestRate.subtract(new BigDecimal(yearRate)).doubleValue()); + li.setCalcManufacturerSubsidyAmt(makerInterestTotal); + li.setCarCount(boLects.size()); + li.setExposuresNumber(exposures()); + li.setExposureAmount(exposuresAmount()); + li.setCarRealDownPaymentRatio(boLcct.getAttribute("FIRST_PAYMENT_RATIO").toString()); + li.setCarRealDownPaymentAmt(boLcct.getAttribute("FIRST_PAYMENT").toString()); + li.setFinancingRatio(1.0-boLcct.getAttribute("FIRST_PAYMENT_RATIO").getDouble()); + return li; + } + + public VehicleInfo getVehicleInfo() throws JBOException { + VehicleInfo vi = new VehicleInfo(); + List SingleVehicleTypes = new ArrayList<>(); + for(BizObject bo : boLects){ + SingleVehicleType svt = new SingleVehicleType(); + //Ʒ + svt.setMaker(ParamDataUtils.queryBcEnumType("MANUFACTURER_NAME",bo.getAttribute("MANUFACTURER_NAME").toString())); + svt.setBrand(bo.getAttribute("BRAND").toString()); + svt.setSeries(bo.getAttribute("car_series").toString()); + // + svt.setModel(bo.getAttribute("MODEL").toString()); + //̨ + svt.setQuantity("1"); + //׼۸ + svt.setPriceUnit(bo.getAttribute("EQUIP_PRICE").toString()); + svt.setPriceTotal(""); + svt.setGps(""); + svt.setChassisVehicleModel(""); + svt.setSubsityVehicleModel(""); + //:³ֳ + svt.setVehicleType(ParamDataUtils.queryBcEnumType("CarType",boLpit.getAttribute("CAR_TYPE").toString())); + svt.setOtherFee(""); + svt.setProducer(""); + //³ָ + svt.setNewPrice(bo.getAttribute("NOW_TOTAL").toString()); + svt.setVinNumber(""); + svt.setEngineNumber(""); + //; + svt.setPurpose(ParamDataUtils.queryBcEnumType("car_use_type",bo.getAttribute("car_use_type").toString())); + svt.setComments(""); + svt.setTransmission(""); + svt.setIsAffiliated(""); + svt.setAffiliatedCompName(""); + svt.setAffiliatedCompCrdcode(""); + svt.setRoadOperationLicenseCode(boLpit.getAttribute("TRANSPORTCERTID").toString()); + svt.setCarType(ParamDataUtils.queryBcEnumType("CarType",boLpit.getAttribute("CAR_TYPE").toString())); + svt.setBuyUseType(bo.getAttribute("cartype").toString()); + svt.setPurchaseTax(boLcct.getAttribute("PURCHASE_TAX").toString()); + svt.setCarPrice(bo.getAttribute("EQUIP_PRICE").toString()); + svt.setCarRealPrice(bo.getAttribute("EQUIP_PRICE").toString()); + SingleVehicleTypes.add(svt); + + } + vi.setSingleVehicleTypes(SingleVehicleTypes); + return vi; + } + public CustomerInfo getCustomerInfo() throws Exception { + CustomerInfo ci = null; + BizObject boCit = JBOFactory.createBizObjectQuery(CUSTOMER_INFO_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String customerType = boCit.getAttribute("customertype").toString(); + if("01".equals(customerType)){ + ci = getCustomerInfoOfCompany(); + } + if("03".equals(customerType)){ + ci = getCustomerInfoOfPerson(); + } + return ci; + } + public CustomerInfo getCustomerInfoOfCompany() throws JBOException { + CustomerInfo ci = new CustomerInfo(); + BizObject boCct = JBOFactory.createBizObjectQuery(CUSTOMER_COMPANY_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String chName = boCct.getAttribute("company_name").toString(); + String idCardNum = boCct.getAttribute("certid").toString(); + String idTypeCode = boCct.getAttribute("CERTTYPE").toString(); + String annualIncome = boCct.getAttribute("business_income").toString(); + String phoneHome = boCct.getAttribute("tel").toString(); + String phoneOffice = boCct.getAttribute("company_tel").toString(); + String businessTypeCode = boCct.getAttribute("unit_properties").toString(); + + ci.setChName(chName); + ci.setIdCardNum(idCardNum); + ci.setIdTypeCode(ParamDataUtils.queryBcEnumType("CertType",idTypeCode)); + ci.setAnnualIncome(annualIncome); + ci.setPhoneHome(phoneHome); + ci.setPhoneOffice(phoneOffice); + ci.setBusinessNatureCde(ParamDataUtils.queryBcEnumType("Unit_nature",businessTypeCode)); + ci.setCustTypeId("2"); + ci.setCheckedType("2"); + return ci; + } + public CustomerInfo getCustomerInfoOfPerson() throws Exception { + CustomerInfo ci = new CustomerInfo(); + BizObject boCat = JBOFactory.createBizObjectQuery(CUSTOMER_ACCOUNT_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + + String idTypeCode = ParamDataUtils.queryBcEnumType("CertType",boCpt.getAttribute("CERTTYPE").toString()); + String chName = boCpt.getAttribute("FULLNAME").toString(); + String idCardNum = boCpt.getAttribute("CERTID").toString(); + String genderCode = ParamDataUtils.queryBcEnumType("sex",boCpt.getAttribute("SEX").toString()); + String maritalStatusCode = ParamDataUtils.queryBcEnumType("marry",boCpt.getAttribute("MARRIAGE").toString(),boCpt.getAttribute("childrens_number").toString()); + String residentialStatusCode = ParamDataUtils.queryBcEnumType("Property_type",boCpt.getAttribute("Property_type").toString()); + String MonthlyIncome = boCpt.getAttribute("FAMILYMONTHINCOME").toString(); + String phoneCellPhone01 = boCpt.getAttribute("mobile").toString(); + String empemployerName = boCpt.getAttribute("WORKCORP").toString(); + String businessTypeCode = boCpt.getAttribute("Unit_nature").toString(); + String phoneHome = boCpt.getAttribute("telephone").toString(); + String phoneOffice = boCpt.getAttribute("WORKTEL").toString(); + String loanCardNumber = boCat.getAttribute("acc_number").toString(); + String openBankMobileNo = boCat.getAttribute("MOBILE").toString(); + String expense = boCpt.getAttribute("monthly_expenses").toString(); + String birthday = boCpt.getAttribute("birthday").toString().replace("/","-"); + String idBirthday = idCardNum.substring(6,14); + String nowDay = DateUtils.dateNow(); + int ageInYear = DateUtils.yearDiffByDate(idBirthday,nowDay); + int ageInMonth = DateUtils.monthDiffByDate(idBirthday,nowDay); + String workAddressId = boCpt.getAttribute("work_address_id").getString(); + + BizObject boRai = this.getAddressById(workAddressId); + String workProvinceCode = boRai.getAttribute("province_code").toString(); + String workCityCode = boRai.getAttribute("city_code").toString(); + String workDistrictCode = boRai.getAttribute("district_code").toString(); + String workAddressDetail = boRai.getAttribute("address_detail").toString(); + String occupationCode = ParamDataUtils.queryBcEnumType("career",boCpt.getAttribute("HEADSHIP").toString()); + String empBusinessTypeCode = ParamDataUtils.queryBcEnumType("workUnitIndustry",boCpt.getAttribute("UNITKIND").toString()); + String empPositionCode = ParamDataUtils.queryBcEnumType("duties",boCpt.getAttribute("OCCUPATION").toString()); + String highestEducation = ParamDataUtils.queryBcEnumType("Education",boCpt.getAttribute("EDUEXPERIENCE").toString()); + String CardTermBeginDate = boCpt.getAttribute("start_idexpiry").toString().replace("/","-"); + String CardTermEndDate = idDateConvert(boCpt.getAttribute("idexpiry").toString()); + + String nationId = ParamDataUtils.queryBcEnumType("nation",boCpt.getAttribute("NATIONALITY").toString()); + String localResidentFlag = ParamDataUtils.queryBcEnumType("spouse_hukou",boCpt.getAttribute("shukou").toString()); + + ci.setChName(chName); + //֤ + ci.setIdTypeCode(idTypeCode); + //֤ + ci.setIdCardNum(idCardNum); + // + ci.setAgeInYear(ageInYear); + //Ա + ci.setGenderCode(genderCode); + //״ + ci.setMaritalStatusCode(maritalStatusCode); + //ѧ + ci.setEducationCode(highestEducation); + //ס״() + ci.setResidentialStatusCode(residentialStatusCode); + // + ci.setMonthlyIncome(MonthlyIncome); + // + ci.setAnnualIncome(""); + ci.setMonthlyDTI(""); + ci.setNoOfDependents(""); + //λ + ci.setEmpemployerName(empemployerName); + //λҵ + ci.setEmpBusinessTypeCode(empBusinessTypeCode); + //ְҵ + ci.setEmpOccupationCode(occupationCode); + //ְ + ci.setEmpPositionCode(empPositionCode); + ci.setEmpProfessionalRank(""); + ci.setWorkSince(""); + ci.setEmpTimeOfEmployee(""); + ci.setPhoneCellphone01(phoneCellPhone01); + ci.setPhoneCellphone02(""); + ci.setPhoneHome(phoneHome); + ci.setPhoneOffice(phoneOffice); + ci.setBankStatementStatusCode(""); + ci.setLocalResidentFlag(localResidentFlag); + ci.setLocalApplicantFlag(""); + ci.setVipCust(""); + //ظͻ0:1:ǣ + ci.setRepeatedApplicantFlag(repeatedApplicantFlag(idCardNum)); + ci.setHukouType(""); + //ѧ + ci.setHighestEducation(highestEducation); + ci.setHighestDegree(""); + ci.setOfficePostCode(""); + ci.setCurrentOfficeEntryDate(""); + ci.setPhsNumber(""); + ci.setEmail(""); + ci.setHasDrivingLicence(""); + ci.setAllowDrivingType(""); + //Ա1.ˡ2.ˣ + ci.setCheckedType("1"); + //(п) + ci.setLoanCardNumber(loanCardNumber); + ci.setLoanCardPassword(""); + ci.setArchiveUrl(""); + ci.setAgeInMonth(ageInMonth); + ci.setChildrenFlag(""); + ci.setBlacklistInd(""); + ci.setThaiTitleCde(""); + //֧ + ci.setExpense(expense); + // + ci.setBrithday(birthday); + ci.setLicenseExpireDate(""); + ci.setCountryCode(""); + ci.setAreaCode(""); + ci.setExtentionNbr(""); + ci.setPhoneTypeCde(""); + ci.setDesignationCde(""); + ci.setCityCde(""); + ci.setStateCde(""); + //ʡ + ci.setProvinceGB(workProvinceCode); + ci.setCityGB(workCityCode); + ci.setDistrictGB(workDistrictCode); + ci.setStreetGB(""); + //ҵ + ci.setBusinessNatureCde(ParamDataUtils.queryBcEnumType("Unit_nature",businessTypeCode)); + ci.setPostCode(""); + //ַ + ci.setEmployAddress(workAddressDetail); + //ְҵ + ci.setOccupationCode(occupationCode); + //ҵ + ci.setBusinessTypeCde(empBusinessTypeCode); + //ʾ޵ij(ҵ) + ci.setTimeInYear2(""); + ci.setRankCde(""); + //ְҵ + ci.setOccupationCde(occupationCode); + //λҵ + ci.setIndustryTypeCde(empBusinessTypeCode); + ci.setAddr(getAddr()); + ci.setExposure(getExposure(idTypeCode)); + //ͻ + ci.setCustTypeId("1"); + ci.setIdCardTermBeginDate(CardTermBeginDate); + ci.setIdCardTermEndDate(CardTermEndDate); + ci.setOpenBankMobileNo(openBankMobileNo); + ci.setNationId(nationId); + ci.setQueryReason(CodeManager.getItemName("pboc_query_strategy","qryReason_lessee")); + return ci; + } + public Coborrowers getCoborrowers() throws Exception { + Coborrowers cos = new Coborrowers(); + if(boCft==null){ + return cos; + } + List coborrowerList = new ArrayList<>(); + coborrowerList.add(getCoborrower()); + cos.setCoborrower(coborrowerList); + return cos; + } + public Coborrower getCoborrower() throws Exception { + Coborrower co = new Coborrower(); + String idTypeCode = ParamDataUtils.queryBcEnumType("CertType",boCft.getAttribute("CERTTYPE").toString()); + String chName = boCft.getAttribute("name").toString(); + String idCardNum = boCft.getAttribute("CERTID").toString(); + String genderCode = ParamDataUtils.queryBcEnumType("sex",boCft.getAttribute("SEX").toString()); + String maritalStatusCode = ParamDataUtils.queryBcEnumType("marry",boCft.getAttribute("marry_type").toString(),boCft.getAttribute("childrens_number").toString()); + String residentialStatusCode = ParamDataUtils.queryBcEnumType("Property_type",boCft.getAttribute("residential_status").toString()); + String MonthlyIncome = boCft.getAttribute("smincome").toString(); + String phoneCellPhone01 = boCft.getAttribute("tel").toString(); + String empemployerName = boCft.getAttribute("suname").toString(); + String businessTypeCode = boCft.getAttribute("enterprise_nature").toString(); + String phoneHome = boCft.getAttribute("tel").toString(); + String phoneOffice = boCft.getAttribute("suphone").toString(); + String expense = boCft.getAttribute("monthly_expenses").toString(); + String birthday = boCft.getAttribute("birthday").toString().replace("/","-"); + String idBirthday = idCardNum.substring(6,14); + String nowDay = DateUtils.dateNow(); + int ageInYear = DateUtils.yearDiffByDate(idBirthday,nowDay); + int ageInMonth = DateUtils.monthDiffByDate(idBirthday,nowDay); + String workAddressId = boCft.getAttribute("work_address_id").getString(); + + BizObject boRai = getAddressById(workAddressId); + String workProvinceCode = boRai.getAttribute("province_code").toString(); + String workCityCode = boRai.getAttribute("city_code").toString(); + String workDistrictCode = boRai.getAttribute("district_code").toString(); + String workAddressDetail = boRai.getAttribute("address_detail").toString(); + String occupationCode = ParamDataUtils.queryBcEnumType("career",boCft.getAttribute("career_type").toString()); + String empBusinessTypeCode = ParamDataUtils.queryBcEnumType("workUnitIndustry",boCft.getAttribute("industry_type").toString()); + String empPositionCode = ParamDataUtils.queryBcEnumType("duties",boCft.getAttribute("sposition").toString()); + String highestEducation = ParamDataUtils.queryBcEnumType("Education",boCft.getAttribute("education_level").toString()); + String CardTermBeginDate = boCft.getAttribute("start_idexpiry").toString().replace("/","-"); + String CardTermEndDate = idDateConvert(boCft.getAttribute("idexpiry").toString()); + String nationId = ParamDataUtils.queryBcEnumType("nation",boCft.getAttribute("nation").toString()); + String censusRegAddrId = boCft.getAttribute("id_address_id").toString(); + BizObject boCens = this.getAddressById(censusRegAddrId); + String censusRegAddr = boCens.getAttribute("full_address").toString(); + String relationshipCode = ParamDataUtils.queryBcEnumType("personContact",boCft.getAttribute("ASSURE_RELATION").toString()); + String localResidentFlag = ParamDataUtils.queryBcEnumType("spouse_hukou",boCpt.getAttribute("shukou").toString()); + + co.setChName(chName); + //֤ + co.setIdTypeCode(idTypeCode); + //֤ + co.setIdCardNum(idCardNum); + // + co.setAgeInYear(ageInYear); + //Ա + co.setGenderCode(genderCode); + //״ + co.setMaritalStatusCode(maritalStatusCode); + //ѧ + co.setEducationCode(highestEducation); + //ס״() + co.setResidentialStatusCode(residentialStatusCode); + // + co.setMonthlyIncome(MonthlyIncome); + // + co.setAnnualIncome(""); + co.setMonthlyDTI(""); + co.setNoOfDependents(""); + //λ + co.setEmpemployerName(empemployerName); + //λҵ + co.setEmpBusinessTypeCode(empBusinessTypeCode); + //ְҵ + co.setEmpOccupationCode(occupationCode); + //ְ + co.setEmpPositionCode(empPositionCode); + co.setEmpProfessionalRank(""); + co.setWorkSince(""); + co.setEmpTimeOfEmployee(""); + co.setPhoneCellphone01(phoneCellPhone01); + co.setPhoneCellphone02(""); + co.setPhoneHome(phoneHome); + co.setPhoneOffice(phoneOffice); + co.setBankStatementStatusCode(""); + co.setLocalResidentFlag(localResidentFlag); + co.setLocalApplicantFlag(""); + co.setVipCust(""); + //ظͻ0:1:ǣ + co.setRepeatedApplicantFlag(repeatedApplicantFlag(idCardNum)); + co.setHukouType(""); + //ѧ + co.setHighestEducation(highestEducation); + co.setHighestDegree(""); + co.setOfficePostCode(""); + co.setCurrentOfficeEntryDate(""); + co.setPhsNumber(""); + co.setEmail(""); + co.setHasDrivingLicence(""); + co.setAllowDrivingType(""); + //Ա1.ˡ2.ˣ + co.setCheckedType("1"); + co.setLoanCardPassword(""); + co.setArchiveUrl(""); + co.setAgeInMonth(ageInMonth); + co.setChildrenFlag(""); + co.setBlacklistInd(""); + co.setThaiTitleCde(""); + //֧ + co.setExpense(expense); + // + co.setBrithday(birthday); + co.setLicenseExpireDate(""); + co.setCountryCode(""); + co.setAreaCode(""); + co.setExtentionNbr(""); + co.setPhoneTypeCde(""); + co.setDesignationCde(""); + co.setCityCde(""); + co.setStateCde(""); + //ʡ + co.setProvinceGB(workProvinceCode); + co.setCityGB(workCityCode); + co.setDistrictGB(workDistrictCode); + co.setStreetGB(""); + //ҵ + co.setBusinessNatureCde(ParamDataUtils.queryBcEnumType("Unit_nature",businessTypeCode)); + co.setPostCode(""); + //ַ + co.setEmployAddress(workAddressDetail); + //ְҵ + co.setOccupationCode(occupationCode); + //ҵ + co.setBusinessTypeCde(empBusinessTypeCode); + //ʾ޵ij(ҵ) + co.setTimeInYear2(""); + co.setRankCde(""); + //ְҵ + co.setOccupationCde(occupationCode); + //λҵ + co.setIndustryTypeCde(empBusinessTypeCode); + co.setAddr(getAddr()); + co.setExposure(getExposure(idTypeCode)); + //ͻͣĿǰϵͳֻһΪȻˣĬ1 + co.setCustTypeId("1"); + co.setIdCardTermBeginDate(CardTermBeginDate); + co.setIdCardTermEndDate(CardTermEndDate); + // + co.setNationId(nationId); + //ַ + co.setCensusRegAddr(censusRegAddr); + //λ绰 + co.setTelWorkNo(phoneOffice); + //˹ϵ + co.setRelationshipCode(relationshipCode); + //˱(ĿǰϵͳֻһˣĬ1) + co.setBorrowerId("1"); + //Ųѯԭ + co.setQueryReason(CodeManager.getItemName("pboc_query_strategy","qryReason_jointApplicant")); + return co; + } + public GuarantorInfo getGuarantorInfo() throws Exception { + GuarantorInfo gi = new GuarantorInfo(); + List gis = new ArrayList<>(); + for(BizObject boLgu : boLguts){ + Guar gr = getGuar(boLgu); + if(gr==null){ + continue; + } + gis.add(gr); + } + return gi; + } + public Guar getGuar(BizObject boLgu) throws Exception { + String certType = boLgu.getAttribute("CERTTYPE").toString(); + Guar gr = null; + if(certType.startsWith("Ind")){ + gr = getGuarOfPerson(boLgu); + } + if(certType.startsWith("Ent")){ + gr = getGuarOfCompany(boLgu); + } + return gr; + } + public Guar getGuarOfCompany(BizObject boLgu) throws JBOException { + Guar gr = new Guar(); + String chName = boLgu.getAttribute("FULLNAME").toString(); + String idCardNum = boLgu.getAttribute("CERTID").toString(); + String idTypeCode = boLgu.getAttribute("CERTTYPE").toString(); + String relationshipCode = ParamDataUtils.queryBcEnumType("personContact",boLgu.getAttribute("ASSURE_RELATION").toString()); + + gr.setChName(chName); + gr.setIdCardNum(idCardNum); + gr.setIdTypeCode(ParamDataUtils.queryBcEnumType("CertType",idTypeCode)); + gr.setRelationshipCode(relationshipCode); + gr.setCustTypeId("2"); + gr.setCheckedType("2"); + return gr; + } + public Guar getGuarOfPerson(BizObject boLgu) throws Exception { + Guar gr = new Guar(); + String idTypeCode = ParamDataUtils.queryBcEnumType("CertType",boLgu.getAttribute("CERTTYPE").toString()); + String chName = boLgu.getAttribute("FULLNAME").toString(); + String idCardNum = boLgu.getAttribute("CERTID").toString(); + String genderCode = ParamDataUtils.queryBcEnumType("sex",boLgu.getAttribute("SEX").toString()); + String maritalStatusCode = ParamDataUtils.queryBcEnumType("marry",boLgu.getAttribute("Marital_status").toString(),boLgu.getAttribute("childrens_number").toString()); + String residentialStatusCode = ParamDataUtils.queryBcEnumType("Property_type",boLgu.getAttribute("residential_status").toString()); + String MonthlyIncome = boLgu.getAttribute("Major_monthly_income").toString(); + String phoneCellPhone01 = boLgu.getAttribute("MOBILE").toString(); + String empemployerName = boLgu.getAttribute("WORKCORP").toString(); + String businessTypeCode = boLgu.getAttribute("enterprise_nature").toString(); + String phoneHome = boLgu.getAttribute("MOBILE").toString(); + String phoneOffice = boLgu.getAttribute("WORKTEL").toString(); + String expense = boLgu.getAttribute("monthly_expenses").toString(); + String birthday = boLgu.getAttribute("birthday").toString().replace("/","-"); + String idBirthday = idCardNum.substring(6,14); + String nowDay = DateUtils.dateNow(); + int ageInYear = DateUtils.yearDiffByDate(idBirthday,nowDay); + int ageInMonth = DateUtils.monthDiffByDate(idBirthday,nowDay); + String workAddressId = boLgu.getAttribute("work_address_id").getString(); + + BizObject boRai = getAddressById(workAddressId); + String workProvinceCode = boRai.getAttribute("province_code").toString(); + String workCityCode = boRai.getAttribute("city_code").toString(); + String workDistrictCode = boRai.getAttribute("district_code").toString(); + String workAddressDetail = boRai.getAttribute("address_detail").toString(); + String occupationCode = ParamDataUtils.queryBcEnumType("career",boLgu.getAttribute("career_type").toString()); + String empBusinessTypeCode = ParamDataUtils.queryBcEnumType("workUnitIndustry",boLgu.getAttribute("industry_type").toString()); + String empPositionCode = ParamDataUtils.queryBcEnumType("duties",boLgu.getAttribute("TITLE").toString()); + String highestEducation = ParamDataUtils.queryBcEnumType("Education",boLgu.getAttribute("education_level").toString()); + String CardTermBeginDate = boLgu.getAttribute("start_idexpiry").toString().replace("/","-"); + String CardTermEndDate = idDateConvert(boLgu.getAttribute("idexpiry").toString()); + String nationId = ParamDataUtils.queryBcEnumType("nation",boLgu.getAttribute("nation").toString()); + String censusRegAddrId = boLgu.getAttribute("id_address_id").toString(); + BizObject boCens = this.getAddressById(censusRegAddrId); + String censusRegAddr = boCens.getAttribute("full_address").toString(); + String relationshipCode = ParamDataUtils.queryBcEnumType("personContact",boLgu.getAttribute("ASSURE_RELATION").toString()); + String localResidentFlag = ParamDataUtils.queryBcEnumType("spouse_hukou",boCpt.getAttribute("shukou").toString()); + + gr.setChName(chName); + //֤ + gr.setIdTypeCode(idTypeCode); + //֤ + gr.setIdCardNum(idCardNum); + // + gr.setAgeInYear(ageInYear); + //Ա + gr.setGenderCode(genderCode); + //״ + gr.setMaritalStatusCode(maritalStatusCode); + //ѧ + gr.setEducationCode(highestEducation); + //ס״() + gr.setResidentialStatusCode(residentialStatusCode); + // + gr.setMonthlyIncome(MonthlyIncome); + // + gr.setAnnualIncome(""); + gr.setMonthlyDTI(""); + gr.setNoOfDependents(""); + //λ + gr.setEmpemployerName(empemployerName); + //λҵ + gr.setEmpBusinessTypeCode(empBusinessTypeCode); + //ְҵ + gr.setEmpOccupationCode(occupationCode); + //ְ + gr.setEmpPositionCode(empPositionCode); + gr.setEmpProfessionalRank(""); + gr.setWorkSince(""); + gr.setEmpTimeOfEmployee(""); + gr.setPhoneCellphone01(phoneCellPhone01); + gr.setPhoneCellphone02(""); + gr.setPhoneHome(phoneHome); + gr.setPhoneOffice(phoneOffice); + gr.setBankStatementStatusCode(""); + gr.setLocalResidentFlag(localResidentFlag); + gr.setLocalApplicantFlag(""); + gr.setVipCust(""); + //ظͻ0:1:ǣ + gr.setRepeatedApplicantFlag(repeatedApplicantFlag(idCardNum)); + gr.setHukouType(""); + //ѧ + gr.setHighestEducation(highestEducation); + gr.setHighestDegree(""); + gr.setOfficePostCode(""); + gr.setCurrentOfficeEntryDate(""); + gr.setPhsNumber(""); + gr.setEmail(""); + gr.setHasDrivingLicence(""); + gr.setAllowDrivingType(""); + //Ա1.ˡ2.ˣ + gr.setCheckedType("1"); + gr.setLoanCardPassword(""); + gr.setArchiveUrl(""); + gr.setAgeInMonth(ageInMonth); + gr.setChildrenFlag(""); + gr.setBlacklistInd(""); + gr.setThaiTitleCde(""); + //֧ + gr.setExpense(expense); + // + gr.setBrithday(birthday); + gr.setLicenseExpireDate(""); + gr.setCountryCode(""); + gr.setAreaCode(""); + gr.setExtentionNbr(""); + gr.setPhoneTypeCde(""); + gr.setDesignationCde(""); + gr.setCityCde(""); + gr.setStateCde(""); + //ʡ + gr.setProvinceGB(workProvinceCode); + gr.setCityGB(workCityCode); + gr.setDistrictGB(workDistrictCode); + gr.setStreetGB(""); + //ҵ + gr.setBusinessNatureCde(ParamDataUtils.queryBcEnumType("Unit_nature",businessTypeCode)); + gr.setPostCode(""); + //ַ + gr.setEmployAddress(workAddressDetail); + //ְҵ + gr.setOccupationCode(occupationCode); + //ҵ + gr.setBusinessTypeCde(empBusinessTypeCode); + //ʾ޵ij(ҵ) + gr.setTimeInYear2(""); + gr.setRankCde(""); + //ְҵ + gr.setOccupationCde(occupationCode); + //λҵ + gr.setIndustryTypeCde(empBusinessTypeCode); + gr.setAddr(getAddr()); + gr.setExposure(getExposure(idTypeCode)); + gr.setCustTypeId("1"); + gr.setIdCardTermBeginDate(CardTermBeginDate); + gr.setIdCardTermEndDate(CardTermEndDate); + // + gr.setNationId(nationId); + //ַ + gr.setCensusRegAddr(censusRegAddr); + //˹ϵ + gr.setRelationshipCode(relationshipCode); + //Ųѯԭ + gr.setQueryReason(CodeManager.getItemName("pboc_query_strategy","qryReason_guarantor")); + return gr; + } + public ContInfo getContInfo() throws JBOException { + ContInfo ci = new ContInfo(); + List contrs = new ArrayList<>(); + + Contr contr = new Contr(); + contr.setContNum("1"); + contr.setChName(boCpt.getAttribute("EMERGENCY_CONTACT_PERSON").toString()); + String relationshipCode1 = ParamDataUtils.queryBcEnumType("personContact",boCpt.getAttribute("EMPLOYRECORD").toString()); + contr.setRelationshipCode(relationshipCode1); + contr.setCellPhone(boCpt.getAttribute("EMERGENCY_CONTACT_TEL").toString()); + + Contr contr2 = new Contr(); + contr2.setContNum("2"); + contr2.setChName(boCpt.getAttribute("INTRO").toString()); + String relationshipCode2 = ParamDataUtils.queryBcEnumType("personContact",boCpt.getAttribute("EDUDEGREE").toString()); + contr2.setRelationshipCode(relationshipCode2); + contr2.setCellPhone(boCpt.getAttribute("REMARK").toString()); + + contrs.add(contr); + contrs.add(contr2); + ci.setContrs(contrs); + return ci; + } + + public int repeatedApplicantFlag(String certId) throws JBOException { + int repeatedApplicantFlag = 0; + //int boCountLgu = JBOFactory.createBizObjectQuery(LB_GUARANTEE_UNIT.CLASS_NAME,"CERTID=:certId").setParameter("certId",certId).getTotalCount(); + //int boCountCf = JBOFactory.createBizObjectQuery(CUSTOMER_FAMILY.CLASS_NAME,"CERTID=:certId and status='valid' and Partner_='Y' ").setParameter("certId",certId).getTotalCount(); + int boCountCi = JBOFactory.createBizObjectQuery(CUSTOMER_INFO.CLASS_NAME,"CERTID=:certId ").setParameter("certId",certId).getTotalCount(); + if(boCountCi>0){ + repeatedApplicantFlag = 1; + } + return repeatedApplicantFlag; + } + + public Addr getAddr() throws JBOException { + BizObject boCat = JBOFactory.createBizObjectQuery(CUSTOMER_ADDRESS_TEMP.CLASS_NAME,"FLOWUNID=:flowunid and customerid=:customerId").setParameter("flowunid",flowUnid).setParameter("customerId",boCpt.getAttribute("customerid").toString()).getSingleResult(false); + String liveAddressId = boCat.getAttribute("province").getString(); + String provinceCode = ParamDataUtils.queryMapBcProvinceCode("AreaCode",liveAddressId); + String cityCode = ParamDataUtils.queryMapBcCityCode("AreaCode",liveAddressId); + String districtCode = ParamDataUtils.queryMapBcCountyCode("AreaCode",liveAddressId); + String fullAddress = boCat.getAttribute("dressdetail").getString(); + String residentialStatusCode = ParamDataUtils.queryBcEnumType("Property_type",boCpt.getAttribute("Property_type").toString()); + Addr addr = new Addr(); + addr.setProvince(""); + addr.setCity(""); + addr.setDistrict(""); + addr.setProvinceGB(provinceCode); + addr.setCityGB(cityCode); + addr.setDistrictGB(districtCode); + addr.setStreetGB(""); + addr.setAddress(fullAddress); + addr.setPostCode(""); + addr.setAddrType(""); + addr.setAddrNum(""); + addr.setPropertyTypeCde(residentialStatusCode); + addr.setHukouAddress(""); + + return addr; + } + public Exposure getExposure(String certId) throws JBOException { + //֤ţcustomeridΪһ֤ţcustomerid + List boCis = JBOFactory.createBizObjectQuery(CUSTOMER_INFO.CLASS_NAME,"CERTID=:certId").setParameter("certId",certId).getResultList(false); + BigDecimal corpusRemain = new BigDecimal("0"); + BigDecimal yetLoan = new BigDecimal("0"); + int carCountRemain = 0; + int carCountYetLoan = 0; + for(BizObject boCi : boCis){ + String customerId = boCi.getAttribute("CUSTOMERID").toString(); + //һcustomerIdڶͬ + List boLuls = JBOFactory.createBizObjectQuery(LB_UNION_LESSEE.CLASS_NAME,"CUSTOMER_ID=:CUSTOMER_ID and is_main='Y'").setParameter("CUSTOMER_ID",customerId).getResultList(false); + for(BizObject boLul : boLuls){ + String contractId = boLul.getAttribute("contract_id").toString(); + BizObject boLci = JBOFactory.createBizObjectQuery(LB_CONTRACT_INFO.CLASS_NAME,"ID=:ID").setParameter("ID",contractId).getSingleResult(false); + String contractStatus = boLci.getAttribute("CONTRACT_STATUS").toString(); + if("31".equals(contractStatus)){ + BizObject boCat = JBOFactory.createBizObjectQuery(LC_CALC_CONDITION.CLASS_NAME,"CONTRACT_ID=:CONTRACT_ID").setParameter("CONTRACT_ID",contractId).getSingleResult(false); + String financeAmount = boCat.getAttribute("CLEAN_LEASE_MONEY").toString(); + BizObject boLri = JBOFactory.createBizObjectQuery(LC_RENT_INCOME.CLASS_NAME,"select ifnull(sum(corpus),0) as v.corpusTotal from o where CONTRACT_ID=:CONTRACT_ID and ROLL_BACK='0' ").setParameter("CONTRACT_ID",contractId).getSingleResult(false); + String corpusTotal = boLri.getAttribute("corpusTotal").toString(); + corpusRemain = corpusRemain.add(new BigDecimal(financeAmount).subtract(new BigDecimal(corpusTotal))); + carCountRemain = JBOFactory.createBizObjectQuery(LB_EQUIPMENT_CAR.CLASS_NAME,"CONTRACT_ID=:CONTRACT_ID").setParameter("CONTRACT_ID",contractId).getTotalCount(); + + } + if("21".equals(contractStatus)){ + BizObject boLfi = JBOFactory.createBizObjectQuery(LC_FUND_INCOME.CLASS_NAME,"CONTRACT_ID=:CONTRACT_ID and pay_type='pay_type_out' and fee_type='feetype10' and SETTLE_METHOD='settlemethod6' and roll_back='0' and PAY_STATUS<>'have_paid' ").setParameter("CONTRACT_ID",contractId).getSingleResult(false); + String factMoney = boLfi.getAttribute("fact_money").toString(); + yetLoan = yetLoan.add(new BigDecimal(factMoney)); + carCountYetLoan = JBOFactory.createBizObjectQuery(LB_EQUIPMENT_CAR.CLASS_NAME,"CONTRACT_ID=:CONTRACT_ID").setParameter("CONTRACT_ID",contractId).getTotalCount(); + } + } + } + Exposure ep = new Exposure(); + ep.setOutstanding(corpusRemain.toString()); + ep.setApprovalAmt(yetLoan.toString()); + ep.setOsNum(carCountRemain); + ep.setApprovalNum(carCountYetLoan); + return ep; + } + + public ApplicationInfo getApplicationInfo() throws Exception { + ApplicationInfo app = new ApplicationInfo(); + String number = boLpit.getAttribute("PROJECT_NO").toString(); + BizObject boft = JBOFactory.createBizObjectQuery(FLOW_TASK.CLASS_NAME,"select min(begintime) as v.minTime,max(begintime) as v.maxTime from o where flowno='BusinessApplyFlow' and phasetype='1020' and objectno=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String minTime = boft.getAttribute("minTime").toString().replace("/","-").replace(" ","T"); + String maxTime = boft.getAttribute("maxTime").toString().replace("/","-").replace(" ","T"); + String faName = boLpit.getAttribute("inputName").toString(); + String faCellphone = boLpit.getAttribute("inputTel").toString(); + String carType = boLpit.getAttribute("car_type").toString(); + app.setNumber(number); + app.setApplicationType("APF"); + app.setOriginalSystemId("APF"); + app.setTranNo(DateUtils.dateTimeNowAccurate()); + app.setFirstProposalDate(minTime); + app.setLastProposalDate(maxTime); + app.setFaName(faName); + app.setFaid(""); + app.setFaCellphone(faCellphone); + app.setFvName(""); + app.setFvCellphone(""); + app.setFvDateoffv(""); + app.setFieldVisitFlag(""); + app.setBusinessStep(""); + app.setGroupCustomerUpId(""); + app.setGroupCustomerSpecialLimit(""); + //ִͣCVPV + app.setLoanvehicleType("ó".equals(carType)?"PV":"CV"); + app.setQueryReason(""); + app.setCreditQueryType(""); + app.setCreditQueryInterface(""); + BizObject boPsl = JBOFactory.createBizObjectQuery(PRD_SPECIFIC_LIBRARY.CLASS_NAME,"PRODUCTID=:PRODUCTID").setParameter("PRODUCTID",boLpit.getAttribute("PRODUCT_ID").toString()).getSingleResult(false); + String lendingType = boPsl.getAttribute("LENDING_TYPE").toString(); + app.setIsVehicleGuaranty("AFTER".equals(lendingType)||"FIRST".equals(lendingType)?"1":"0"); + app.setCvHeadVehicleCount(""); + app.setSosRandomNumber(""); + // + app.setApplicationDate(boLpit.getAttribute("project_date").toString().replace("/","-").replace(" ","T")); + //ύύʱ䡣 + app.setApplicationSubmitDate(maxTime); + // ͻ 1 2 + BizObject boCit = JBOFactory.createBizObjectQuery(CUSTOMER_INFO_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String customerType = "1"; + if("01".equals(boCit.getAttribute("customertype").toString())){ + customerType="2"; + } + app.setCustomerType(customerType); + //̵ģʽ + app.setStatusCode(ParamDataUtils.queryBcEnumType("dischanneltype",boDi.getAttribute("channeltype").toString())); + + return app; + } + + public PreviouslyVehicle getPreviouslyVehicle() throws JBOException { + PreviouslyVehicle pv = new PreviouslyVehicle(); + pv.setWorkingTime(ParamDataUtils.queryBcEnumType("employmentTime",boCpt.getAttribute("pre_operate_years").toString())); + pv.setPreviouslyVehicleType(ParamDataUtils.queryBcEnumType("operatePreVehicleType",boCpt.getAttribute("pre_operate_car_type").toString())); + pv.setPreviouslyVehicleLicense(boCpt.getAttribute("pre_operate_car_no").toString()); + return pv; + } + + public BizObject getAddressById(String addressId) throws JBOException { + BizObjectManager rcAddressInfo = JBOFactory.getBizObjectManager(RC_ADDRESS_INFO.CLASS_NAME); + BizObject boRai = rcAddressInfo.createQuery("address_id=:id").setParameter("id", addressId).getSingleResult(false); + return boRai; + } + + public int exposures() throws JBOException { + Set projectSet = new HashSet<>(); + BizObject boCit = JBOFactory.createBizObjectQuery(CUSTOMER_INFO_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String applyCertId = boCpt.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(applyCertId)); + if(boCft!=null){ + String coBorroeerId = boCft.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(coBorroeerId)); + } + if(boLguts.size()>0){ + for(BizObject boLgu : boLguts){ + String lguCertId = boLgu.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(lguCertId)); + } + } + return projectSet.size(); + } + public String exposuresAmount() throws JBOException { + Set projectSet = new HashSet<>(); + BigDecimal amount = new BigDecimal("0.00"); + BizObject boCit = JBOFactory.createBizObjectQuery(CUSTOMER_INFO_TEMP.CLASS_NAME,"FLOWUNID=:flowunid").setParameter("flowunid",flowUnid).getSingleResult(false); + String applyCertId = boCpt.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(applyCertId)); + if(boCft!=null){ + String coBorroeerId = boCft.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(coBorroeerId)); + } + if(boLguts.size()>0){ + for(BizObject boLgu : boLguts){ + String lguCertId = boLgu.getAttribute("CERTID").toString(); + projectSet.addAll(getExposuresNumberByCertID(lguCertId)); + } + } + for(String projectId : projectSet){ + BizObject boLpc = JBOFactory.createBizObjectQuery(LC_PROJ_CONDITION.CLASS_NAME,"PROJECT_ID=:PROJECT_ID").setParameter("PROJECT_ID",projectId).getSingleResult(false); + String cleanLeaseMoney = boLpc.getAttribute("CLEAN_LEASE_MONEY").toString(); + String cautionMoney =boLpc.getAttribute("CAUTION_MONEY").toString(); + BizObject boLri = JBOFactory.createBizObjectQuery(LC_RENT_INCOME.CLASS_NAME,"select sum(rent) as v.rentIncome from O where ROLL_BACK=0 and PROJECT_ID=:PROJECT_ID").setParameter("PROJECT_ID",projectId).getSingleResult(false); + String rentIncome = boLri.getAttribute("rentIncome").toString(); + if("".equals(rentIncome)){ + continue; + } + amount = new BigDecimal(cleanLeaseMoney).subtract(new BigDecimal(cautionMoney)).subtract(new BigDecimal(rentIncome)).add(amount); + } + + return amount.toString(); + } + public Set getExposuresNumberByCertID(String certId) throws JBOException { + /* + 峨߼Ϊ˻߹˻򵣱˳ͬȫҵΪ߹˻򵣱ˣظͬȡһμ㣩 + =ȫͬģѷſĴ + ſĴ + Ѻ׼δſ - ֤ + ģ - ֤ + +ǰڵģ - ֤ + ˿ͻ迼Ƿ˿ͻȻ壺ˡʵʿ˼ɶĶڡ + */ + //һ֤ܴڶcustomerid + List boCis = JBOFactory.createBizObjectQuery(CUSTOMER_INFO.CLASS_NAME,"select CUSTOMERID from O where CERTID=:certId").setParameter("certId",certId).getResultList(false); + Set projectSet = new HashSet<>(); + for(BizObject boCi : boCis){ + String customerId = boCi.getAttribute("CUSTOMERID").toString(); + //һcustomerIdڶͬ + List boLuls = JBOFactory.createBizObjectQuery(LB_UNION_LESSEE.CLASS_NAME,"select project_id from O where CUSTOMER_ID=:CUSTOMER_ID and is_main='Y'").setParameter("CUSTOMER_ID",customerId).getResultList(false); + for(BizObject boLul : boLuls){ + String projectId = boLul.getAttribute("project_id").toString(); + projectSet.add(projectId); + } + } + List boCfs = JBOFactory.createBizObjectQuery(CUSTOMER_FAMILY.CLASS_NAME,"select PROJECT_ID from O where CERTID=:certId and status='valid' and Partner_='Y'").setParameter("certId",certId).getResultList(false); + for(BizObject boCf : boCfs){ + String projectId = boCf.getAttribute("PROJECT_ID").toString(); + projectSet.add(projectId); + } + List boLgus = JBOFactory.createBizObjectQuery(LB_GUARANTEE_UNIT.CLASS_NAME,"select PROJECT_ID from O where CERTID=:certId ").setParameter("certId",certId).getResultList(false); + for(BizObject boLgu : boLgus){ + String projectId = boLgu.getAttribute("PROJECT_ID").toString(); + projectSet.add(projectId); + } + return projectSet; + } + + public String idDateConvert(String date){ + if("2100/12/31".equals(date)){ + date = "0000-00-00"; + }else{ + date = date.replace("/","-"); + } + return date; + } + + public String getFlowUnid() { + return flowUnid; + } + + public void setFlowUnid(String flowUnid) { + this.flowUnid = flowUnid; + } + + public String getOperatorId() { + return operatorId; + } + + public void setOperatorId(String operatorId) { + this.operatorId = operatorId; + } +} diff --git a/src/com/ample/esb/util/BaicPropertiesUtil.java b/src/com/ample/esb/util/BaicPropertiesUtil.java new file mode 100644 index 000000000..154cc0cd6 --- /dev/null +++ b/src/com/ample/esb/util/BaicPropertiesUtil.java @@ -0,0 +1,36 @@ +package com.ample.esb.util; + + +import java.io.IOException; +import java.util.Map; +import java.util.Properties; +import java.util.concurrent.ConcurrentHashMap; + +public class BaicPropertiesUtil { + private static Map attributes; + + public static void load() { + attributes = new ConcurrentHashMap(); + Properties prop = new Properties(); + try { + prop.load(BaicPropertiesUtil.class.getResourceAsStream("/baic.properties")); + for(Map.Entry entry : prop.entrySet()) { + if(entry.getKey() == null || entry.getValue() == null) { + continue; + } + attributes.put(entry.getKey().toString(), entry.getValue().toString()); + } + } catch (IOException e) { + e.printStackTrace(); + } + } + + public static void destroy() { + if(attributes != null) attributes.clear(); + } + + public static String get(String propName) { + if(attributes == null) load(); + return attributes.get(propName); + } +} diff --git a/src/com/ample/esb/util/DateUtils.java b/src/com/ample/esb/util/DateUtils.java new file mode 100644 index 000000000..bb55a419f --- /dev/null +++ b/src/com/ample/esb/util/DateUtils.java @@ -0,0 +1,251 @@ +package com.ample.esb.util; + +import org.apache.commons.lang3.time.DateFormatUtils; + +import java.lang.management.ManagementFactory; +import java.text.ParseException; +import java.text.SimpleDateFormat; +import java.time.*; +import java.util.Date; + +/** + * 时间工具类 + * + * @author + */ +public class DateUtils extends org.apache.commons.lang3.time.DateUtils +{ + public static String YYYY = "yyyy"; + + public static String YYYY_MM = "yyyy-MM"; + + public static String YYYY_MM_DD = "yyyy-MM-dd"; + + public static String YYYY_MM_CORE = "yyyy/MM"; + + public static String YYYY_MM_DD_CORE = "yyyy/MM/dd"; + + public static String YYYYMMDD = "yyyyMMdd"; + + public static String HHMMSSSSS = "HHmmssSSS"; + + public static String YYYYMMDDHHMMSS = "yyyyMMddHHmmss"; + + public static String YYYYMMDDHHMMSSSSS = "yyyyMMddHHmmssSSS"; + + public static String YYYY_MM_DD_HH_MM_SS = "yyyy-MM-dd HH:mm:ss"; + + public static String YYYY_MM_DD_HH_MM_SS_CORE = "yyyy/MM/dd HH:mm:ss"; + + private static String[] parsePatterns = { + "yyyy-MM-dd", "yyyy-MM-dd HH:mm:ss", "yyyy-MM-dd HH:mm", "yyyy-MM", + "yyyy/MM/dd", "yyyy/MM/dd HH:mm:ss", "yyyy/MM/dd HH:mm", "yyyy/MM", + "yyyy.MM.dd", "yyyy.MM.dd HH:mm:ss", "yyyy.MM.dd HH:mm", "yyyy.MM"}; + + /** + * 获取当前Date型日期 + * + * @return Date() 当前日期 + */ + public static Date getNowDate() + { + return new Date(); + } + + /** + * 获取当前日期, 默认格式为yyyy-MM-dd + * + * @return String + */ + public static String getDate() + { + return dateTimeNow(YYYY_MM_DD); + } + + public static final String getTime() + { + return dateTimeNow(YYYY_MM_DD_HH_MM_SS); + } + + public static final String dateNow() + { + return dateTimeNow(YYYYMMDD); + } + public static final String yearNow() + { + return dateTimeNow(YYYY); + } + + public static final String dateNowCore() + { + return dateTimeNow(YYYY_MM_DD_CORE); + } + + public static final String dateTimeNowCore() + { + return dateTimeNow(YYYY_MM_DD_HH_MM_SS_CORE); + } + + public static final String monthNowCore(){ + return dateTimeNow(YYYY_MM_CORE); + } + + public static final String TimeNowAccurate() + { + return dateTimeNow(HHMMSSSSS); + } + + public static final String dateTimeNow() + { + return dateTimeNow(YYYYMMDDHHMMSS); + } + + public static final String dateTimeNowAccurate() + { + return dateTimeNow(YYYYMMDDHHMMSSSSS); + } + + public static final String dateTimeNow(final String format) + { + return parseDateToStr(format, new Date()); + } + + public static final String dateTime(final Date date) + { + return parseDateToStr(YYYY_MM_DD, date); + } + + public static final String parseDateToStr(final String format, final Date date) + { + return new SimpleDateFormat(format).format(date); + } + + public static final Date dateTime(final String format, final String ts) + { + try + { + return new SimpleDateFormat(format).parse(ts); + } + catch (ParseException e) + { + throw new RuntimeException(e); + } + } + + /** + * 日期路径 即年/月/日 如2018/08/08 + */ + public static final String datePath() + { + Date now = new Date(); + return DateFormatUtils.format(now, "yyyy/MM/dd"); + } + + /** + * 日期路径 即年/月/日 如20180808 + */ + public static final String dateTime() + { + Date now = new Date(); + return DateFormatUtils.format(now, "yyyyMMdd"); + } + + /** + * 日期型字符串转化为日期 格式 + */ + public static Date parseDate(Object str) + { + if (str == null) + { + return null; + } + try + { + return parseDate(str.toString(), parsePatterns); + } + catch (ParseException e) + { + return null; + } + } + + /** + * 获取服务器启动时间 + */ + public static Date getServerStartDate() + { + long time = ManagementFactory.getRuntimeMXBean().getStartTime(); + return new Date(time); + } + + /** + * 计算相差天数 + */ + public static int differentDaysByMillisecond(Date date1, Date date2) + { + return Math.abs((int) ((date2.getTime() - date1.getTime()) / (1000 * 3600 * 24))); + } + + /** + * 计算两个时间差 + */ + public static String getDatePoor(Date endDate, Date nowDate) + { + long nd = 1000 * 24 * 60 * 60; + long nh = 1000 * 60 * 60; + long nm = 1000 * 60; + // long ns = 1000; + // 获得两个时间的毫秒时间差异 + long diff = endDate.getTime() - nowDate.getTime(); + // 计算差多少天 + long day = diff / nd; + // 计算差多少小时 + long hour = diff % nd / nh; + // 计算差多少分钟 + long min = diff % nd % nh / nm; + // 计算差多少秒//输出结果 + // long sec = diff % nd % nh % nm / ns; + return day + "天" + hour + "小时" + min + "分钟"; + } + + /** + * 增加 LocalDateTime ==> Date + */ + public static Date toDate(LocalDateTime temporalAccessor) + { + ZonedDateTime zdt = temporalAccessor.atZone(ZoneId.systemDefault()); + return Date.from(zdt.toInstant()); + } + + /** + * 增加 LocalDate ==> Date + */ + public static Date toDate(LocalDate temporalAccessor) + { + LocalDateTime localDateTime = LocalDateTime.of(temporalAccessor, LocalTime.of(0, 0, 0)); + ZonedDateTime zdt = localDateTime.atZone(ZoneId.systemDefault()); + return Date.from(zdt.toInstant()); + } + + public static int yearDiffByDate(String start,String end){ + int diffYear = Integer.parseInt(end.substring(0,4))-Integer.parseInt(start.substring(0,4)); + if(Integer.parseInt(end.substring(4))=Integer.parseInt(start.substring(6))){ + diffMonth = Integer.parseInt(end.substring(4,6))-Integer.parseInt(start.substring(4,6)); + }else{ + diffMonth = Integer.parseInt(end.substring(4,6))-Integer.parseInt(start.substring(4,6))-1; + } + if(diffMonth<0){ + diffMonth = diffMonth + 12; + } + return diffMonth; + } + + +} diff --git a/src/com/ample/esb/util/GlobalSeqNo.java b/src/com/ample/esb/util/GlobalSeqNo.java new file mode 100644 index 000000000..15278350c --- /dev/null +++ b/src/com/ample/esb/util/GlobalSeqNo.java @@ -0,0 +1,27 @@ +package com.ample.esb.util; + +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.jbo.JBOFactory; + + +public class GlobalSeqNo { + + public synchronized String getGlobalSeqNo() { + String globalSeqNo = null; + BizObject bo = null; + try { + bo = JBOFactory.getBizObjectManager("jbo.oti.ESB_LOG").createQuery("select max(GLOBAL_SEQ_NO) as v.GLOBAL_SEQ_NO_MAX from O where LEFT(INPUTTIME,8)=:INPUTTIME").setParameter("INPUTTIME", DateUtils.dateNow()).getSingleResult(false); + if(bo==null||bo.getAttribute("GLOBAL_SEQ_NO_MAX")==null||"".equals(bo.getAttribute("GLOBAL_SEQ_NO_MAX").toString())){ + globalSeqNo = "GAPF" + DateUtils.dateNow() + "00000001"; + }else{ + globalSeqNo = bo.getAttribute("GLOBAL_SEQ_NO_MAX").toString(); + long seqNo = Long.valueOf(globalSeqNo.substring(4))+1; + globalSeqNo = "GAPF" + seqNo; + } + } catch (JBOException e) { + e.printStackTrace(); + } + return globalSeqNo; + } +} diff --git a/src/com/ample/esb/util/XstreamUtil.java b/src/com/ample/esb/util/XstreamUtil.java new file mode 100644 index 000000000..369e50f3c --- /dev/null +++ b/src/com/ample/esb/util/XstreamUtil.java @@ -0,0 +1,91 @@ +package com.ample.esb.util; + +import com.ample.esb.bean.esb.Transaction; +import com.thoughtworks.xstream.XStream; +import com.thoughtworks.xstream.core.util.QuickWriter; +import com.thoughtworks.xstream.io.HierarchicalStreamWriter; +import com.thoughtworks.xstream.io.xml.PrettyPrintWriter; +import com.thoughtworks.xstream.io.xml.XppDriver; + +import java.io.Writer; + +public class XstreamUtil { + + public static String PREFIX_CDATA = ""; + + /** + * ȫת + */ + public static XStream initXStream() { + return new XStream(new XppDriver() { + @Override + public HierarchicalStreamWriter createWriter(Writer out) { + return new PrettyPrintWriter(out) { + protected void writeText(QuickWriter writer, String text) { + // if (text.startsWith(PREFIX_CDATA) && + // text.endsWith(SUFFIX_CDATA)) { + writer.write(PREFIX_CDATA + text + SUFFIX_CDATA); + // } else { + // super.writeText(writer, text); + // } + } + }; + } + }); + } + + /** + * ʼXStream֧ijһֶοԼCDATAǩ,Ҫijһֶʹԭ,ҪString͵textͷ + * ""ǩ ԹXStreamʱʶ + * @param isAddCDATA Ƿ֧CDATAǩ + */ + public static XStream initXStream(boolean isAddCDATA) { + XStream xstream = null; + if (isAddCDATA) { + xstream = new XStream(new XppDriver() { + @Override + public HierarchicalStreamWriter createWriter(Writer out) { + return new PrettyPrintWriter(out) { + protected void writeText(QuickWriter writer, String text) { + if (text.startsWith(PREFIX_CDATA) && text.endsWith(SUFFIX_CDATA)) { + writer.write(text); + } else { + super.writeText(writer, text); + } + } + }; + } + }); + } else { + xstream = new XStream(); + } + return xstream; + } + + public static Object objectConvert(String xml) { + if(xml.startsWith("")+2); + } + XStream xs = new XStream(); + xs.ignoreUnknownElements(); + xs.autodetectAnnotations(true); + xs.alias("TRANSACTION", Transaction.class); + return xs.fromXML(xml); + } + public static String xmlConvert(Object obj) { + String xml = xmlConvertNotTitle(obj); + xml = "\n" + xml; + return xml; + } + public static String xmlConvertNotTitle(Object obj) { + XStream xs = initXStream(true); + xs.autodetectAnnotations(true); + xs.aliasSystemAttribute(null,"class"); + String xml = xs.toXML(obj); + //XStreamëתὫ_ת__,ת + xml = xml.replace("__","_"); + return xml; + } + +} diff --git a/src/com/ample/esb/web/RCScoreResultCheck.java b/src/com/ample/esb/web/RCScoreResultCheck.java new file mode 100644 index 000000000..149516d22 --- /dev/null +++ b/src/com/ample/esb/web/RCScoreResultCheck.java @@ -0,0 +1,45 @@ +package com.ample.esb.web; + +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.*; +import jbo.app.tenwa.customer.*; +import jbo.oti.RC_SCORE_RESULT; + +public class RCScoreResultCheck { + + + private String projectNo; + + + + public String getProjectNo() { + return projectNo; + } + + public void setProjectNo(String projectNo) { + this.projectNo = projectNo; + } + + /** + * ֽѯ + * @param tx + * @return + * @throws JBOException + */ + public String queryRCScoreResult(JBOTransaction tx) throws JBOException{//У֤Ƿ + ARE.getLog().info("RCScoreResultCheck#queryRCScoreResultprojectNo=" + projectNo); + BizObject rcScoreResultBiz = JBOFactory.createBizObjectQuery(RC_SCORE_RESULT.CLASS_NAME,"project_no=:project_no").setParameter("project_no", this.projectNo).getSingleResult(false); + if(null == rcScoreResultBiz){ + return null; + } + // թԤHSC + String fraud_alert_code = null == rcScoreResultBiz.getAttribute("fraud_alert_code") ? "" : rcScoreResultBiz.getAttribute("fraud_alert_code").toString(); + // թжFKS + String fraud_taken_code = null == rcScoreResultBiz.getAttribute("fraud_taken_code") ? "" : rcScoreResultBiz.getAttribute("fraud_taken_code").toString(); + // ֽ AA RR RD DD + String score_result_code = null == rcScoreResultBiz.getAttribute("score_result_code") ? "" : rcScoreResultBiz.getAttribute("score_result_code").toString(); + String res = score_result_code+"@" +fraud_taken_code+"@" +fraud_alert_code; + ARE.getLog().info("RCScoreResultCheck#queryRCScoreResultres=" + res); + return score_result_code+"@" +fraud_taken_code+"@" +fraud_alert_code ; + } +} diff --git a/src/com/ample/sms/SmsController.java b/src/com/ample/sms/SmsController.java index 68f0be099..b9ab09a19 100644 --- a/src/com/ample/sms/SmsController.java +++ b/src/com/ample/sms/SmsController.java @@ -23,12 +23,16 @@ public class SmsController { public String sendMessage(JBOTransaction tx){ try{ - // ʵŴ - SmsSendConn smsSendConn = new SmsSendConn(true); //͹IJ@зֳ String[] smsID = ids.split("@"); + if(smsID.length==0){ + return "ERROR"; + } BizObjectManager bomLSNT = JBOFactory.getBizObjectManager(LB_SMS_NOTICE_TASKS.CLASS_NAME,tx); BizObjectManager bomSS = JBOFactory.getBizObjectManager(SMS_SEND.CLASS_NAME,tx); + SmsSendManager.accountCheck(); + // ʵŴ + SmsSendConn smsSendConn = new SmsSendConn(true); for(String id:smsID){ sendMessage(smsSendConn,id,bomLSNT,bomSS); } @@ -44,12 +48,6 @@ public class SmsController { int resultCode = -310099; try { Message message = createMessageByBizObject(boLSNT); - String smsObType = boLSNT.getAttribute("SEND_OBJ_TYPE").toString(); - if(SmsObjType.URGE_COLLECTION.getType().equals(smsObType)){ - SmsSendManager.setAccountInfo(SmsObjType.URGE_COLLECTION); - }else { - SmsSendManager.setAccountInfo(SmsObjType.NORMAL); - } StringBuffer returnValue = new StringBuffer(); /* Ͷ @@ -96,9 +94,14 @@ public class SmsController { String result = "ѯʧ"; // ʵŴ SmsSendConn smsSendConn = new SmsSendConn(true); - SmsSendManager.setAccountInfo("02".equals(smsObjType)?SmsObjType.URGE_COLLECTION:SmsObjType.NORMAL); - // ѯӿڡ - Remains remains = smsSendConn.getRemains(SmsPropertiesUtil.get("userid")); + String userId = SmsPropertiesUtil.get("userid"); + if("02".equals(smsObjType)){ + userId = SmsPropertiesUtil.get("urge_userid"); + } + if(!SmsSendManager.accountExist(userId)){ + SmsSendManager.setAccountInfo(); + } + Remains remains = smsSendConn.getRemains(userId); //remainsΪ if(remains==null) @@ -143,14 +146,18 @@ public class SmsController { return "ȡ״̬߳ɹ"; } public Message createMessageByBizObject(BizObject bo) throws JBOException { - //öŽӿ String phoneNo = bo.getAttribute("PHONE_NUMBER").getString(); String smsContent = bo.getAttribute("SMS_CONTENT").getString(); String smsId = bo.getAttribute("ID").getString(); + String smsObjType = bo.getAttribute("SEND_OBJ_TYPE").getString(); + String userId = SmsPropertiesUtil.get("userid"); + if("02".equals(smsObjType)){ + userId = SmsPropertiesUtil.get("urge_userid"); + } // Message message = new Message(); // û˺ ָû˺ŷͣҪдû˺ţָû˺ŷͣдû˺ - // message.setUserid(userid); + message.setUserid(userId); // ֻ ˴ֻһֻ message.setMobile(phoneNo); // @@ -166,7 +173,6 @@ public class SmsController { return message; } - public String getSmsObjType() { return smsObjType; } diff --git a/src/com/ample/sms/SmsSendManager.java b/src/com/ample/sms/SmsSendManager.java index 30d597366..f89be5acf 100644 --- a/src/com/ample/sms/SmsSendManager.java +++ b/src/com/ample/sms/SmsSendManager.java @@ -46,11 +46,27 @@ public class SmsSendManager { //globalParams.setMoFixedKey("0123456789abcdeffedcba9876543210"); // û˺Ϣ - setAccountInfo(SmsObjType.NORMAL); - + setAccountInfo(); } + public static void accountCheck(){ + if(!(accountExist(SmsPropertiesUtil.get("userid"))&&accountExist(SmsPropertiesUtil.get("urge_userid")))) { + SmsSendManager.setAccountInfo(); + } + } + public static boolean accountExist(String userId){ + Account account = (Account) ConfigManager.accountMap.get(userId); + if (account == null) { + return false; + }else{ + return true; + } + } + public static void setAccountInfo(){ + setAccountInfo(SmsObjType.NORMAL); + setAccountInfo(SmsObjType.URGE_COLLECTION); + } /** * @description û˺Ϣ */ diff --git a/src_core/com/tenwa/officetempalte/controller/RentNotinyDeleteAction.java b/src_core/com/tenwa/officetempalte/controller/RentNotinyDeleteAction.java index 2c777409b..bd2b33491 100644 --- a/src_core/com/tenwa/officetempalte/controller/RentNotinyDeleteAction.java +++ b/src_core/com/tenwa/officetempalte/controller/RentNotinyDeleteAction.java @@ -135,4 +135,33 @@ public class RentNotinyDeleteAction { } + + //ǰ̨ĵ + public void deletequtationByType(JBOTransaction tx) throws Exception{ + BizObjectManager bom=JBOFactory.getBizObjectManager(jbo.app.tenwa.doc.LB_DOCRELATIVE.CLASS_NAME); + BizObject DOCRELATIVE=null; + if(objecttype!=null){ + DOCRELATIVE=bom.createQuery(" PROJ_ID=:projectId and OBJECTTYPE=:objecttype"). + setParameter("projectId",projectId).setParameter("objecttype",objecttype).getSingleResult(false); + System.out.println("deletequtationBytype---------------------------:---"+objecttype); + } + if(DOCRELATIVE!=null){ + String DOCRELATIVEid=DOCRELATIVE.getAttribute("id").toString(); + BizObjectManager bom1=JBOFactory.getBizObjectManager(jbo.app.tenwa.doc.LB_DOCLIBRARY.CLASS_NAME); + String DOCLIBRARYid=bom1.createQuery("relative_id=:relative_id").setParameter("relative_id", DOCRELATIVEid).getSingleResult(false).getAttribute("id").toString(); + BizObjectManager bom2=JBOFactory.getBizObjectManager(jbo.app.tenwa.doc.LB_DOCATTRIBUTE.CLASS_NAME); + String DOCATTRIBUTEid=bom2.createQuery("library_id=:library_id").setParameter("library_id", DOCLIBRARYid).getSingleResult(false).getAttribute("id").toString(); + Map condtion= new HashMap(); + condtion.put("id", DOCRELATIVEid); + DataOperatorUtil.deleteJBOByCondtion(jbo.app.tenwa.doc.LB_DOCRELATIVE.CLASS_NAME, condtion, tx); + condtion.clear(); + condtion.put("id", DOCLIBRARYid); + DataOperatorUtil.deleteJBOByCondtion(jbo.app.tenwa.doc.LB_DOCLIBRARY.CLASS_NAME, condtion, tx); + condtion.clear(); + condtion.put("id", DOCATTRIBUTEid); + DataOperatorUtil.deleteJBOByCondtion(jbo.app.tenwa.doc.LB_DOCATTRIBUTE.CLASS_NAME, condtion, tx); + } + + + } } \ No newline at end of file diff --git a/src_jbo/jbo/app/LB_EQUIPMENT_CAR.java b/src_jbo/jbo/app/LB_EQUIPMENT_CAR.java index 7be55deec..59da0d58a 100644 --- a/src_jbo/jbo/app/LB_EQUIPMENT_CAR.java +++ b/src_jbo/jbo/app/LB_EQUIPMENT_CAR.java @@ -13,6 +13,11 @@ public interface LB_EQUIPMENT_CAR{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.LB_EQUIPMENT_CAR"; + /** + * + * -;" STRING(32)
+ */ + public static final String car_use_type = "car_use_type"; /** * ʶ STRING(32)
*/ diff --git a/src_jbo/jbo/app/LB_EQUIPMENT_CAR_TEMP.java b/src_jbo/jbo/app/LB_EQUIPMENT_CAR_TEMP.java index 3bde31cb8..ba34733d1 100644 --- a/src_jbo/jbo/app/LB_EQUIPMENT_CAR_TEMP.java +++ b/src_jbo/jbo/app/LB_EQUIPMENT_CAR_TEMP.java @@ -13,6 +13,12 @@ public interface LB_EQUIPMENT_CAR_TEMP{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.LB_EQUIPMENT_CAR_TEMP"; + /** + * + * -;" STRING(32)
+ */ + public static final String car_use_type = "car_use_type"; + /** * ʶ STRING(32)
*/ diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY.java index 3c6db528b..c18fa49a1 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY.java @@ -13,6 +13,120 @@ public interface CUSTOMER_FAMILY{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_FAMILY"; + + + + + // 20230817 Ʒ̨Խ-ͬ˳ + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + + /** + * ͬ˻״ STRING(32)
+ */ + public static final String marry_type = "marry_type"; + + /** + * ͬ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ͬ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ͬ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ͬ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ͬ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶͬ + // 20230809 Ʒ̨Խ-ֶͬ + /** + * ֤ͬЧ STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ͬ STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ͬѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ͬ˵λַ STRING(500)
+ */ + public static final String work_address = "work_address"; + + + /** + * ͬ˻ַ STRING(500)
+ */ + public static final String id_address = "id_address"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְͬҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ͬ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶͬ /** * ʶ STRING(32)
*/ @@ -125,4 +239,10 @@ public interface CUSTOMER_FAMILY{ * Ա STRING(32)
*/ public static final String SEX = "SEX"; + + + + + + } \ No newline at end of file diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_HIS.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_HIS.java index f2e175e0f..b32a2dd1d 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_HIS.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_HIS.java @@ -13,6 +13,119 @@ public interface CUSTOMER_FAMILY_HIS{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_FAMILY_HIS"; + + + + // 20230817 Ʒ̨Խ-ͬ˳ + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + + /** + * ͬ˻״ STRING(32)
+ */ + public static final String marry_type = "marry_type"; + + /** + * ͬ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ͬ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ͬ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ͬ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ͬ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶͬ + // 20230809 Ʒ̨Խ-ֶͬ + /** + * ֤ͬЧ STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ͬ STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ͬѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ͬ˵λַ STRING(500)
+ */ + public static final String work_address = "work_address"; + + + /** + * ͬ˻ַ STRING(500)
+ */ + public static final String id_address = "id_address"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְͬҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ͬ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶͬ /** * ʶ STRING(32)
*/ @@ -129,4 +242,5 @@ public interface CUSTOMER_FAMILY_HIS{ * Ա STRING(32)
*/ public static final String SEX = "SEX"; + } \ No newline at end of file diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_TEMP.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_TEMP.java index 8dc9effe4..8c624df96 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_TEMP.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_FAMILY_TEMP.java @@ -13,6 +13,118 @@ public interface CUSTOMER_FAMILY_TEMP{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_FAMILY_TEMP"; + + + // 20230817 Ʒ̨Խ-ͬ˳ + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + + /** + * ͬ˻״ STRING(32)
+ */ + public static final String marry_type = "marry_type"; + + /** + * ͬ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ͬ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ͬ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ͬ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ͬ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ͬ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶͬ + // 20230809 Ʒ̨Խ-ֶͬ + /** + * ֤ͬЧ STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ͬ STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ͬѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ͬ˵λַ STRING(500)
+ */ + public static final String work_address = "work_address"; + + + /** + * ͬ˻ַ STRING(500)
+ */ + public static final String id_address = "id_address"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ͬҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְͬҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ͬ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶͬ /** * ʶ STRING(32)
*/ diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON.java index 48aaf34a7..7a5c10f14 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON.java @@ -13,6 +13,61 @@ public interface CUSTOMER_PERSON{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_PERSON"; + + // 20230809 Ʒ̨Խ-ֶ + + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + + /** + * ˹ȥӪ STRING(32)
+ */ + public static final String pre_operate_car_type = "pre_operate_car_type"; + + /** + * ˹ȥӪƺ STRING(32)
+ */ + public static final String pre_operate_car_no = "pre_operate_car_no"; + + /** + * ˴ҵʱ STRING(32)
+ */ + public static final String pre_operate_years = "pre_operate_years"; + + // 20230809 Ʒ̨Խ-ֶ + + /** + * STRING(18)
+ */ + public static final String NATIONALITY = "NATIONALITY"; + /** * ʶ STRING(40)
*/ @@ -65,10 +120,7 @@ public interface CUSTOMER_PERSON{ * STRING(18)
*/ public static final String county = "county"; - /** - * STRING(18)
- */ - public static final String NATIONALITY = "NATIONALITY"; + /** * ַ STRING(200)
*/ @@ -381,4 +433,6 @@ public interface CUSTOMER_PERSON{ * STRING(32)
*/ public static final String e_mail = "e_mail"; + + } \ No newline at end of file diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_HIS.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_HIS.java index 0e2bd4ff1..682b7cd53 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_HIS.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_HIS.java @@ -13,6 +13,53 @@ public interface CUSTOMER_PERSON_HIS{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_PERSON_HIS"; + // 20230809 Ʒ̨Խ-ֶ + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + + /** + * ˹ȥӪ STRING(32)
+ */ + public static final String pre_operate_car_type = "pre_operate_car_type"; + + /** + * ˹ȥӪƺ STRING(32)
+ */ + public static final String pre_operate_car_no = "pre_operate_car_no"; + + /** + * ˴ҵʱ STRING(32)
+ */ + public static final String pre_operate_years = "pre_operate_years"; + + // 20230809 Ʒ̨Խ-ֶ + /** * ʶ STRING(40)
*/ @@ -381,4 +428,5 @@ public interface CUSTOMER_PERSON_HIS{ * 롪ż DOUBLE(22)
*/ public static final String smincome = "smincome"; + } \ No newline at end of file diff --git a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_TEMP.java b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_TEMP.java index 79ccc4122..859626ce5 100644 --- a/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_TEMP.java +++ b/src_jbo/jbo/app/tenwa/customer/CUSTOMER_PERSON_TEMP.java @@ -13,6 +13,66 @@ public interface CUSTOMER_PERSON_TEMP{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.app.tenwa.customer.CUSTOMER_PERSON_TEMP"; + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + // 20230809 Ʒ̨Խ-ֶ + + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + + /** + * ˹ȥӪ STRING(32)
+ */ + public static final String pre_operate_car_type = "pre_operate_car_type"; + + /** + * ˹ȥӪƺ STRING(32)
+ */ + public static final String pre_operate_car_no = "pre_operate_car_no"; + + /** + * ˴ҵʱ STRING(32)
+ */ + public static final String pre_operate_years = "pre_operate_years"; + + // 20230809 Ʒ̨Խ-ֶ + + /** + * λҵ STRING(50)
+ */ + public static final String UNITKIND = "UNITKIND"; + /** + * ְҵ STRING(18)
+ */ + public static final String OCCUPATION = "OCCUPATION"; + /** + * ְ STRING(18)
+ */ + public static final String title = "title"; /** * ʶ STRING(40)
*/ @@ -85,10 +145,7 @@ public interface CUSTOMER_PERSON_TEMP{ * ״ STRING(18)
*/ public static final String MARRIAGE = "MARRIAGE"; - /** - * λҵ STRING(50)
- */ - public static final String UNITKIND = "UNITKIND"; + /** * λ STRING(80)
*/ @@ -109,14 +166,7 @@ public interface CUSTOMER_PERSON_TEMP{ * ʽԱ STRING(32)
*/ public static final String FORMALEMP = "FORMALEMP"; - /** - * ְҵ STRING(18)
- */ - public static final String OCCUPATION = "OCCUPATION"; - /** - * ְ STRING(18)
- */ - public static final String title = "title"; + /** * STRING(200)
*/ @@ -385,4 +435,5 @@ public interface CUSTOMER_PERSON_TEMP{ * STRING(32)
*/ public static final String e_mail = "e_mail"; + } \ No newline at end of file diff --git a/src_jbo/jbo/com/tenwa/lease/comm/LB_EQUIPMENT_CAR_HIS.java b/src_jbo/jbo/com/tenwa/lease/comm/LB_EQUIPMENT_CAR_HIS.java index 6582d2ed5..cc8752697 100644 --- a/src_jbo/jbo/com/tenwa/lease/comm/LB_EQUIPMENT_CAR_HIS.java +++ b/src_jbo/jbo/com/tenwa/lease/comm/LB_EQUIPMENT_CAR_HIS.java @@ -13,6 +13,13 @@ public interface LB_EQUIPMENT_CAR_HIS{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR_HIS"; + + /** + * + * -;" STRING(32)
+ */ + public static final String car_use_type = "car_use_type"; + /** * ʶ STRING(32)
*/ diff --git a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT.java b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT.java index d60a395d2..77f2c1328 100644 --- a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT.java +++ b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT.java @@ -13,6 +13,117 @@ public interface LB_GUARANTEE_UNIT{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.com.tenwa.lease.comm.LB_GUARANTEE_UNIT"; + + // 20230817 Ʒ̨Խ-ֶ + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + /** + * ΪҵʱķϢ STRING(32)
+ */ + public static final String legal_representative = "legal_representative"; + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + /** + * ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + /** + * ְ STRING(32)
+ */ + public static final String duties_type = "duties_type"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶ + // 20230809 Ʒ̨Խ-ֶ + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address = "id_address"; + + /** + * ҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶ + /** * ʶ STRING(32)
*/ @@ -153,4 +264,5 @@ public interface LB_GUARANTEE_UNIT{ * λַ STRING(80)
*/ public static final String WORKADD = "WORKADD"; + } \ No newline at end of file diff --git a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_HIS.java b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_HIS.java index d7fdc7d04..d12b6d51d 100644 --- a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_HIS.java +++ b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_HIS.java @@ -13,6 +13,117 @@ public interface LB_GUARANTEE_UNIT_HIS{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.com.tenwa.lease.comm.LB_GUARANTEE_UNIT_HIS"; + + // 20230817 Ʒ̨Խ-ֶ + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + /** + * ΪҵʱķϢ STRING(32)
+ */ + public static final String legal_representative = "legal_representative"; + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + /** + * ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + /** + * ְ STRING(32)
+ */ + public static final String duties_type = "duties_type"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶ + // 20230809 Ʒ̨Խ-ֶ + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address = "id_address"; + + /** + * ҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶ + /** * ʶ STRING(32)
*/ @@ -149,4 +260,6 @@ public interface LB_GUARANTEE_UNIT_HIS{ * λַ STRING(80)
*/ public static final String WORKADD = "WORKADD"; + + } \ No newline at end of file diff --git a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_TEMP.java b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_TEMP.java index 85754dccf..ea87052a0 100644 --- a/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_TEMP.java +++ b/src_jbo/jbo/com/tenwa/lease/comm/LB_GUARANTEE_UNIT_TEMP.java @@ -13,6 +13,116 @@ public interface LB_GUARANTEE_UNIT_TEMP{ * ӳBizObjectClass */ public static final String CLASS_NAME = "jbo.com.tenwa.lease.comm.LB_GUARANTEE_UNIT_TEMP"; + // 20230817 Ʒ̨Խ-ֶ + /** + * start_idexpiry -Ƿбػ STRING(32)
+ */ + public static final String shukou = "shukou"; + /** + * start_idexpiry -֤Чͣ1ڣ2 STRING(32)
+ */ + public static final String idexpiry_type = "idexpiry_type"; + + /** + * start_idexpiry Чڿʼʱ STRING(32)
+ */ + public static final String start_idexpiry = "start_idexpiry"; + /** + * ΪҵʱķϢ STRING(32)
+ */ + public static final String legal_representative = "legal_representative"; + /** + * STRING(32)
+ */ + public static final String birthday = "birthday"; + + /** + * Ů STRING(32)
+ */ + public static final String childrens_number = "childrens_number"; + /** + * ˾ס״ STRING(32)
+ */ + public static final String residential_status = "residential_status"; + + /** + * ְ STRING(32)
+ */ + public static final String duties_type = "duties_type"; + + /** + * ˵λַ STRING(32)
+ */ + public static final String work_address_code = "work_address_code"; + + /** + * ˵λַid STRING(32)
+ */ + public static final String work_address_id = "work_address_id"; + + /** + * ˾סַ STRING(32)
+ */ + public static final String live_address_code = "live_address_code"; + + /** + * ˾סַid STRING(32)
+ */ + public static final String live_address_id = "live_address_id"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address_code = "id_address_code"; + + /** + * ˻ַid STRING(32)
+ */ + public static final String id_address_id = "id_address_id"; + + // 20230817 Ʒ̨Խ-ֶ + // 20230809 Ʒ̨Խ-ֶ + /** + * ֤Ч STRING(32)
+ */ + public static final String idexpiry = "idexpiry"; + + /** + * STRING(32)
+ */ + public static final String nation = "nation"; + + /** + * ѧ STRING(32)
+ */ + public static final String education_level = "education_level"; + + /** + * ˻ַ STRING(32)
+ */ + public static final String id_address = "id_address"; + + /** + * ҵ STRING(32)
+ */ + public static final String enterprise_nature = "enterprise_nature"; + + /** + * ҵ STRING(32)
+ */ + public static final String industry_type = "industry_type"; + + /** + * ְҵ STRING(32)
+ */ + public static final String career_type = "career_type"; + + /** + * ֧ STRING(32)
+ */ + public static final String monthly_expenses = "monthly_expenses"; + // 20230809 Ʒ̨Խ-ֶ + /** * ʶ STRING(32)
*/ @@ -149,4 +259,6 @@ public interface LB_GUARANTEE_UNIT_TEMP{ * λַ STRING(80)
*/ public static final String WORKADD = "WORKADD"; + + } \ No newline at end of file diff --git a/src_jbo/jbo/oti/ESB_LOG.java b/src_jbo/jbo/oti/ESB_LOG.java new file mode 100644 index 000000000..25a7db02a --- /dev/null +++ b/src_jbo/jbo/oti/ESB_LOG.java @@ -0,0 +1,63 @@ +package jbo.oti; + +/** + * esbͼ¼ - JBO

+ * Note: This file is generated by ADE tools, dont modify it.
+ + */ +public interface ESB_LOG { + /** + * ŷͼ¼

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.ESB_LOG"; + /** + * Ψһʶ LONG(64)
+ */ + public static final String ID = "ID"; + /** + * ȫΨһʶ LONG(64)
+ */ + public static final String GLOBAL_SEQ_NO = "GLOBAL_SEQ_NO"; + /** + * ȫΨһʶ LONG(64)
+ */ + public static final String TARGET_SEQ_NO = "TARGET_SEQ_NO"; + /** + * (15)
+ */ + public static final String TARGET_SYSTEM_ID = "TARGET_SYSTEM_ID"; + /** + * id STRING(990)
+ */ + public static final String SERVICE_ID = "SERVICE_ID"; + /** + * ͨѶ״̬ STRING(20)
+ */ + public static final String RET_CODE = "RET_CODE"; + /** + * 񷵻 STRING(50)
+ */ + public static final String RET_MSG = "RET_MSG"; + /** + * 񷵻ϵͳ STRING(32)
+ */ + public static final String RET_SYSTEM_ID = "RET_SYSTEM_ID"; + /** + * 񷵻Ϣ STRING(32)
+ */ + public static final String TRAN_CODE = "TRAN_CODE"; + /** + * 񷵻Ϣ STRING(32)
+ */ + public static final String SOURCE_MACHINE_DATE = "SOURCE_MACHINE_DATE"; + /** + * ¼ʱ STRING(100)
+ */ + public static final String INPUTTIME = "INPUTTIME"; + /** + * ¼ʱ STRING(100)
+ */ + public static final String UPDATETIME = "UPDATETIME"; + +} \ No newline at end of file diff --git a/src_jbo/jbo/oti/RC_ADDRESS_INFO.java b/src_jbo/jbo/oti/RC_ADDRESS_INFO.java new file mode 100644 index 000000000..f9268463e --- /dev/null +++ b/src_jbo/jbo/oti/RC_ADDRESS_INFO.java @@ -0,0 +1,67 @@ +package jbo.oti; +import java.lang.String; + +/** + * ֵϢ rc_address_library + */ +public interface RC_ADDRESS_INFO { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_ADDRESS_INFO"; + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + + public static final String address_id = "address_id"; + /** + * ʡ STRING(20)
+ */ + public static final String province_code = "province_code"; + /** + * ʡ STRING(20)
+ */ + public static final String province_value = "province_value"; + /** + * б STRING(20)
+ */ + public static final String city_code = "city_code"; + /** + * STRING(20)
+ */ + public static final String city_value = "city_value"; + /** + * ر STRING(20)
+ */ + public static final String district_code = "district_code"; + + /** + * STRING(20)
+ */ + public static final String district_value = "district_value"; + + /** + * ϸַ STRING(20)
+ */ + public static final String address_detail = "address_detail"; + + /** + * ȫַ STRING(20)
+ */ + public static final String full_address = "full_address"; + + /** + * ŵַ STRING(20)
+ */ + public static final String ap_address_code = "ap_address_code"; + + /** + * ŵַ STRING(20)
+ */ + public static final String ap_address_value = "ap_address_value"; + +} diff --git a/src_jbo/jbo/oti/RC_ADDRESS_LIBRARY.java b/src_jbo/jbo/oti/RC_ADDRESS_LIBRARY.java new file mode 100644 index 000000000..bbea4ba54 --- /dev/null +++ b/src_jbo/jbo/oti/RC_ADDRESS_LIBRARY.java @@ -0,0 +1,62 @@ +package jbo.oti; + +/** + * ֵϢ rc_address_library + */ +public interface RC_ADDRESS_LIBRARY { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_ADDRESS_LIBRARY"; + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + /** + * ַ STRING(20)
+ */ + public static final String address_code = "address_code"; + /** + * ַ STRING(20)
+ */ + public static final String address_value = "address_value"; + /** + * ϼַ STRING(20)
+ */ + public static final String parent_address_code = "parent_address_code"; + /** + * ϼַ STRING(20)
+ */ + public static final String parent_address_value = "parent_address_value"; + /** + * ϼַ STRING(20)
+ */ + public static final String grant_address_code = "grant_address_code"; + + /** + * ϼַ STRING(20)
+ */ + public static final String grant_address_value = "grant_address_value"; + + /** + * ַ STRING(20)
+ */ + public static final String address_code_level = "address_code_level"; + + /** + * ַ STRING(20)
+ */ + public static final String ap_library_code = "ap_library_code"; + /** + * ַ STRING(20)
+ */ + public static final String ap_address_code = "ap_address_code"; + /** + * ַ STRING(20)
+ */ + public static final String ap_address_value = "ap_address_value"; + +} diff --git a/src_jbo/jbo/oti/RC_CALLBACK_LOG.java b/src_jbo/jbo/oti/RC_CALLBACK_LOG.java new file mode 100644 index 000000000..0c9e1294f --- /dev/null +++ b/src_jbo/jbo/oti/RC_CALLBACK_LOG.java @@ -0,0 +1,46 @@ +package jbo.oti; + +/** + * Ʒַ̨թ־ rc_score_result_log + */ +public interface RC_CALLBACK_LOG { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_CALLBACK_LOG"; + + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + public static final String callback_id = "callback_id"; + + /** + * ҵ + */ + public static final String project_no = "project_no"; + + /** + * ͽֽͣ score, թ fraud + */ + public static final String callback_type = "callback_type"; + + + public static final String callback_data = "callback_data"; + + /** + * ״̬0 ؽ1 ؽѴ + */ + public static final String handle_sts = "handle_sts"; + + public static final String handle_value = "handle_value"; + + public static final String input_time = "input_time"; + + public static final String update_time = "update_time"; + + } + diff --git a/src_jbo/jbo/oti/RC_LIBRARY.java b/src_jbo/jbo/oti/RC_LIBRARY.java new file mode 100644 index 000000000..5a1f0a582 --- /dev/null +++ b/src_jbo/jbo/oti/RC_LIBRARY.java @@ -0,0 +1,50 @@ +package jbo.oti; + +/** + * ֵϢ rc_library + */ +public interface RC_LIBRARY { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_LIBRARY"; + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + /** + * ֵ STRING(20)
+ */ + public static final String library_no = "library_no"; + /** + * ֵ STRING(20)
+ */ + public static final String library_value = "library_value"; + /** + * ǩ STRING(20)
+ */ + public static final String ap_item_no = "ap_item_no"; + /** + * ǩ STRING(20)
+ */ + public static final String ap_item_value = "ap_item_value"; + /** + * Ʊǩ STRING(20)
+ */ + public static final String bc_item_no = "bc_item_no"; + + /** + * Ʊǩ STRING(20)
+ */ + public static final String bc_item_value = "bc_item_value"; + + /** + * STRING(20)
+ */ + public static final String operate_type = "operate_type"; + + +} diff --git a/src_jbo/jbo/oti/RC_SCORE_RESULT.java b/src_jbo/jbo/oti/RC_SCORE_RESULT.java new file mode 100644 index 000000000..eb510d90c --- /dev/null +++ b/src_jbo/jbo/oti/RC_SCORE_RESULT.java @@ -0,0 +1,73 @@ +package jbo.oti; + +/** + * Ʒֽ̨ rc_score_result + */ +public interface RC_SCORE_RESULT { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_SCORE_RESULT"; + /** + * id + * STRING(20)
+ */ + public static final String id = "id"; + + /** + * Ψһʶ + */ + public static final String score_result_id = "score_result_id"; + /** + * ˮ + */ + public static final String tran_no = "tran_no"; + /** + * ҵ + */ + public static final String project_no = "project_no"; + + + /** + * ̱ + */ + public static final String flow_no = "flow_no"; + + /** + * թԤHSC + */ + public static final String fraud_alert_code = "fraud_alert_code"; + + + /** + * թжFKS + */ + public static final String fraud_taken_code = "fraud_taken_code"; + + + /** + * ֽ AA RR RD DD + */ + public static final String score_result_code = "score_result_code"; + + /** + * ֽҳ + */ + public static final String score_result_url = "score_result_url"; + + + /** + * Ǽʱ + */ + public static final String input_time = "input_time"; + + + /** + * ʱ + */ + public static final String update_time = "update_time"; + + +} diff --git a/src_jbo/jbo/oti/RC_SCORE_RESULT_DETAIL.java b/src_jbo/jbo/oti/RC_SCORE_RESULT_DETAIL.java new file mode 100644 index 000000000..8b51e4b70 --- /dev/null +++ b/src_jbo/jbo/oti/RC_SCORE_RESULT_DETAIL.java @@ -0,0 +1,102 @@ +package jbo.oti; + +/** + * Ʒֽ̨ϸҳ RC_SCORE_RESULT_DETAIL + */ +public interface RC_SCORE_RESULT_DETAIL { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_SCORE_RESULT_DETAIL"; + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + + /** + * Ψһʶ + */ + public static final String score_result_id = "score_result_id"; + + /** + * ҵ + */ + public static final String score_result_detail_id = "score_result_detail_id"; + + /** + * ˮ + */ + public static final String tran_no = "tran_no"; + + /** + * ҵ + */ + public static final String project_no = "project_no"; + + + /** + * ̱ + */ + public static final String flow_no = "flow_no"; + + /** + * Աͣˡˡ + */ + public static final String person_type = "person_type"; + + /** + * Ա + */ + public static final String person_name = "person_name"; + + + /** + * Ա֤ + */ + public static final String person_card_type = "person_card_type"; + + + /** + * Ա֤ + */ + public static final String person_card_no = "person_card_no"; + + + /** + * ӵַ + */ + public static final String third_result_url = "third_result_url"; + + + /** + * pbocӵַ + */ + public static final String pboc_result_url = "pboc_result_url"; + + + /** + * Ǽʱ + */ + public static final String input_time = "input_time"; + + + /** + * ʱ + */ + public static final String update_time = "update_time"; + + public static final String score_level = "score_level"; + + public static final String third_state_code = "third_state_code"; + + public static final String error_message = "error_message"; + + public static final String name_result = "name_result"; + + public static final String cert_id_result = "cert_id_result"; + + } + diff --git a/src_jbo/jbo/oti/RC_SCORE_RESULT_LOG.java b/src_jbo/jbo/oti/RC_SCORE_RESULT_LOG.java new file mode 100644 index 000000000..3f33f8cf8 --- /dev/null +++ b/src_jbo/jbo/oti/RC_SCORE_RESULT_LOG.java @@ -0,0 +1,70 @@ +package jbo.oti; + +/** + * Ʒַ̨թ־ rc_score_result_log + */ +public interface RC_SCORE_RESULT_LOG { + + /** + * ҵ

+ * ӳBizObjectClass + */ + public static final String CLASS_NAME = "jbo.oti.RC_SCORE_RESULT_LOG"; + + /** + * id` + * STRING(20)
+ */ + public static final String id = "id"; + + /** + * Ψһʶ + */ + public static final String score_result_id = "score_result_id"; + /** + * ˮ + */ + public static final String tran_no = "tran_no"; + + /** + * ҵ + */ + public static final String project_no = "project_no"; + + + /** + * ̱ + */ + public static final String flow_no = "flow_no"; + + /** + * թԤHSC + */ + public static final String fraud_alert_code = "fraud_alert_code"; + + + /** + * թжFKS + */ + public static final String fraud_taken_code = "fraud_taken_code"; + + + /** + * ֽ AA RR RD DD + */ + public static final String score_result_code = "score_result_code"; + + /** + * ֽҳ + */ + public static final String score_result_url = "score_result_url"; + + /** + * Ǽʱ + */ + public static final String input_time = "input_time"; + + + + } + diff --git a/src_tenwa/com/tenwa/httpclient/pboc/FileUtils.java b/src_tenwa/com/tenwa/httpclient/pboc/FileUtils.java new file mode 100644 index 000000000..90f086ecf --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/FileUtils.java @@ -0,0 +1,64 @@ +package com.tenwa.httpclient.pboc; + +import com.tenwa.reckon.util.DateUtils; +import org.apache.commons.codec.binary.Base64; + +import java.io.File; +import java.io.FileOutputStream; +import java.io.PrintStream; +import java.text.SimpleDateFormat; +import java.util.Date; + +public class FileUtils { + + /** + * xmlϢȡxmlļ + * @param filePath + * @param reportId + * @param resXMLReportStr + * @return + */ + public static String createXMLFile(String filePath, String reportId, String resXMLReportStr) throws Exception { + // TODO: 2023/1/31 ļַ޸ +// String xmlFilePath = filePath + "\\xmlHtml\\"+ reportId +".xml"; + SimpleDateFormat timeFormat = new SimpleDateFormat("yyyyMM"); + filePath = filePath + "/report/"+timeFormat.format(new Date())+ "/"; + File targetFolder = new File(filePath); + if (!targetFolder.exists()) { + targetFolder.mkdirs(); + } + String xmlFilePath = filePath + reportId +".xml"; + // TODO: 2023/1/31 дxmlļ + File xmlFile = new File(xmlFilePath); + xmlFile.createNewFile(); + PrintStream printStream = new PrintStream(new FileOutputStream(xmlFile)); + printStream.println(resXMLReportStr);//ַдļ + return xmlFilePath; + } + + /** + * xmlϢȡhtmlļ + * @param filePath + * @param reportId + * @param htmlRptDataStr + * @return + */ + public static String createHtmlFile(String filePath, String reportId, String htmlRptDataStr) throws Exception { + byte[] byteData = new Base64().decode(htmlRptDataStr); + // TODO: 2023/1/31 ļַ޸ +// String htmlFilePath = filePath + "\\xmlHtml\\"+ reportId +".html"; + SimpleDateFormat timeFormat = new SimpleDateFormat("yyyyMM"); + filePath = filePath + "/report/"+timeFormat.format(new Date())+ "/"; + File targetFolder = new File(filePath); + if (!targetFolder.exists()) { + targetFolder.mkdirs(); + } + String htmlFilePath = filePath + reportId +".html"; + // TODO: 2023/1/31 htmlдhtmlļ + File htmlFile = new File(htmlFilePath); + htmlFile.createNewFile(); + PrintStream printStreamHtml = new PrintStream(new FileOutputStream(htmlFile)); + printStreamHtml.println(new String(byteData));//ַдļ + return htmlFilePath; + } +} diff --git a/src_tenwa/com/tenwa/httpclient/pboc/HttpUtils.java b/src_tenwa/com/tenwa/httpclient/pboc/HttpUtils.java new file mode 100644 index 000000000..7464f4b8a --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/HttpUtils.java @@ -0,0 +1,180 @@ +package com.tenwa.httpclient.pboc; + + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import javax.net.ssl.*; +import java.io.*; +import java.net.ConnectException; +import java.net.SocketTimeoutException; +import java.net.URL; +import java.net.URLConnection; +import java.security.cert.X509Certificate; + +/** + * ͨhttpͷ + * + * @author zhanglei + */ +public class HttpUtils +{ + private static final Logger log = LoggerFactory.getLogger(HttpUtils.class); + /** + * ָ URL POST + * + * @param url URL + * @param param Ӧ name1=value1&name2=value2 ʽ + * @return ԶԴӦ + */ + public static String sendPost(String url, String param) + { + PrintWriter out = null; + BufferedReader in = null; + StringBuilder result = new StringBuilder(); + try + { + String urlNameString = url; +// log.info("sendPost - {}", urlNameString); + URL realUrl = new URL(urlNameString); + URLConnection conn = realUrl.openConnection(); + conn.setRequestProperty("accept", "*/*"); + conn.setRequestProperty("connection", "Keep-Alive"); + conn.setRequestProperty("user-agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;SV1)"); + conn.setRequestProperty("Accept-Charset", "utf-8"); + conn.setRequestProperty("Content-Type", "application/xml;charset=utf-8"); + conn.setRequestProperty("Content-Length", Integer.toString(param.length())); + conn.setConnectTimeout(3*60*1000); + conn.setDoOutput(true); + conn.setDoInput(true); + out = new PrintWriter(conn.getOutputStream()); + out.print(param); + out.flush(); + in = new BufferedReader(new InputStreamReader(conn.getInputStream(), "utf-8")); + String line; + while ((line = in.readLine()) != null) + { + result.append(line); + } +// log.info("recv - {}", result); + } + catch (ConnectException e) + { + log.error("HttpUtils.sendPost ConnectException, url=" + url + ",param=" + param, e); + } + catch (SocketTimeoutException e) + { + log.error("HttpUtils.sendPost SocketTimeoutException, url=" + url + ",param=" + param, e); + } + catch (IOException e) + { + log.error("HttpUtils.sendPost IOException, url=" + url + ",param=" + param, e); + } + catch (Exception e) + { + log.error("HttpsUtil.sendPost Exception, url=" + url + ",param=" + param, e); + } + finally + { + try + { + if (out != null) + { + out.close(); + } + if (in != null) + { + in.close(); + } + } + catch (IOException ex) + { + log.error("in.close Exception, url=" + url + ",param=" + param, ex); + } + } + return result.toString(); + } + + public static String sendSSLPost(String url, String param) + { + StringBuilder result = new StringBuilder(); + String urlNameString = url + "?" + param; + try + { + log.info("sendSSLPost - {}", urlNameString); + SSLContext sc = SSLContext.getInstance("SSL"); + sc.init(null, new TrustManager[] { new TrustAnyTrustManager() }, new java.security.SecureRandom()); + URL console = new URL(urlNameString); + HttpsURLConnection conn = (HttpsURLConnection) console.openConnection(); + conn.setRequestProperty("accept", "*/*"); + conn.setRequestProperty("connection", "Keep-Alive"); + conn.setRequestProperty("user-agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;SV1)"); + conn.setRequestProperty("Accept-Charset", "utf-8"); + conn.setRequestProperty("contentType", "utf-8"); + conn.setDoOutput(true); + conn.setDoInput(true); + + conn.setSSLSocketFactory(sc.getSocketFactory()); + conn.setHostnameVerifier(new TrustAnyHostnameVerifier()); + conn.connect(); + InputStream is = conn.getInputStream(); + BufferedReader br = new BufferedReader(new InputStreamReader(is)); + String ret = ""; + while ((ret = br.readLine()) != null) + { + if (ret != null && !ret.trim().equals("")) + { + result.append(new String(ret.getBytes("ISO-8859-1"), "utf-8")); + } + } + log.info("recv - {}", result); + conn.disconnect(); + br.close(); + } + catch (ConnectException e) + { + log.error("HttpUtils.sendSSLPost ConnectException, url=" + url + ",param=" + param, e); + } + catch (SocketTimeoutException e) + { + log.error("HttpUtils.sendSSLPost SocketTimeoutException, url=" + url + ",param=" + param, e); + } + catch (IOException e) + { + log.error("HttpUtils.sendSSLPost IOException, url=" + url + ",param=" + param, e); + } + catch (Exception e) + { + log.error("HttpsUtil.sendSSLPost Exception, url=" + url + ",param=" + param, e); + } + return result.toString(); + } + + private static class TrustAnyTrustManager implements X509TrustManager + { + @Override + public void checkClientTrusted(X509Certificate[] chain, String authType) + { + } + + @Override + public void checkServerTrusted(X509Certificate[] chain, String authType) + { + } + + @Override + public X509Certificate[] getAcceptedIssuers() + { + return new X509Certificate[] {}; + } + } + + private static class TrustAnyHostnameVerifier implements HostnameVerifier + { + @Override + public boolean verify(String hostname, SSLSession session) + { + return true; + } + } +} \ No newline at end of file diff --git a/src_tenwa/com/tenwa/httpclient/pboc/PbocAction.java b/src_tenwa/com/tenwa/httpclient/pboc/PbocAction.java new file mode 100644 index 000000000..99266bd84 --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/PbocAction.java @@ -0,0 +1,203 @@ +package com.tenwa.httpclient.pboc; + +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.*; +import com.amarsoft.are.util.StringFunction; +import com.amarsoft.awe.util.ASResultSet; +import com.amarsoft.awe.util.SqlObject; +import com.amarsoft.awe.util.Transaction; +import com.amarsoft.dict.als.cache.CacheLoaderFactory; +import com.tenwa.httpclient.resources.BigDataPropertiesUtil; +import com.tenwa.lease.app.quartzmession.CreditAuditHolidayBatch; +import com.tenwa.util.SerialNumberUtil; +import jbo.com.tenwa.entity.comm.message.BT_BUSSINESS_MESSAGE; +import jbo.oti.FC_REQUEST; +import jbo.oti.FC_REQUEST_FILE; +import org.apache.log4j.LogManager; +import org.apache.log4j.Logger; + +import java.util.List; + +public class PbocAction { + + private String fullName; + private String fullCertId; + private String fullPhone; + private String flowId; + private String projectNo; + private String actionType; + + + public PbocAction() { + } + + public String getActionType() { + return actionType; + } + + public void setActionType(String actionType) { + this.actionType = actionType; + } + + public String getFlowId() { + return flowId; + } + + public void setFlowId(String flowId) { + this.flowId = flowId; + } + + public String getProjectNo() { + return projectNo; + } + + public void setProjectNo(String projectNo) { + this.projectNo = projectNo; + } + + public String getFullName() { + return fullName; + } + + public void setFullName(String fullName) { + this.fullName = fullName; + } + + public String getFullCertId() { + return fullCertId; + } + + public void setFullCertId(String fullCertId) { + this.fullCertId = fullCertId; + } + + public String getFullPhone() { + return fullPhone; + } + + public void setFullPhone(String fullPhone) { + this.fullPhone = fullPhone; + } + + public PbocAction(String fullName, String fullCertId , String fullPhone) { + this.fullName = fullName; + this.fullCertId = fullCertId; + this.fullPhone = fullPhone; + } + + private static final Logger logger = LogManager.getLogger(PbocAction.class);// logger־ + + /** + * actionType : get: + * 1޽쳣δȡ + * 2нҪж״̬ + * 2.1ʧܣѯʧܣȡ + * 2.2trueִȡ + * 2.3ڽУŽڴУԺԣ + * actionType : save: + * 1޽trueִȡ + * 2нҪж״̬ + * 2.1ʧܣtrueִȡ + * 2.2trueִȡ + * 2.3ڽУŽڴУԺԣ + * @return + */ + public String checkReqData(){ + Transaction Sqlca=null; + String result = "false@ϵͳ쳣Ժԣ"; + try{ +// if(true){ +// JBOTransaction tx = JBOFactory.createJBOTransaction(); +// String applyId = SerialNumberUtil.getPengyuanNumber(tx); +// tx.commit(); +// logger.info("PbocAction.checkReqData====⡣"); +// return "true@"+applyId; +// } + logger.info("PbocActioncheckReqData start<<<<<<<<<<<<<"); + Sqlca = Transaction.createTransaction(CacheLoaderFactory.getDataSource()); + //ʱʼ󿼺˱ + String sql = "select max(id) applyid from bigdata_pboc_af where project_no='"+projectNo+"' and fullname='"+fullName + +"' and fullcertId='"+fullCertId+"' and fullphone='"+fullPhone+"' "; + + logger.info("sql======================"+sql+"========================================================"); + ASResultSet rs = Sqlca.getASResultSet(new SqlObject(sql)); + + if(rs.next()) { + String applyId = rs.getString("applyid"); + if(null == applyId || "null".equals(applyId.toLowerCase())){ + //޽ + if("GET".equals(actionType)){ + return "false@ǰûδȡִȡݣ"; + }else { + JBOTransaction tx = JBOFactory.createJBOTransaction(); + applyId = SerialNumberUtil.getPengyuanNumber(tx); + tx.commit(); + logger.info("PbocAction.checkReqData====1޽,applyid"); + return "true@"+applyId; + } + } + String sql2 = "select req_sts from bigdata_pboc_af where id='" + applyId+ "' "; + logger.info("sql2======================"+sql2+"========================================================"); + ASResultSet rs2 = Sqlca.getASResultSet(new SqlObject(sql2)); + // req_sts : 0,У-1 ʧܣ-2 ɹ + if(rs2.next()) {// + String reqSts = rs2.getString("req_sts"); + if(null == reqSts || "null".equals(reqSts.toLowerCase())){ + return "false@Ųѯ״̬쳣"; + } + if("0".equals(reqSts)){ + return "false@ŽڴУԺԣ"; + }else if("-1".equals(reqSts)){//ѯʧ + if("GET".equals(actionType)){ + return "false@ѯʧܣȡȡݻϵԱ"; + }else { + JBOTransaction tx = JBOFactory.createJBOTransaction(); + applyId = SerialNumberUtil.getPengyuanNumber(tx); + tx.commit(); + logger.info("PbocAction.checkReqData====2޽,applyid"); + return "true@"+applyId; + } + }else if("1".equals(reqSts)){//ɹ + logger.info("PbocAction.checkReqData====3н,ؽ===applyId="+applyId); + return "true@" + applyId; + }else {//״̬쳣 + return "false@ѯʧܣȡȡݻϵԱ"; + } + }else { + return "false@ѯʧܣȡȡݻϵԱ"; + } + }else { + //޽ + if("GET".equals(actionType)){ + return "false@ǰûδȡִȡݣ"; + }else { + JBOTransaction tx = JBOFactory.createJBOTransaction(); + String applyId = SerialNumberUtil.getPengyuanNumber(tx); + tx.commit(); + logger.info("PbocAction.checkReqData====4޽,applyid"); + return "true@"+applyId; + } + } + }catch(Exception e){ + e.printStackTrace(); + logger.error("<<<<<<<<<<<<<<<<<<<<<>>>>>1>>>>>>>>>>>>>>>>>", e); + try { + Sqlca.rollback(); + } catch (JBOException e1) { + e1.printStackTrace(); + logger.error("<<<<<<<<<<<<<<<<<<<<<>>>>>2>>>>>>>>>>>>>>>>>", e1); + } + }finally { + if(Sqlca!=null) { + try { + Sqlca.commit(); + } catch (JBOException e) { + e.printStackTrace(); + logger.error("<<<<<<<<<<<<<<<<<<<<<>>>>>3>>>>>>>>>>>>>>>>>", e); + } + } + } + return result; + } + +} diff --git a/src_tenwa/com/tenwa/httpclient/pboc/PbocNewDataController.java b/src_tenwa/com/tenwa/httpclient/pboc/PbocNewDataController.java new file mode 100644 index 000000000..84888b1a2 --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/PbocNewDataController.java @@ -0,0 +1,234 @@ +package com.tenwa.httpclient.pboc; + +import com.alibaba.fastjson.JSONObject; +import com.amarsoft.are.ARE; +import com.amarsoft.are.jbo.JBOException; +import com.amarsoft.are.util.StringFunction; +import com.amarsoft.awe.Configure; +import com.amarsoft.awe.control.model.Page; +import com.amarsoft.awe.util.SqlObject; +import com.amarsoft.awe.util.Transaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.httpclient.resources.BigDataPropertiesUtil; +import org.apache.commons.lang3.StringUtils; +import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; +import java.util.Map; + +public class PbocNewDataController { + + + /** + * pbocѯ߲ѯ + * @param params + * @param table + * @param Sqlca + * @param actionType + * @param applyId + * @param CurPage + * @return + * @throws Exception + */ + public String findAndSavePbocData(Map params, String table, Transaction Sqlca, String actionType, String applyId, Page CurPage) throws Exception { + String type = "html"; + ARE.getLog().info("PbocNewDataController.findAndSavePbocData====applyid="+applyId); + String htmlFilePath = Sqlca.getString(new SqlObject("select html_data from bigdata_pboc_af where id = '" + applyId + "'")); + if(null != htmlFilePath && !"null".equals(htmlFilePath.toLowerCase())){ + return htmlFilePath; + } + // TODO: 2023-5-5 ¼״̬ΪС ־ + // TODO: 2023/2/1 pboc˵ʲѯ id + String flowId = CurPage.getParameter("flowId");//̱ + String projectNo = CurPage.getParameter("projectNo");//ҵ + String personQueryParamStr = PbocXmlUtils.createPersonQueryParamStr(params, CurPage.getAttribute("subjectId").toString()); + ARE.getLog().info("pboc===============fullName==="+CurPage.getParameter("fullName")); + ARE.getLog().info("pboc===============fullCertId==="+CurPage.getParameter("fullCertId")); + ARE.getLog().info("pboc===============fullPhone==="+CurPage.getParameter("fullPhone")); + SqlObject sql = new SqlObject(("insert into bigdata_pboc_af (id,req_sts,begin_time,inputuserid,inputorgid,inputtime,flow_id,project_no,fullName,fullcertId,fullphone) values('" + + applyId+ "','0','" + System.currentTimeMillis() + "','" + CurPage.getUserId() + "','" + CurPage.getUser().getOrgID() + "','" + StringFunction.getTodayNow() +"','" + + flowId +"','" + projectNo +"','" + +CurPage.getParameter("fullName")+"','"+CurPage.getParameter("fullCertId")+"','"+CurPage.getParameter("fullPhone")+"')").replaceAll(":", "")); + sql.setDebugSql(sql.getDebugSql().replaceAll("", ":")); + sql.setOriginalSql(sql.getOriginalSql().replaceAll("", ":")); + sql.setRunSql(sql.getRunSql().replaceAll("", ":")); + Sqlca.executeSQL(sql); + //log + SqlObject sqlLog = new SqlObject(("insert into bigdata_pboc_af_log (pboc_id,req_sts,req_time,http_url,http_param,inputuserid,inputorgid,inputtime,flow_id,project_no,fullName,fullcertId,fullphone) values('" + + applyId+ "','0','" + System.currentTimeMillis()+ "','" + BigDataPropertiesUtil.get("pboc_url") + "','" + personQueryParamStr + + "','" + CurPage.getUserId() + "','" + CurPage.getUser().getOrgID() + "','" + StringFunction.getTodayNow() + +"','"+ flowId +"','" + projectNo + +"','" +CurPage.getParameter("fullName")+"','"+CurPage.getParameter("fullCertId") + +"','"+CurPage.getParameter("fullPhone")+"')").replaceAll(":", "")); + sqlLog.setDebugSql(sqlLog.getDebugSql().replaceAll("", ":")); + sqlLog.setOriginalSql(sqlLog.getOriginalSql().replaceAll("", ":")); + sqlLog.setRunSql(sqlLog.getRunSql().replaceAll("", ":")); + Sqlca.executeSQL(sqlLog); + // TODO: 2023-5-5 첽ýӿ,ļ¼ ־ + asyncReqHttp(applyId,personQueryParamStr,CurPage); + return "false@ȡУԺٽвѯ"; + } + + private void asyncReqHttp(String applyId, String personQueryParamStr, Page curPage) { + ThreadPoolTaskExecutor threadPool = PbocThreadPool.getInstance(); + threadPool.execute(()->{ + try { + asyncReqHttpAndSave(applyId, personQueryParamStr, curPage); + } catch (Exception e) { + throw new RuntimeException(e); + } + }); + } + + /** + * pbocѯżϢ + * @param params + * @param applyId + * @return + * @throws Exception + */ + public String queryPbocData(Map params, Transaction Sqlca, String applyId) throws Exception { + String type = "html"; + ARE.getLog().info("PbocNewDataController.findAndSavePbocData====applyid=" + applyId); + String xmlDataContent = Sqlca.getString(new SqlObject("select xml_data_content from bigdata_pboc_af where id = '" + applyId + "'")); + if(null != xmlDataContent){ + JSONObject resJson = PbocXmlUtils.toJson(xmlDataContent); + JSONObject serviceDataJson = resJson.getJSONObject("service"); + JSONObject msgBodyData = serviceDataJson.getJSONObject("msgBody"); + JSONObject xmlRptData = msgBodyData.getJSONObject("xmlRpt"); + JSONObject DocumentData = xmlRptData.getJSONObject("Document"); + JSONObject PMMData = DocumentData.getJSONObject("PMM"); + JSONObject PB02Data = PMMData.getJSONObject("PB02"); + String poName = PB02Data.getString("PB020Q01"); + if(null == poName){ + return null; + } + String poCertId = PB02Data.getString("PB020I01") == null ? "0" : PB02Data.getString("PB020I01"); + return poName+"@"+poCertId; + } + return null; + } + + /** + * 첽ִзpbocѯ + */ + private void asyncReqHttpAndSave(String applyId, String personQueryParamStr, Page CurPage) throws Exception { + String type = "html"; + String xmlFilePath = null; + String htmlFilePath = null; + String resXMLReport = null; + String reportId = null; + JSONObject resJson = null; + String resSts = "1";//req_sts : 0,У-1 ʧܣ1 ɹ + try{ + // : 2023/2/1 ز + @SuppressWarnings("deprecation") + Configure configure = Configure.getInstance(); + String fileSavePath = configure.getParameter("FileSavePath") + "/" + "pboc"; + resXMLReport = this.findQueryReport(personQueryParamStr, type, CurPage.getAttribute("subjectId").toString()); + resJson = PbocXmlUtils.toJson(resXMLReport); + JSONObject serviceDataJson = resJson.getJSONObject("service"); + JSONObject msgHeadData = serviceDataJson.getJSONObject("msgHead"); + ARE.getLog().info("========================pboc=================="); + ARE.getLog().info("<<<<<<<<<<<<<<<<<<<<<>>>>>20230816 querypbocressuccess >>>>>>>>>>>>>>>>>"+ msgHeadData.toJSONString()); + ARE.getLog().info("========================pboc=================="); + String resCode = msgHeadData.getString("resCode"); + if("000".equals(resCode)){ + reportId = msgHeadData.getString("resJnlId"); + JSONObject msgBodyData = serviceDataJson.getJSONObject("msgBody"); + ARE.getLog().info("========================pbocسɹ=================="); + ARE.getLog().info("<<<<<<<<<<<<<<<<<<<<<>>>>>20230816 querypbocressuccess >>>>>>>>>>>>>>>>>"+ resCode); + ARE.getLog().info("========================pbocسɹ=================="); + String htmlRptDataStr = msgBodyData.getString("htmlRpt"); + // : 2023-5-24 ɾhtmlݴ洢 + //msgBodyData.remove("htmlRpt"); + // : 2023-5-24 ɾhtmlݴ洢 + xmlFilePath = FileUtils.createXMLFile(fileSavePath, reportId, resXMLReport); + htmlFilePath = FileUtils.createHtmlFile(fileSavePath, reportId, htmlRptDataStr); + ARE.getLog().info(htmlFilePath); + ARE.getLog().info(xmlFilePath); + }else {//״̬쳣 + resSts = "-1";//req_sts : 0,У-1 ʧܣ1 ɹ + ARE.getLog().info("========================pboc쳣=================="); + ARE.getLog().error("<<<<<<<<<<<<<<<<<<<<<>>>>>20230816 querypbocreserror >>>>>>>>>>>>>>>>>"+ resCode); + ARE.getLog().info("========================pboc쳣=================="); + } + }catch (Exception e){ + ARE.getLog().info("========================pboc쳣=================="); + ARE.getLog().error("<<<<<<<<<<<<<<<<<<<<<>>>>>01>>>>>>>>>>>>>>>>>", e); + ARE.getLog().info("========================pboc쳣=================="); + resSts = "-1";//req_sts : 0,У-1 ʧܣ1 ɹ + } + Transaction Sqlca=null; + try{ + Sqlca = Transaction.createTransaction("als"); + // TODO: 2023-5-5 첽ýӿ,ļ¼ ־ + SqlObject sql = new SqlObject(("update bigdata_pboc_af set pboc_report_id='"+reportId+"'," + +"xml_data='"+xmlFilePath+"'," +// +"xml_data_content='"+resXMLReport+"'," + // TODO: 2023-5-24 ɾhtmlݴ洢 +// +"xml_data_content='"+PbocXmlUtils.jsonStr2Xml(resJson.toJSONString())+"'," + +"xml_data_content='"+resXMLReport+"'," + // TODO: 2023-5-24 ɾhtmlݴ洢 + +"html_data='"+htmlFilePath+"'," + +"req_sts='"+resSts+"'," + +"end_time='"+ System.currentTimeMillis() +"'" + +" where id='"+ applyId +"'").replaceAll(":", "")); + sql.setDebugSql(sql.getDebugSql().replaceAll("", ":")); + sql.setOriginalSql(sql.getOriginalSql().replaceAll("", ":")); + sql.setRunSql(sql.getRunSql().replaceAll("", ":")); + Sqlca.executeSQL(sql); + //log + SqlObject sqlLog = new SqlObject(("insert into bigdata_pboc_af_log (pboc_id,req_sts,req_time,http_url,http_param,http_res,inputuserid,inputorgid,inputtime,fullName,fullcertId,fullphone) values('" + + applyId+ "','"+resSts+"','" + System.currentTimeMillis()+ "','" + BigDataPropertiesUtil.get("pboc_url") + "','" + personQueryParamStr + + "','" + reportId + + "','" + CurPage.getUserId() + "','" + CurPage.getUser().getOrgID() + "','" + StringFunction.getTodayNow() + +"','" +CurPage.getParameter("fullName")+"','"+CurPage.getParameter("fullCertId") + +"','"+CurPage.getParameter("fullPhone")+"')").replaceAll(":", "")); + sqlLog.setDebugSql(sqlLog.getDebugSql().replaceAll("", ":")); + sqlLog.setOriginalSql(sqlLog.getOriginalSql().replaceAll("", ":")); + sqlLog.setRunSql(sqlLog.getRunSql().replaceAll("", ":")); + Sqlca.executeSQL(sqlLog); + }catch(Exception e){ + e.printStackTrace(); + ARE.getLog().error("<<<<<<<<<<<<<<<<<<<<<>>>>>1>>>>>>>>>>>>>>>>>", e); + try { + Sqlca.rollback(); + } catch (JBOException e1) { + e1.printStackTrace(); + ARE.getLog().error("<<<<<<<<<<<<<<<<<<<<<>>>>>2>>>>>>>>>>>>>>>>>", e1); + } + }finally { + if(Sqlca!=null) { + try { + Sqlca.commit(); + } catch (JBOException e) { + e.printStackTrace(); + ARE.getLog().error("<<<<<<<<<<<<<<<<<<<<<>>>>>3>>>>>>>>>>>>>>>>>", e); + } + } + } + } + + public String findQueryReport(String params, String type, String SubjectId) throws Exception { + ARE.getLog().info("========================pboc=================="); + ARE.getLog().info(params); + ARE.getLog().info("========================pboc=================="); + String result = ""; + try{ + String url = BigDataPropertiesUtil.get("pboc_url"); + result = HttpUtils.sendPost(url, params); + if(StringUtils.isEmpty(result)){ + ARE.getLog().info("==================ֵΪ====================" ); + throw new RuntimeException("ȡʧ"); + }else if(result.length() < 2000){ + ARE.getLog().info("==================result====================" + result); + } + } catch(Exception e) { + e.printStackTrace(); + throw new BusinessException("ȡʧ"); + } + + return result; + } + +} + diff --git a/src_tenwa/com/tenwa/httpclient/pboc/PbocThreadPool.java b/src_tenwa/com/tenwa/httpclient/pboc/PbocThreadPool.java new file mode 100644 index 000000000..d126daafc --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/PbocThreadPool.java @@ -0,0 +1,65 @@ +package com.tenwa.httpclient.pboc; + +import org.apache.log4j.LogManager; +import org.apache.log4j.Logger; +import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; + +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; + +public class PbocThreadPool implements ServletContextListener { + private static final Logger logger = LogManager.getLogger(PbocThreadPool.class);// logger־ + private static volatile ThreadPoolTaskExecutor threadPool; + private static boolean flag = false; + + + @Override + public void contextInitialized(ServletContextEvent servletContextEvent) { + logger.info("==================================PbocThreadPool.contextInitialized.start==============================="); + } + + @Override + public void contextDestroyed(ServletContextEvent servletContextEvent) { + try { + logger.info("==================================PbocThreadPool.contextDestroyed.start==============================="); + if(threadPool != null){ + threadPool.shutdown(); + logger.info("==================================PbocThreadPool.contextDestroyed.end============shutdown==================="); + }else { + logger.info("==================================PbocThreadPool.contextDestroyed.end==============================="); + } + } catch (Exception e) { + e.printStackTrace(); + logger.info("==================================PbocThreadPool.contextDestroyed.error==============================="); + } + } + + public PbocThreadPool(){ + } + + public static ThreadPoolTaskExecutor getInstance(){ + logger.info("==================================PbocThreadPool.getInstance.start==============================="); + if(!flag){ + synchronized (ThreadPoolTaskExecutor.class){ + if(threadPool == null){ + // ̳߳߳ + threadPool = new ThreadPoolTaskExecutor(); + // ̳߳ά̵߳ + threadPool.setCorePoolSize(3); + // ̳߳ά̵߳ + threadPool.setMaxPoolSize(6); + //߳ǰ׺ + threadPool.setThreadNamePrefix("bigdata_http_pboc_"); + //öг + threadPool.setQueueCapacity(10); +// threadPool.setKeepAliveSeconds(300); + // shutdownʱȴǰȵ + threadPool.setWaitForTasksToCompleteOnShutdown(true); + threadPool.initialize(); + flag = true; + } + } + } + return threadPool; + } +} diff --git a/src_tenwa/com/tenwa/httpclient/pboc/PbocXmlUtils.java b/src_tenwa/com/tenwa/httpclient/pboc/PbocXmlUtils.java new file mode 100644 index 000000000..dd2c37a6d --- /dev/null +++ b/src_tenwa/com/tenwa/httpclient/pboc/PbocXmlUtils.java @@ -0,0 +1,277 @@ +package com.tenwa.httpclient.pboc; + +import com.alibaba.fastjson.JSON; +import com.alibaba.fastjson.JSONArray; +import com.alibaba.fastjson.JSONObject; +import com.amarsoft.are.ARE; +import com.amarsoft.dict.als.manage.CodeManager; +import com.tenwa.flow.util.CalculateUtil; +import com.tenwa.httpclient.resources.BigDataPropertiesUtil; +import org.apache.commons.lang3.StringUtils; +import org.dom4j.*; + +import java.text.SimpleDateFormat; +import java.util.*; +import java.util.regex.Pattern; + +public class PbocXmlUtils { + /** + * ˵ʲѯIJװ + * @return + */ + public static String createPersonQueryParamStr(Map params, String subjectId) { + try { + JSONObject param = new JSONObject(); + JSONObject msgHead = new JSONObject(); + JSONObject msgBody = new JSONObject(); + msgHead.put("txCode", CodeManager.getItemName("pboc_query_strategy", "txCode")); + msgHead.put("reqSysCode", CodeManager.getItemName("pboc_query_strategy", "reqSysCode")); + msgHead.put("loginUserCode", CodeManager.getItemName("pboc_query_strategy", "loginUserCode")); + msgHead.put("loginPwd", CodeManager.getItemName("pboc_query_strategy", "loginPwd")); + msgHead.put("finDept", CodeManager.getItemName("pboc_query_strategy", "finDept")); + param.put("msgHead", msgHead); + + //ѯ 01-˹루ͨǰϵͳ룩 + msgBody.put("appType", "01"); + msgBody.put("rptUser", CodeManager.getItemName("pboc_query_strategy", "finDept"));//ʹ ¼Ųѯǰϵͳû˺ + msgBody.put("rptUserdept", CodeManager.getItemName("pboc_query_strategy", "finDept"));//дŻ + +// msgBody.put("reqId", applyId); + msgBody.put("custName", params.get("fullName")); + msgBody.put("custCertype", "10");//֤ 10-֤ + msgBody.put("custCertno", params.get("fullCertId")); + //ѯԭ 24- + String fullRelation = params.get("fullRelation"); + if("ͬ".equals(fullRelation)){ + msgBody.put("qryReason", CodeManager.getItemName("pboc_query_strategy", "qryReason_jointApplicant")); + }else if("".equals(fullRelation)){ + msgBody.put("qryReason", CodeManager.getItemName("pboc_query_strategy", "qryReason_guarantor")); + }else if("".equals(fullRelation)){ + msgBody.put("qryReason", CodeManager.getItemName("pboc_query_strategy", "qryReason_lessee")); + } + + msgBody.put("qryType", CodeManager.getItemName("pboc_query_strategy", "qryType"));//ѯ + msgBody.put("rptQryType", CodeManager.getItemName("pboc_query_strategy", "rptQryType"));//ñѯʽ1ȣ2ѯأ3ѯϵͳ + //"01-а + //02-ѯ + //03- + //04-" + msgBody.put("qryFormat", CodeManager.getItemName("pboc_query_strategy", "qryFormat"));//ѯ汾 + /** + * a-Ϣ + * b-ϢҪ + * e-Ϣϸ + */ +// msgBody.put("rptRstSegment", "a|b|e"); + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + Date date = new Date(); + String startTime = sdf.format(date); + Calendar cal = Calendar.getInstance(); + cal.setTime(date); + cal.add(Calendar.YEAR, 1); + String endTime = sdf.format(cal.getTime()); + msgBody.put("authStartDt", startTime); + msgBody.put("authEndDt", endTime); + + msgBody.put("authArchUrl", CodeManager.getItemName("pboc_query_strategy", "authArchUrl"));//ȨԴURL + msgBody.put("certSrcUrl", CodeManager.getItemName("pboc_query_strategy", "certSrcUrl"));//֤ԴURL + msgBody.put("certFileNameList", CodeManager.getItemName("pboc_query_strategy", "certFileNameList")); + msgBody.put("authArchFileNameList", CodeManager.getItemName("pboc_query_strategy", "authArchFileNameList")); + param.put("msgBody", msgBody); + ARE.getLog().info("xmlParamStr : " + param.toJSONString()); + String xmlParamStr = toXml(param); + ARE.getLog().info("xmlParamStr : " + xmlParamStr); + return xmlParamStr; + } catch (Exception e) { + e.printStackTrace(); + } + return null; + } + + // CDATA + private static Pattern pattern = Pattern.compile("[<>&\"',]"); + + + public static String toXml(JSONObject obj) { + return jsonStr2Xml(obj.toJSONString()); + } + + private static String escape(String string) { + return pattern.matcher(string).find() ? "" : string; + } + + /** + * updateXml + * @param xmlStr + */ + private static String updateXml(String xmlStr) { + xmlStr = xmlStr.trim(); + if (StringUtils.isBlank(xmlStr)) { + return xmlStr; + } + + // ˷Ƿַ + xmlStr = xmlStr.replaceAll("[\\x00-\\x08\\x0b-\\x0c\\x0e-\\x1f]", ""); + + StringBuilder xmlSb = new StringBuilder(xmlStr); + if (!xmlStr.startsWith(""); + } + + int idx = xmlSb.indexOf("?>") + 2; + xmlSb.insert(idx, "").append(""); + + return xmlSb.toString(); + } + + /** + * xml2Json + * @param xmlStr + * @return + * @throws DocumentException + */ + public static JSONObject toJson(String xmlStr) throws DocumentException { + xmlStr = updateXml(xmlStr); + Document doc = DocumentHelper.parseText(xmlStr); + JSONObject json = new JSONObject(); + dom4j2Json(doc.getRootElement(), json); + return json; + } + + /** + * toJsonString + * @param xmlStr + */ + public static String toJsonString(String xmlStr) throws DocumentException { + JSONObject jsonObject = toJson(xmlStr); + String json = JSON.toJSONString(jsonObject); + return json; + } + + /** + * toMap + * @param xmlStr + */ + public static Map toMap(String xmlStr) throws DocumentException { + String jsonStr = toJsonString(xmlStr); + Map xmlMap = JSON.parseObject(jsonStr, LinkedHashMap.class); + return xmlMap; + } + + /** + * xmlתjson + * @param element + * @param json + */ + private static void dom4j2Json(Element element, JSONObject json){ + // + for(Object o:element.attributes()){ + Attribute attr=(Attribute)o; + if(!isEmpty(attr.getValue())){ + json.put("@"+attr.getName(), attr.getValue()); + } + } + List chdEl=element.elements(); + if(chdEl.isEmpty()&&!isEmpty(element.getText())){ // ûԪ,ֻһֵ + json.put(element.getName(), element.getText()); + } + + for(Element e:chdEl){ // Ԫ + if(!e.elements().isEmpty()){ // ԪҲԪ + JSONObject chdjson=new JSONObject(); + dom4j2Json(e,chdjson); + Object o=json.get(e.getName()); + if(o!=null){ + JSONArray jsona=null; + if(o instanceof JSONObject){ // ԪѴ,תΪjsonArray + JSONObject jsono=(JSONObject)o; + json.remove(e.getName()); + jsona=new JSONArray(); + jsona.add(jsono); + jsona.add(chdjson); + } + if(o instanceof JSONArray){ + jsona=(JSONArray)o; + jsona.add(chdjson); + } + json.put(e.getName(), jsona); + }else{ + if(!chdjson.isEmpty()){ + json.put(e.getName(), chdjson); + } + } + }else{ // ԪûԪ + for(Object o:element.attributes()){ + Attribute attr=(Attribute)o; + if(!isEmpty(attr.getValue())){ + json.put("@"+attr.getName(), attr.getValue()); + } + } + if(!e.getText().isEmpty()){ + json.put(e.getName(), e.getText()); + } + } + } + } + + public static boolean isEmpty(String str) { + + if (str == null || str.trim().isEmpty() || "null".equals(str)) { + return true; + } + return false; + } + + /** + * jsonStr2Xml + * @param json + * @return java.lang.String + */ + public static String jsonStr2Xml(String json){ + try { + StringBuffer buffer = new StringBuffer(); + buffer.append(""); + JSONObject jObj = JSON.parseObject(json); + json2Xmlstr(jObj,buffer); + return buffer.toString(); + } + catch (Exception e) { + e.printStackTrace(); + return ""; + } + } + + /** + * Json to xmlstr string + * + * @param jObj the j obj + * @param buffer the buffer + * @return the string + */ + public static String json2Xmlstr(JSONObject jObj,StringBuffer buffer){ + Set> se = jObj.entrySet(); + for(Iterator> it = se.iterator(); it.hasNext(); ) + { + Map.Entry en = it.next(); + if(en.getValue().getClass().getName().equals("com.alibaba.fastjson.JSONObject")){ + buffer.append("<"+en.getKey()+">"); + JSONObject jo = jObj.getJSONObject(en.getKey()); + json2Xmlstr(jo,buffer); + buffer.append(""); + }else if(en.getValue().getClass().getName().equals("com.alibaba.fastjson.JSONArray")){ + JSONArray jarray = jObj.getJSONArray(en.getKey()); + for (int i = 0; i < jarray.size(); i++) { + buffer.append("<"+en.getKey()+">"); + JSONObject jsonobject = jarray.getJSONObject(i); + json2Xmlstr(jsonobject,buffer); + buffer.append(""); + } + }else if(en.getValue().getClass().getName().equals("java.lang.String")){ + buffer.append("<"+en.getKey()+">" + escape((String) en.getValue())); + buffer.append(""); + } + } + return buffer.toString(); + } + +} diff --git a/src_tenwa/com/tenwa/lease/flow/project/businessapply/CustomerInfoManage.java b/src_tenwa/com/tenwa/lease/flow/project/businessapply/CustomerInfoManage.java index e4762ec3e..544f67f00 100644 --- a/src_tenwa/com/tenwa/lease/flow/project/businessapply/CustomerInfoManage.java +++ b/src_tenwa/com/tenwa/lease/flow/project/businessapply/CustomerInfoManage.java @@ -1,26 +1,12 @@ package com.tenwa.lease.flow.project.businessapply; -import jbo.app.tenwa.customer.CUSTOMER_ACCOUNT_TEMP; -import jbo.app.tenwa.customer.CUSTOMER_CERT_TEMP; -import jbo.app.tenwa.customer.CUSTOMER_FAMILY; -import jbo.app.tenwa.customer.CUSTOMER_FAMILY_TEMP; -import jbo.app.tenwa.customer.CUSTOMER_PERSON_TEMP; -import jbo.app.tenwa.customer.DISTRIBUTOR_INFO; -import jbo.app.tenwa.customer.DISTRIBUTOR_INFO_TEMP; -import jbo.app.tenwa.customer.DISTRIBUTOR_SUBSIDIARY; +import com.amarsoft.are.jbo.*; +import com.amarsoft.are.util.StringFunction; +import jbo.app.tenwa.customer.*; import jbo.com.tenwa.entity.comm.flow.FLOW_BUSSINESS_OBJECT; import jbo.com.tenwa.lease.comm.LB_PROJECT_INFO; import jbo.com.tenwa.lease.comm.LB_PROJECT_INFO_TEMP; -import org.bouncycastle.crypto.tls.AlertDescription; - -import com.amarsoft.are.jbo.BizObject; -import com.amarsoft.are.jbo.BizObjectManager; -import com.amarsoft.are.jbo.JBOException; -import com.amarsoft.are.jbo.JBOFactory; -import com.amarsoft.are.jbo.JBOTransaction; -import com.amarsoft.are.util.StringFunction; - public class CustomerInfoManage { private String F_I_TYPE; private String DISTRIBUTOR_STATUS; @@ -54,7 +40,267 @@ public class CustomerInfoManage { private String zcProjectNumber; private String zcContractNumber; private String channel; - + // Ʒֶ̨ + + /** + * -'-ͬ' + */ + private String nation; + + /** + * -'-ͬѧ' + */ + private String educationLevel; + /** + * -'-'-ͬ˵λַ'' + */ + private String workAddress; + + /** + * -'-ͬ˻ַ' + */ + private String idAddress; + + /** + * -'-ͬҵ' + */ + private String enterpriseNature; + + /** + * -'-ͬҵ' + */ + private String industryType; + + /** + * -'-ְͬҵ' + */ + private String careerType; + + /** + * -'-֧ͬ' + */ + private String monthlyExpenses; + + /** + * -'-ͬ˵λַ' + */ + private String workAddressCode; + + /** + * -'-ͬ˵λַid' + */ + private String workAddressId; + + /** + * -'-ͬ˾סַ' + */ + private String liveAddressCode; + + /** + * -'-ͬ˾סַid' + */ + private String liveAddressId; + + /** + * -'-ͬ˻ַ' + */ + private String idAddressCode; + + /** + * -'-ͬ˻״' + */ + private String marryType; + + /** + * -'-ͬ˾ס״' + */ + private String residentialStatus; + + /** + * -'-ͬ˻ַid' + */ + private String idAddressId; + + /** + * -'-Ů' + */ + private String childrensNumber; + + /** + * -'-ͬ˳' + */ + private String birthday; + + /** + * -'-֤Чڿʼʱ' + */ + private String startIdexpiry; + + /** + * -'-֤ͬЧ' + */ + private String idexpiryType; + + public String getNation() { + return nation; + } + + public void setNation(String nation) { + this.nation = nation; + } + + public String getEducationLevel() { + return educationLevel; + } + + public void setEducationLevel(String educationLevel) { + this.educationLevel = educationLevel; + } + + public String getWorkAddress() { + return workAddress; + } + + public void setWorkAddress(String workAddress) { + this.workAddress = workAddress; + } + + public String getIdAddress() { + return idAddress; + } + + public void setIdAddress(String idAddress) { + this.idAddress = idAddress; + } + + public String getEnterpriseNature() { + return enterpriseNature; + } + + public void setEnterpriseNature(String enterpriseNature) { + this.enterpriseNature = enterpriseNature; + } + + public String getIndustryType() { + return industryType; + } + + public void setIndustryType(String industryType) { + this.industryType = industryType; + } + + public String getCareerType() { + return careerType; + } + + public void setCareerType(String careerType) { + this.careerType = careerType; + } + + public String getMonthlyExpenses() { + return monthlyExpenses; + } + + public void setMonthlyExpenses(String monthlyExpenses) { + this.monthlyExpenses = monthlyExpenses; + } + + public String getWorkAddressCode() { + return workAddressCode; + } + + public void setWorkAddressCode(String workAddressCode) { + this.workAddressCode = workAddressCode; + } + + public String getWorkAddressId() { + return workAddressId; + } + + public void setWorkAddressId(String workAddressId) { + this.workAddressId = workAddressId; + } + + public String getLiveAddressCode() { + return liveAddressCode; + } + + public void setLiveAddressCode(String liveAddressCode) { + this.liveAddressCode = liveAddressCode; + } + + public String getLiveAddressId() { + return liveAddressId; + } + + public void setLiveAddressId(String liveAddressId) { + this.liveAddressId = liveAddressId; + } + + public String getIdAddressCode() { + return idAddressCode; + } + + public void setIdAddressCode(String idAddressCode) { + this.idAddressCode = idAddressCode; + } + + public String getMarryType() { + return marryType; + } + + public void setMarryType(String marryType) { + this.marryType = marryType; + } + + public String getResidentialStatus() { + return residentialStatus; + } + + public void setResidentialStatus(String residentialStatus) { + this.residentialStatus = residentialStatus; + } + + public String getIdAddressId() { + return idAddressId; + } + + public void setIdAddressId(String idAddressId) { + this.idAddressId = idAddressId; + } + + public String getChildrensNumber() { + return childrensNumber; + } + + public void setChildrensNumber(String childrensNumber) { + this.childrensNumber = childrensNumber; + } + + public String getBirthday() { + return birthday; + } + + public void setBirthday(String birthday) { + this.birthday = birthday; + } + + public String getStartIdexpiry() { + return startIdexpiry; + } + + public void setStartIdexpiry(String startIdexpiry) { + this.startIdexpiry = startIdexpiry; + } + + public String getIdexpiryType() { + return idexpiryType; + } + + public void setIdexpiryType(String idexpiryType) { + this.idexpiryType = idexpiryType; + } + public String getDistributorCode() { return distributorCode; } @@ -348,6 +594,7 @@ public class CustomerInfoManage { bo.setAttributeValue("smincome", smincome); bo.setAttributeValue("shukou", shukou); bo.setAttributeValue("Spouse_", "Y"); + bo.setAttributeValue("ASSURE_RELATION", "ż"); bo.setAttributeValue("PROJECT_ID", projectId); bo.setAttributeValue("workunit", workunit); bo.setAttributeValue("sex", sex); @@ -368,10 +615,35 @@ public class CustomerInfoManage { bo.setAttributeValue("smincome", smincome); bo.setAttributeValue("shukou", shukou); bo.setAttributeValue("Spouse_", "Y"); + bo.setAttributeValue("ASSURE_RELATION", "ż"); bo.setAttributeValue("PROJECT_ID", projectId); bo.setAttributeValue("workunit", workunit); bo.setAttributeValue("sex", sex); } + if("Y".equals(partner)){ + System.out.println("ʼ湲ͬżϢ---------666---------->"); + bo.setAttributeValue("idexpiry",idexpiry); + bo.setAttributeValue("nation",nation); + bo.setAttributeValue("education_level",educationLevel); + bo.setAttributeValue("work_address",workAddress); + bo.setAttributeValue("id_address",idAddress); + bo.setAttributeValue("enterprise_nature",enterpriseNature); + bo.setAttributeValue("industry_type",industryType); + bo.setAttributeValue("career_type",careerType); + bo.setAttributeValue("monthly_expenses",monthlyExpenses); + bo.setAttributeValue("work_address_code",workAddressCode); + bo.setAttributeValue("work_address_id",workAddressId); + bo.setAttributeValue("live_address_code",liveAddressCode); + bo.setAttributeValue("live_address_id",liveAddressId); + bo.setAttributeValue("id_address_code",idAddressCode); + bo.setAttributeValue("marry_type",marryType); + bo.setAttributeValue("residential_status",residentialStatus); + bo.setAttributeValue("id_address_id",idAddressId); + bo.setAttributeValue("childrens_number",childrensNumber); + bo.setAttributeValue("birthday",birthday); + bo.setAttributeValue("start_idexpiry",startIdexpiry); + bo.setAttributeValue("idexpiry_type",idexpiryType); + } bom.saveObject(bo); }catch(Exception e){ e.printStackTrace(); diff --git a/src_tenwa/com/tenwa/message/JobSendMessage.java b/src_tenwa/com/tenwa/message/JobSendMessage.java index f578939e2..6e5ff228f 100644 --- a/src_tenwa/com/tenwa/message/JobSendMessage.java +++ b/src_tenwa/com/tenwa/message/JobSendMessage.java @@ -8,7 +8,6 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.quartz.Job; import org.quartz.JobExecutionContext; -import org.quartz.JobExecutionException; import java.text.SimpleDateFormat; @@ -18,7 +17,7 @@ public class JobSendMessage implements Job{ private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); @Override - public void execute(JobExecutionContext context) throws JobExecutionException { + public void execute(JobExecutionContext context){ JBOTransaction tx = null; String smsnoticeid = null; try { diff --git a/src_tenwa/quartz/AutoExecuteMission.java b/src_tenwa/quartz/AutoExecuteMission.java index b57fb1a4f..86200ca20 100644 --- a/src_tenwa/quartz/AutoExecuteMission.java +++ b/src_tenwa/quartz/AutoExecuteMission.java @@ -469,7 +469,6 @@ public void contextDestroyed(ServletContextEvent arg0) { } catch (SchedulerException e) { e.printStackTrace(); } - } @Override
ûûűʱ
<%=person_type%><%=person_name%>ű<%=update_time%>