diff --git a/WebContent/Accounting/LoanSimulation_onhire/LoanBasicInfoBusiness.jsp b/WebContent/Accounting/LoanSimulation_onhire/LoanBasicInfoBusiness.jsp new file mode 100644 index 000000000..5db307d87 --- /dev/null +++ b/WebContent/Accounting/LoanSimulation_onhire/LoanBasicInfoBusiness.jsp @@ -0,0 +1,1274 @@ +<%@page import="jbo.prd.BUSINESS_TYPE"%> +<%@page import="com.tenwa.reckon.util.TbBeanTools"%> +<%@page import="com.tenwa.reckon.bean.TabCalBean"%> +<%@page import="com.amarsoft.awe.control.model.Parameter"%> +<%@page import="com.amarsoft.app.base.util.DateHelper"%> +<%@page import="com.tenwa.util.SerialNumberUtil"%> +<%@page import="com.tenwa.reckon.product.ProductCondition"%> +<%@page import="com.amarsoft.app.util.ProductParamUtil"%> +<%@ page import="com.amarsoft.app.lc.workflow.action.GetFlowAction" %> +<%@ page import="java.util.Vector" %> +<%@ page import="com.amarsoft.awe.dw.ui.validator.ValidateRule" %> +<%@ page import="com.tenwa.reckon.product.ASObjectWindowCalc" %> +<%@ page contentType="text/html; charset=GBK"%> +<%@ include file="/Frame/resources/include/include_begin_info.jspf"%> +<% + /*获取参数*/ + String flowunid = CurPage.getParameter("FlowUnid"); + String plannumber=CurPage.getParameter("plannumber"); + String productId=CurPage.getParameter("ProductId"); + String ishistory=CurPage.getParameter("IsHistory"); + String nodeNo=CurPage.getParameter("NodeNo"); + String RightType= CurPage.getParameter("RightType"); + String calType = CurPage.getParameter("calType"); + //判断是否为汽车业务 + boolean isCarProduct = "004".equals(productId) ? false : true; + /*获取参数*/ + /*根据参数判断 是否去数据库查询*/ + BizObject flow=GetFlowAction.getFlowBussinessObject(flowunid); + if(productId==null){ + productId=flow.getAttribute("productId").getString(); + } + if(calType == null){ + calType = "proj_process"; + } + TabCalBean tcb=TbBeanTools.getTabInfo(calType); + String planCName=tcb.getPlanCName(); + //方案编号 + if(plannumber==null){ + if("pay_process".equals(calType)||"onHire_process".equals(calType)){ + BizObject condtion=JBOFactory.createBizObjectQuery("jbo.app.tenwa.calc.LC_CALC_CONDITION_TEMP","flowunid=:flowunid and PAYMENT_NUMBER is not null and length(PAYMENT_NUMBER)>0 ").setParameter("flowunid", flowunid).getSingleResult(false); + if(condtion!=null){ + plannumber=condtion.getAttribute(planCName).getString(); + } + }else{ + String planType=ProductParamUtil.getProductParameterValue(productId, "PRD0314", "planinformation"); + if("SinglePlan".equals(planType)){ + BizObject condtion=JBOFactory.createBizObjectQuery("jbo.app.tenwa.calc.LC_CALC_CONDITION_TEMP","flowunid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false); + if(condtion!=null){ + plannumber=condtion.getAttribute(planCName).getString(); + } + } + } + } + //新增数据 自动生成方案编号 + if(plannumber==null){ + String sSerialType=""; + JBOTransaction tx=JBOFactory.createJBOTransaction(); + if("proj_process".equals(calType)){ + BizObject proj=JBOFactory.createBizObjectQuery("jbo.com.tenwa.lease.comm.LB_PROJECT_INFO_TEMP","flowunid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false); + sSerialType=proj.getAttribute("PROJECT_NO").getString(); + }else{ + BizObject contract=JBOFactory.createBizObjectQuery("jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO_TEMP","flowunid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false); + sSerialType=contract.getAttribute("CONTRACT_NO").getString(); + } + plannumber=SerialNumberUtil.getPlannumber(sSerialType,calType,tx); + tx.commit(); + } + /*根据参数判断 是否去数据库查询*/ + + String sTempletNo = "TLoanSimulationBasicInfo_onhire";//--模板号-- + ASObjectModel doTemp = new ASObjectModel(sTempletNo); + + + + /*设置字段事件*/ + doTemp.setHtmlEvent("SETTLE_METHOD", "onchange", "changeSettleMethod");//租金计算方式 + doTemp.setHtmlEvent("RENT_OR_RATE", "onchange", "rentOrRateChange");//租金推算方法 + doTemp.setHtmlEvent("INCOME_NUMBER_YEAR", "onchange", "changeIncomeNumber");//还款间隔 + doTemp.setHtmlEvent("INCOME_INTERVAL_MONTH", "onchange", "changeIntervalMonth");//还款间隔(月) + doTemp.setHtmlEvent("INCOME_NUMBER", "onchange", "changeNumber");//还款次数 + doTemp.setHtmlEvent("PERIOD_TYPE", "onchange", "changePeriod");//期初/期末 + doTemp.setHtmlEvent("GRACE", "onchange", "changeGrace");//宽限期RATTermID + doTemp.setHtmlEvent("RATE_FLOAT_TYPE", "onchange", "changeRateFloat");//利率计算方式 + doTemp.setHtmlEvent("BASE_RATE", "onchange", "changeBaseRate");//基准利率 + doTemp.setHtmlEvent("RATE_FLOAT_AMT", "onchange", "changeRateFloatAmt");//利率调整值 + doTemp.setHtmlEvent("CAUTION_MONEY", "onchange", "cautionMoney");//保证金 + doTemp.setHtmlEvent("CAUTION_DEDUCTION_MONEY", "onchange", "cautionDeductionMoney");//保证金抵扣金额 + doTemp.setHtmlEvent("LEASE_AMT_DATE", "onchange", "changeLeaseAmtDate");//投放日 + doTemp.setHtmlEvent("START_DATE", "onchange", "changeStartDate");//起租日 + doTemp.setHtmlEvent("FIRST_PLAN_DATE", "onchange", "changeFistPlanDate");//第一期计划日期 + doTemp.setHtmlEvent("CORPUS_RATIO", "onchange", "changeCorpusRatio");//期限内本金比例 + doTemp.setHtmlEvent("RATE_TYPE", "onchange", "changeRateTypeNew");//利率类型 + /*设置字段事件*/ + + /*设置模板属性*/ + Vector vali=new Vector(); + //费用规则 + ProductCondition pc=new ProductCondition(); + pc.getProductFundRules(doTemp, productId); + String calcRules=pc.getProductRulesBusiness(doTemp, productId,vali); + + if("quoted_price".equals(calType)){//客户报价 流程号存的是客户主键 + doTemp.setDefaultValue("cust_id", flowunid); + } + doTemp.setColumnAttribute(planCName,"isipdate","1"); + doTemp.setJboClass(tcb.getCondition_tb()); + doTemp.setDefaultValue(planCName, plannumber); + doTemp.setDefaultValue("flowunid", flowunid); + doTemp.appendJboWhere(" and "+planCName+"='"+plannumber+"'"); + if(null!=ishistory&&ishistory.equals("true")){ + doTemp.setDataQueryClass("com.tenwa.lease.flow.flowarchive.calcarchive.CalcCondtionInfoArachiveShow");//如果是历史则新显示历史数据 + } + /*设置模板属性*/ + + /*设置页面属性*/ + CurPage.getCurComp().setAttribute("RightType", null); + Parameter p=new Parameter("plannumber",plannumber); + Vector v=CurPage.parameterList; + v.add(p); + /*设置页面属性*/ + + + ASObjectWindowCalc dwTemp = new ASObjectWindowCalc(CurPage, doTemp,request); + + + dwTemp.Style = "2";//freeform + if((null!=RightType&&RightType.equals("ReadOnly"))||(null!=ishistory&&ishistory.equals("true"))){ + dwTemp.ReadOnly = "-2";//只读模式 + isShowButton=false; + }else{ + isShowButton=true; + } + dwTemp.setVali(vali); + dwTemp.setAttr("inputWidth","120"); + dwTemp.setAttr("spanWidth","107"); + dwTemp.setAttr("showRatio", true); + dwTemp.genHTMLObjectWindow(flowunid); + RightType="ReadOnly"; + CurPage.getCurComp().setAttribute("RightType", RightType); + + String compClientID = request.getParameter("CompClientID"); + dwTemp.replaceColumn("condition_plan", "", CurPage.getObjectWindowOutput()); + dwTemp.replaceColumn("even_subsection", "", CurPage.getObjectWindowOutput()); + dwTemp.replaceColumn("knowing_config", "", CurPage.getObjectWindowOutput()); + String businessDate = DateHelper.getBusinessDate(); + String sButtons[][] = { + //{"true","All","Button","重置","重置","reloadSelf()","","","",""}, + {"true","","Button","租金测算","租金测算","saveRecord()","","","","btn_icon_save"}, + // {((isCarProduct) && ("proj_process".equals(calType)||"cont_process".equals(calType)))?"true":"false","","Button","引入客户报价","引入客户报价","importCustomerQuot()","","","","btn_icon_edit"} + }; +%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%> + +<%@ include file="/Frame/resources/include/include_end.jspf"%> diff --git a/WebContent/Tenwa/Lease/Flow/Comm/LBRisk/LBRistList.jsp b/WebContent/Tenwa/Lease/Flow/Comm/LBRisk/LBRistList.jsp index 631f08786..d8447e80b 100644 --- a/WebContent/Tenwa/Lease/Flow/Comm/LBRisk/LBRistList.jsp +++ b/WebContent/Tenwa/Lease/Flow/Comm/LBRisk/LBRistList.jsp @@ -159,7 +159,7 @@ function upload(){ // deleteFile(); - var sparam="FlowUnid=<%=flowunid%>"+",ProjId=<%=projid%>"+",DocType=001,OneClassify=001003,DocName=风控报告"; + var sparam="FlowUnid=<%=flowunid%>"+",ProjId=<%=projid%>"+",DocType=001,OneClassify=001003,DocName=风控及法务报告"; var library_id=RunJavaMethodTrans("com.tenwa.officetempalte.action.CreateContractOfficeAction","NewCreditLibraryId",sparam); var param="Library_id="+library_id+"&FlowUnid=<%=flowunid%>"; diff --git a/calc/com/tenwa/reckon/executor/FundFundPlanExecutor.java b/calc/com/tenwa/reckon/executor/FundFundPlanExecutor.java index ad4370d92..393bd7865 100644 --- a/calc/com/tenwa/reckon/executor/FundFundPlanExecutor.java +++ b/calc/com/tenwa/reckon/executor/FundFundPlanExecutor.java @@ -212,8 +212,11 @@ public class FundFundPlanExecutor { BizObjectManager bomLFP = JBOFactory.getBizObjectManager(LC_FUND_PLAN.CLASS_NAME,tx); BizObject boLFP = bomLFP.createQuery("select id from O where contract_id='"+tcb.getCb().getContractId()+"' and fee_type='"+item.getItemNo()+"'") .getSingleResult(true); - ffcp.setId(boLFP.getAttribute("id").getString()); - bomLFP.deleteObject(boLFP); + if(boLFP!=null){ + ffcp.setId(boLFP.getAttribute("id").getString()); + bomLFP.deleteObject(boLFP); + } + } ffcp.setFeeType(item.getItemNo());//费用类型 ffcp.setPlanList("1"); diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/CreateVoucherActualPaymentCarTradition.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/CreateVoucherActualPaymentCarTradition.java new file mode 100644 index 000000000..ebf50b945 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/CreateVoucherActualPaymentCarTradition.java @@ -0,0 +1,168 @@ +package com.tenwa.voucher.CreateVoucherProcess; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import jbo.voucher.LV_VOUCHER_CONFIG; + +import com.amarsoft.app.util.ProductParamUtil; +import com.amarsoft.are.jbo.BizObject; +import com.amarsoft.awe.util.Transaction; +import com.amarsoft.dict.als.cache.CacheLoaderFactory; +import com.tenwa.comm.util.jboutil.DataOperatorUtil; +import com.tenwa.flow.baseBussion.BaseBussiness; +import com.tenwa.voucher.serviceImp.CreateVoucherServiceImpl; +/** + * 汽车传统实际付款后生成凭证 + * @author xiezhiwen + */ +public class CreateVoucherActualPaymentCarTradition extends BaseBussiness{ + + public String CreateVoucher(String FlowUnid,String VOUCHERNO) throws Exception { + // 创建事物 + Transaction Sqlca =null; + Sqlca = Transaction.createTransaction(CacheLoaderFactory.getDataSource()); + Map map=new HashMap(); + Map param=new HashMap(); + // 定义全局对象 + String EQUIP_AMT=null; // 设备款 + String EQUIP_AMT_NOTAX=null; // 设备款(不含税) + String EQUIP_AMT_TAX=null; // 设备款(税金) + String FIRST_PAYMENT=null; // 首付款 + String FIRST_PAYMENT_NOTAX=null; // 首付款(不含税) + String FIRST_PAYMENT_TAX=null; // 首付款(税金) + String INSURANCE_PREMIUM_ADD_OTHER=null;// 保险费+其他金额 + String INSURANCE_PREMIUM_ADD_OTHER_NOTAX=null;// 保险费+其他金额(不含税) + String INSURANCE_PREMIUM_ADD_OTHER_TAX=null; // 保险费+其他金额(税金) + String EQUIP_INSURACE_PREMIUM_OTHER=null;// 设备款+保险费+其他 + String OTHERSMONEY=null; // 车款+保险+其他-首付款 + String ACCOUNT_DATE=null; // 会计日期 + String FACT_DATE=null; // 实际付款日期 + String CONTRACT_ID=null; // 合同id + String CONTRACT_NUMBER=null; // 合同编号 + String PROJECT_NAME=null; // 项目名称 + String LEAS_FORM=null; // 项目类别 + String DISTRIBUTOR_ID=null; // 经销商编号 + String DISTRIBUTOR_NAME=null; // 经销商名称 + String CUSTOMERID=null; // 客户编号 + String CUSTOMERNAME=null; // 客户名称 + String CUSTOMERTYPE=null; // 客户类别 + String BUSINESSTYPE=null; // 业务类型 + String ACC_NUMBER=null; // 银行账号 + String PRODUCT_ID=null; // 产品编号 + String sql=""; + + sql="SELECT LCCT.EQUIP_AMT,ROUND(LCCT.EQUIP_AMT / getTax (LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2) AS EQUIP_AMT_NOTAX,(LCCT.EQUIP_AMT - ROUND(LCCT.EQUIP_AMT / getTax (LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2)) AS EQUIP_AMT_TAX,LCCT.FIRST_PAYMENT,ROUND(LCCT.FIRST_PAYMENT/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2) AS FIRST_PAYMENT_NOTAX,(LCCT.FIRST_PAYMENT - ROUND(LCCT.FIRST_PAYMENT/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2)) AS FIRST_PAYMENT_TAX,(LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY) AS INSURANCE_PREMIUM_ADD_OTHER,ROUND((LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY) / getTax (LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2) AS INSURANCE_PREMIUM_ADD_OTHER_NOTAX,((LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY) - ROUND((LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY) / getTax (LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2)) AS INSURANCE_PREMIUM_ADD_OTHER_TAX,(LCCT.EQUIP_AMT+LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY) AS EQUIP_INSURACE_PREMIUM_OTHER,(LCCT.EQUIP_AMT+LCCT.INSURANCE_PREMIUM+LCCT.OTHER_MONEY-LCCT.FIRST_PAYMENT) AS OTHERSMONEY,DATE_FORMAT(SYSDATE(), '%Y/%m/%d') AS ACCOUNT_DATE,DATE_FORMAT(SYSDATE(), '%Y/%m/%d') AS FACT_DATE,LCCT.CONTRACT_ID,LCI.CONTRACT_NUMBER,LCI.PROJECT_NAME,LCI.LEAS_FORM,DI.DISTRIBUTOR_CODING AS DISTRIBUTOR_ID,DI.DISTRIBUTOR_NAME,CIF.CUSTOMER_NUM AS CUSTOMERID,CIF.CUSTOMERNAME,CIF.CUSTOMERTYPE,LPI.BUSINESSTYPE,lfit.ACC_NUMBER,LPDI.PRODUCT_ID FROM LC_CALC_CONDITION LCCT INNER JOIN (SELECT contract_id,FLOWUNID,MIN(ACC_NUMBER) ACC_NUMBER FROM lc_fund_income_temp WHERE fee_type = 'feetype10' GROUP BY contract_id,FLOWUNID) lfit ON lfit.contract_id = lcct.contract_id LEFT JOIN LB_CONTRACT_INFO LCI ON LCI.ID = lfit.CONTRACT_ID LEFT JOIN DISTRIBUTOR_INFO DI ON DI.DISTRIBUTOR_NO = LCI.DISTRIBUTOR_ID LEFT JOIN lb_union_lessee lul ON lul.contract_id = lci.id LEFT JOIN customer_info cif ON cif.customerid = lul.customer_id LEFT JOIN LB_PROJECT_INFO LPI ON LPI.ID = LUL.PROJECT_ID LEFT JOIN LB_PRODUCT_INFO LPDI ON LPDI.PRODUCT_ID = LPI.PRODUCT_ID WHERE LCI.BUSINESSTYPE = '3' AND lfit.FLOWUNID = :FLOWUNID "; + + param.clear(); + map.put("FLOWUNID", FlowUnid); + + // 查询sql, 将结果集封装到map中 + List> dataList=DataOperatorUtil.getDataBySql(Sqlca, sql, map); + + // 创建生成凭证的类对象 + CreateVoucherServiceImpl vs=new CreateVoucherServiceImpl(); + + // 设置常用参数 + String VOUCHER_TYPE="1"; // 凭证分类 金蝶 + String userid ="admin"; + + for (int i=0;i map=new HashMap(); + Map param=new HashMap(); + // 定义全局对象 + String EQUIP_AMT=null; // 设备款 + String EQUIP_AMT_NOTAX=null; // 设备款(不含税) + String EQUIP_AMT_TAX=null; // 设备款(税金) + String FIRST_PAYMENT=null; // 首付款 + String HANDLING_CHARGE_MONEY=null; // 手续费 + String HANDLING_CHARGE_MONEY_NOTAX=null;// 不含税手续费 + String HANDLING_CHARGE_MONEY_TAX=null; // 手续费税金 + String CAUTION_MONEY=null; // 保证金 + String OTHER_MONEY=null; // 其它金额 + String OTHER_MONEY_NOTAX=null; // 其它金额(不含税) + String OTHER_MONEY_TAX=null; // 其它金额(税金) + String ACCOUNT_DATE=null; // 会计日期 + String FACT_DATE=null; // 实际付款日期 + String CONTRACT_ID=null; // 合同id + String CONTRACT_NUMBER=null; // 合同编号 + String PROJECT_NAME=null; // 项目名称 + String LEAS_FORM=null; // 项目类别 + String DISTRIBUTOR_ID=null; // 经销商编号 + String DISTRIBUTOR_NAME=null; // 经销商名称 + String CUSTOMERID=null; // 客户编号 + String CUSTOMERNAME=null; // 客户名称 + String CUSTOMERTYPE=null; // 客户类别 + String BUSINESSTYPE=null; // 业务类型 + String ACC_NUMBER=null; // 银行账号 + String PRODUCT_ID=null; // 产品编号 + String sql=""; + + sql="SELECT LCCT.EQUIP_AMT,ROUND(LCCT.EQUIP_AMT/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2) AS EQUIP_AMT_NOTAX,(LCCT.EQUIP_AMT-ROUND(LCCT.EQUIP_AMT/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2)) AS EQUIP_AMT_TAX,LCCT.FIRST_PAYMENT,LCCT.HANDLING_CHARGE_MONEY,ROUND(LCCT.HANDLING_CHARGE_MONEY/ getTax(LCI.LEAS_FORM,'手续费',LCI.INPUTTIME),2) AS HANDLING_CHARGE_MONEY_NOTAX,(LCCT.HANDLING_CHARGE_MONEY - ROUND(LCCT.HANDLING_CHARGE_MONEY/ getTax(LCI.LEAS_FORM,'手续费',LCI.INPUTTIME),2)) AS HANDLING_CHARGE_MONEY_TAX,IFNULL(LCCT.CAUTION_MONEY, 0) AS CAUTION_MONEY,LCCT.OTHER_MONEY,ROUND(LCCT.OTHER_MONEY/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2) AS OTHER_MONEY_NOTAX,(LCCT.OTHER_MONEY - ROUND(LCCT.OTHER_MONEY/getTax(LCI.LEAS_FORM,'本金',LCI.INPUTTIME),2)) AS OTHER_MONEY_TAX,DATE_FORMAT(SYSDATE(), '%Y/%m/%d') AS ACCOUNT_DATE,DATE_FORMAT(SYSDATE(), '%Y/%m/%d') AS FACT_DATE,LCCT.CONTRACT_ID,LCI.CONTRACT_NUMBER,LCI.PROJECT_NAME,LCI.LEAS_FORM,DI.DISTRIBUTOR_CODING AS DISTRIBUTOR_ID,DI.DISTRIBUTOR_NAME,CIF.CUSTOMER_NUM AS CUSTOMERID,CIF.CUSTOMERNAME,CIF.CUSTOMERTYPE,LPI.BUSINESSTYPE,lfit.ACC_NUMBER,LPDI.PRODUCT_ID FROM LC_CALC_CONDITION LCCT INNER JOIN (SELECT contract_id,FLOWUNID,MIN(ACC_NUMBER) ACC_NUMBER FROM lc_fund_income_temp WHERE fee_type = 'feetype10' GROUP BY contract_id,FLOWUNID) lfit ON lfit.contract_id = lcct.contract_id LEFT JOIN LB_CONTRACT_INFO LCI ON LCI.ID = lfit.CONTRACT_ID LEFT JOIN DISTRIBUTOR_INFO DI ON DI.DISTRIBUTOR_NO = LCI.DISTRIBUTOR_ID LEFT JOIN lb_union_lessee lul ON lul.contract_id = lci.id LEFT JOIN customer_info cif ON cif.customerid = lul.customer_id LEFT JOIN LB_PROJECT_INFO LPI ON LPI.ID = LUL.PROJECT_ID LEFT JOIN LB_PRODUCT_INFO LPDI ON LPDI.PRODUCT_ID=LPI.PRODUCT_ID WHERE LCI.BUSINESSTYPE='2' AND lfit.FLOWUNID = :FLOWUNID "; + + param.clear(); + map.put("FLOWUNID", FlowUnid); + + // 查询sql, 将结果集封装到map中 + List> dataList=DataOperatorUtil.getDataBySql(Sqlca, sql, map); + + // 创建生成凭证的类对象 + CreateVoucherServiceImpl vs=new CreateVoucherServiceImpl(); + + // 设置常用参数 + String VOUCHER_TYPE="1"; // 凭证分类 金蝶 + String userid ="admin"; + + for (int i=0;i getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取保证金 + String CAUTION_MONEY=param.get("CAUTION_MONEY")==null?"0.00":param.get("CAUTION_MONEY"); + returnValue.put("MONEY",CAUTION_MONEY); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquip.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquip.java new file mode 100644 index 000000000..b167ec291 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquip.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取设备款 + * @author xiezhiwen + */ +public class ContractGetMoneyToEquip implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_AMT=param.get("EQUIP_AMT")==null?"0.00":param.get("EQUIP_AMT"); + returnValue.put("MONEY",EQUIP_AMT); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOther.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOther.java new file mode 100644 index 000000000..c01dd804a --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOther.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 设备+保险+其他 + * @author xiezhiwen + */ +public class ContractGetMoneyToEquipAddInsuranceAddOther implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_INSURACE_PREMIUM_OTHER=param.get("EQUIP_INSURACE_PREMIUM_OTHER")==null?"0.00":param.get("EQUIP_INSURACE_PREMIUM_OTHER"); + returnValue.put("MONEY",EQUIP_INSURACE_PREMIUM_OTHER); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOtherSubFirst.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOtherSubFirst.java new file mode 100644 index 000000000..7ac999967 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddInsuranceAddOtherSubFirst.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 设备+保险+其他-首付款 + * @author xiezhiwen + */ +public class ContractGetMoneyToEquipAddInsuranceAddOtherSubFirst implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String OTHERSMONEY=param.get("OTHERSMONEY")==null?"0.00":param.get("OTHERSMONEY"); + returnValue.put("MONEY",OTHERSMONEY); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddOthers.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddOthers.java new file mode 100644 index 000000000..dbb16374e --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipAddOthers.java @@ -0,0 +1,28 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.math.BigDecimal; +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 设备款+其他金额 + * @author xiezhiwen + */ +public class ContractGetMoneyToEquipAddOthers implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_AMT=param.get("EQUIP_AMT")==null?"0.00":param.get("EQUIP_AMT"); + // 获取其它金额 + String OTHER_MONEY=param.get("OTHER_MONEY")==null?"0.00":param.get("OTHER_MONEY"); + + // 其他款项+设备款 + BigDecimal FactMoney=new BigDecimal(EQUIP_AMT).add(new BigDecimal(OTHER_MONEY)); + returnValue.put("MONEY",FactMoney.toString()); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipNoTax.java new file mode 100644 index 000000000..d743e1d8b --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipNoTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取设备款(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToEquipNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_AMT_NOTAX=param.get("EQUIP_AMT_NOTAX")==null?"0.00":param.get("EQUIP_AMT_NOTAX"); + returnValue.put("MONEY",EQUIP_AMT_NOTAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipTax.java new file mode 100644 index 000000000..20aa09da3 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToEquipTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取设备款(税金) + * @author xiezhiwen + */ +public class ContractGetMoneyToEquipTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_AMT_TAX=param.get("EQUIP_AMT_TAX")==null?"0.00":param.get("EQUIP_AMT_TAX"); + returnValue.put("MONEY",EQUIP_AMT_TAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPayment.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPayment.java new file mode 100644 index 000000000..de432c84e --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPayment.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取首付款 + * @author xiezhiwen + */ +public class ContractGetMoneyToFirstPayment implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取首付款 + String FIRST_PAYMENT=param.get("FIRST_PAYMENT")==null?"0.00":param.get("FIRST_PAYMENT"); + returnValue.put("MONEY",FIRST_PAYMENT); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentNoTax.java new file mode 100644 index 000000000..6e5551ff0 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentNoTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 首付款(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToFirstPaymentNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 首付款(不含税) + String FIRST_PAYMENT_NOTAX=param.get("FIRST_PAYMENT_NOTAX")==null?"0.00":param.get("FIRST_PAYMENT_NOTAX"); + returnValue.put("MONEY",FIRST_PAYMENT_NOTAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentTax.java new file mode 100644 index 000000000..bb58b06de --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToFirstPaymentTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 首付款(税金) + * @author xiezhiwen + */ +public class ContractGetMoneyToFirstPaymentTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 首付款(税金) + String FIRST_PAYMENT_TAX=param.get("FIRST_PAYMENT_TAX")==null?"0.00":param.get("FIRST_PAYMENT_TAX"); + returnValue.put("MONEY",FIRST_PAYMENT_TAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingCharge.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingCharge.java new file mode 100644 index 000000000..9324dc22d --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingCharge.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取手续费 + * @author xiezhiwen + */ +public class ContractGetMoneyToHandlingCharge implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取手续费 + String HANDLING_CHARGE_MONEY=param.get("HANDLING_CHARGE_MONEY")==null?"0.00":param.get("HANDLING_CHARGE_MONEY"); + returnValue.put("MONEY",HANDLING_CHARGE_MONEY); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeNoTax.java new file mode 100644 index 000000000..b4e98aa2b --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeNoTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取手续费(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToHandlingChargeNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取手续费(不含税) + String HANDLING_CHARGE_MONEY_NOTAX=param.get("HANDLING_CHARGE_MONEY_NOTAX")==null?"0.00":param.get("HANDLING_CHARGE_MONEY_NOTAX"); + returnValue.put("MONEY",HANDLING_CHARGE_MONEY_NOTAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeTax.java new file mode 100644 index 000000000..fa3bb3f3d --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToHandlingChargeTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取手续费(税金) + * @author xiezhiwen + */ +public class ContractGetMoneyToHandlingChargeTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取手续费(税金) + String HANDLING_CHARGE_MONEY_TAX=param.get("HANDLING_CHARGE_MONEY_TAX")==null?"0.00":param.get("HANDLING_CHARGE_MONEY_TAX"); + returnValue.put("MONEY",HANDLING_CHARGE_MONEY_TAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOther.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOther.java new file mode 100644 index 000000000..5ccac5085 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOther.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 保险+其他 + * @author xiezhiwen + */ +public class ContractGetMoneyToInsuranceAddOther implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String INSURANCE_PREMIUM_ADD_OTHER=param.get("INSURANCE_PREMIUM_ADD_OTHER")==null?"0.00":param.get("INSURANCE_PREMIUM_ADD_OTHER"); + returnValue.put("MONEY",INSURANCE_PREMIUM_ADD_OTHER); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherNoTax.java new file mode 100644 index 000000000..1c7109ae7 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherNoTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 保险+其他(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToInsuranceAddOtherNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String INSURANCE_PREMIUM_ADD_OTHER_NOTAX=param.get("INSURANCE_PREMIUM_ADD_OTHER_NOTAX")==null?"0.00":param.get("INSURANCE_PREMIUM_ADD_OTHER_NOTAX"); + returnValue.put("MONEY",INSURANCE_PREMIUM_ADD_OTHER_NOTAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherTax.java new file mode 100644 index 000000000..79defb5d9 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToInsuranceAddOtherTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 保险+其他(税金) + * @author xiezhiwen + */ +public class ContractGetMoneyToInsuranceAddOtherTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 保险+其他(税金) + String INSURANCE_PREMIUM_ADD_OTHER_TAX=param.get("INSURANCE_PREMIUM_ADD_OTHER_TAX")==null?"0.00":param.get("INSURANCE_PREMIUM_ADD_OTHER_TAX"); + returnValue.put("MONEY",INSURANCE_PREMIUM_ADD_OTHER_TAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoney.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoney.java new file mode 100644 index 000000000..5c91a7924 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoney.java @@ -0,0 +1,20 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取FACT_MONEY + * @author xiezhiwen + */ +public class ContractGetMoneyToMoney implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx,Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + returnValue.put("MONEY",param.get("FACT_MONEY")); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyNoTax.java new file mode 100644 index 000000000..06cc158e3 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyNoTax.java @@ -0,0 +1,20 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取INTERESTNOTAX + * @author xiezhiwen + */ +public class ContractGetMoneyToMoneyNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx,Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + returnValue.put("MONEY",param.get("INTERESTNOTAX")); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyTax.java new file mode 100644 index 000000000..3f3dc12ac --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToMoneyTax.java @@ -0,0 +1,20 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取TAX + * @author xiezhiwen + */ +public class ContractGetMoneyToMoneyTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx,Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + returnValue.put("MONEY",param.get("TAX")); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOther.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOther.java new file mode 100644 index 000000000..6ba47bc76 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOther.java @@ -0,0 +1,23 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.math.BigDecimal; +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取其它金额 + * @author xiezhiwen + */ +public class ContractGetMoneyToOther implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取其它金额 + String OTHER_MONEY=param.get("OTHER_MONEY")==null?"0.00":param.get("OTHER_MONEY"); + returnValue.put("MONEY",OTHER_MONEY); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherNoTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherNoTax.java new file mode 100644 index 000000000..46d5feade --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherNoTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取其它金额(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToOtherNoTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取其它金额 + String OTHER_MONEY_NOTAX=param.get("OTHER_MONEY_NOTAX")==null?"0.00":param.get("OTHER_MONEY_NOTAX"); + returnValue.put("MONEY",OTHER_MONEY_NOTAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherTax.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherTax.java new file mode 100644 index 000000000..be577072a --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOtherTax.java @@ -0,0 +1,22 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 获取其它金额(不含税) + * @author xiezhiwen + */ +public class ContractGetMoneyToOtherTax implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取其它金额 + String OTHER_MONEY_TAX=param.get("OTHER_MONEY_TAX")==null?"0.00":param.get("OTHER_MONEY_TAX"); + returnValue.put("MONEY",OTHER_MONEY_TAX); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOthersMath.java b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOthersMath.java new file mode 100644 index 000000000..3df614451 --- /dev/null +++ b/src_core/com/tenwa/voucher/CreateVoucherProcess/VoucherGetMoneyForTradition/ContractGetMoneyToOthersMath.java @@ -0,0 +1,34 @@ +package com.tenwa.voucher.CreateVoucherProcess.VoucherGetMoneyForTradition; + +import java.math.BigDecimal; +import java.util.HashMap; +import java.util.Map; + +import com.amarsoft.are.jbo.JBOTransaction; +import com.tenwa.comm.exception.BusinessException; +import com.tenwa.voucher.service.VoucherJavaParamService; +/** + * 设备款+其他金额-首付款-手续费-保证金 + * @author xiezhiwen + */ +public class ContractGetMoneyToOthersMath implements VoucherJavaParamService{ + public Map getJavaParam(JBOTransaction tx, Map param) throws BusinessException { + MapreturnValue=new HashMap(); + returnValue.putAll(param); + // 获取设备款 + String EQUIP_AMT=param.get("EQUIP_AMT")==null?"0.00":param.get("EQUIP_AMT"); + // 获取其它金额 + String OTHER_MONEY=param.get("OTHER_MONEY")==null?"0.00":param.get("OTHER_MONEY"); + // 获取首付款 + String FIRST_PAYMENT=param.get("FIRST_PAYMENT")==null?"0.00":param.get("FIRST_PAYMENT"); + // 获取保证金 + String CAUTION_MONEY=param.get("CAUTION_MONEY")==null?"0.00":param.get("CAUTION_MONEY"); + // 获取手续费 + String HANDLING_CHARGE_MONEY=param.get("HANDLING_CHARGE_MONEY")==null?"0.00":param.get("HANDLING_CHARGE_MONEY"); + // 其他款项+设备款 + BigDecimal FactMoney=new BigDecimal(EQUIP_AMT).add(new BigDecimal(OTHER_MONEY)).subtract(new BigDecimal(FIRST_PAYMENT)).subtract(new BigDecimal(CAUTION_MONEY)).subtract(new BigDecimal(HANDLING_CHARGE_MONEY)); + + returnValue.put("MONEY",FactMoney.toString()); + return returnValue; + } +} diff --git a/src_core/com/tenwa/voucher/serviceImp/CreateVoucherServiceImpl.java b/src_core/com/tenwa/voucher/serviceImp/CreateVoucherServiceImpl.java index cf088a8d6..97bf5dfb7 100644 --- a/src_core/com/tenwa/voucher/serviceImp/CreateVoucherServiceImpl.java +++ b/src_core/com/tenwa/voucher/serviceImp/CreateVoucherServiceImpl.java @@ -311,13 +311,16 @@ public class CreateVoucherServiceImpl { }else if("PZ2018082600000149".equals(VOUCHERNO) || "PZ2018082600000150".equals(VOUCHERNO) || "PZ2018070900000003".equals(VOUCHERNO) || "PZ2018080200000065".equals(VOUCHERNO)) { subData.put("CUSTID",dataTemp.get("DISTRIBUTOR_ID"));//经销商id subData.put("CUSTNAME",dataTemp.get("DISTRIBUTOR_NAME"));//经销商名称 - }else if("PZ2018072100000037".equals(VOUCHERNO)||"PZ2018080400000091".equals(VOUCHERNO) || "PZ2018072100000038".equals(VOUCHERNO)||"PZ2018080400000092".equals(VOUCHERNO)){ + }else if("PZ2018072100000037".equals(VOUCHERNO)||"PZ2018080400000091".equals(VOUCHERNO) || "PZ2018072100000038".equals(VOUCHERNO) || "PZ2018080400000092".equals(VOUCHERNO)){ subData.put("CUSTID","APZL00000000DC");//经销商id subData.put("CUSTNAME","业务系统待查客户");//经销商名称 - }else if("PZ2018092500000192".equals(VOUCHERNO)||"PZ2018092500000193".equals(VOUCHERNO) || "PZ2018092500000194".equals(VOUCHERNO)||"PZ2018092500000195".equals(VOUCHERNO)){ + }else if("PZ2018092500000192".equals(VOUCHERNO)||"PZ2018092500000193".equals(VOUCHERNO) || "PZ2018092500000194".equals(VOUCHERNO) || "PZ2018092500000195".equals(VOUCHERNO) || "PZ2018092600000240".equals(VOUCHERNO)||"PZ2018092600000241".equals(VOUCHERNO) || "PZ2018092600000242".equals(VOUCHERNO) || "PZ2018092600000243".equals(VOUCHERNO)){ subData.put("CUSTID","APZL00000000DC");//经销商id subData.put("CUSTNAME","业务系统待查客户");//经销商名称 - }else if("PZ2018092500000156".equals(VOUCHERNO)||"PZ2018092500000157".equals(VOUCHERNO) || "PZ2018092500000158".equals(VOUCHERNO)){ + }else if("PZ2018092500000164".equals(VOUCHERNO)||"PZ2018092600000229".equals(VOUCHERNO) || "PZ2018092500000166".equals(VOUCHERNO) || "PZ2018092600000231".equals(VOUCHERNO)){ + subData.put("CUSTID","APZL00000000DC");//经销商id + subData.put("CUSTNAME","业务系统待查客户");//经销商名称 + }else if("PZ2018092500000156".equals(VOUCHERNO)||"PZ2018092500000157".equals(VOUCHERNO) || "PZ2018092500000158".equals(VOUCHERNO) || "PZ2018092600000244".equals(VOUCHERNO)||"PZ2018092600000245".equals(VOUCHERNO) || "PZ2018092600000246".equals(VOUCHERNO)){ subData.put("CUSTID","APZL00000000DC");//经销商id subData.put("CUSTNAME","业务系统待查客户");//经销商名称 }else {