diff --git a/WebContent/WEB-INF/etc/jbo/jbo_lease.xml b/WebContent/WEB-INF/etc/jbo/jbo_lease.xml index fa994222a..63df377c0 100644 --- a/WebContent/WEB-INF/etc/jbo/jbo_lease.xml +++ b/WebContent/WEB-INF/etc/jbo/jbo_lease.xml @@ -4301,7 +4301,7 @@ - + diff --git a/src_tenwa/com/tenwa/collectaudit/cache/CollectAuditInfoCache.java b/src_tenwa/com/tenwa/collectaudit/cache/CollectAuditInfoCache.java index 6dcb2c1b9..985b33125 100644 --- a/src_tenwa/com/tenwa/collectaudit/cache/CollectAuditInfoCache.java +++ b/src_tenwa/com/tenwa/collectaudit/cache/CollectAuditInfoCache.java @@ -422,7 +422,7 @@ public class CollectAuditInfoCache { BizObjectManager bmi = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,transaction); BizObject boi = bmi.createQuery("select v.replace(v.uuid(),'-','') as v.id,O.QUOT_ID as v.QUOT_ID,O.CUST_ID as v.CUST_ID,O.PROJECT_ID as v.PROJECT_ID,O.PROJECT_PLAN_NUMBER as v.PROJECT_PLAN_NUMBER," + "O.CONTRACT_ID as v.CONTRACT_ID,O.CONTRACT_PLAN_NUMBER as v.CONTRACT_PLAN_NUMBER,O.PAYMENT_NUMBER as v.PAYMENT_NUMBER,'' as v.EBANK_NUMBER,O.id as v.PLAN_ID,O.PLAN_LIST as v.PLAN_LIST," - + "'0' as v.INTEREST_ADJUST,'settlemethod6' as v.SETTLE_METHOD,'"+hire_list+"' as v.HIRE_LIST,'"+cerrentDate+"' as v.HIRE_DATE,'"+rent+"' as v.RENT,("+rent+"-vl.interest_over) as v.CORPUS,vl.interest_over as v.INTEREST,vl.penalty_over as v.PENALTY," + + "'0' as v.INTEREST_ADJUST,'settlemethod6' as v.SETTLE_METHOD,'"+hire_list+"' as v.HIRE_LIST,'"+cerrentDate+"' as v.HIRE_DATE,vl.rent_over v.RENT,vl.corpus_over as v.CORPUS,vl.interest_over as v.INTEREST,("+rent+"-vl.corpus_over) as v.PENALTY," + "'0' as v.CORPUS_ADJUST,'0' as v.PENALTY_ADJUST,'0' as v.ROLL_BACK,O.COIN as v.COIN from O, jbo.app.tenwa.calc.VI_LC_RENT_PLAN vl where O.id = vl.id" + " and vl.contract_id =:contract_id and vl.plan_date =:plan_date") .setParameter("contract_id", bo.getAttribute("contract_id").toString()) @@ -797,7 +797,7 @@ public class CollectAuditInfoCache { BizObjectManager bmi = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,transaction); BizObject boi = bmi.createQuery("select v.replace(v.uuid(),'-','') as v.id,O.QUOT_ID as v.QUOT_ID,O.CUST_ID as v.CUST_ID,O.PROJECT_ID as v.PROJECT_ID,O.PROJECT_PLAN_NUMBER as v.PROJECT_PLAN_NUMBER," + "O.CONTRACT_ID as v.CONTRACT_ID,O.CONTRACT_PLAN_NUMBER as v.CONTRACT_PLAN_NUMBER,O.PAYMENT_NUMBER as v.PAYMENT_NUMBER,'' as v.EBANK_NUMBER,O.id as v.PLAN_ID,O.PLAN_LIST as v.PLAN_LIST," - + "'0' as v.INTEREST_ADJUST,'settlemethod6' as v.SETTLE_METHOD,'"+hire_list+"' as v.HIRE_LIST,'"+cerrentDate+"' as v.HIRE_DATE,vl.rent_over as v.RENT,vl.corpus_over v.CORPUS,vl.interest_over v.INTEREST,("+rent+"-vl.rent_over) as v.PENALTY," + + "'0' as v.INTEREST_ADJUST,'settlemethod6' as v.SETTLE_METHOD,'"+hire_list+"' as v.HIRE_LIST,'"+cerrentDate+"' as v.HIRE_DATE,vl.rent_over as v.RENT,vl.corpus_over as v.CORPUS,vl.interest_over as v.INTEREST,("+rent+"-vl.rent_over) as v.PENALTY," + "'0' as v.CORPUS_ADJUST,'0' as v.PENALTY_ADJUST,'0' as v.ROLL_BACK,O.COIN as v.COIN from O, jbo.app.tenwa.calc.VI_LC_RENT_PLAN vl where O.id = vl.id" + " and vl.contract_id =:contract_id and vl.plan_date =:plan_date") .setParameter("contract_id", bo.getAttribute("contract_id").toString()) diff --git a/src_tenwa/com/tenwa/flow/comm/handler/flowmanage/OverdueProjectCache.java b/src_tenwa/com/tenwa/flow/comm/handler/flowmanage/OverdueProjectCache.java index f951163d6..2ea5a8c4b 100644 --- a/src_tenwa/com/tenwa/flow/comm/handler/flowmanage/OverdueProjectCache.java +++ b/src_tenwa/com/tenwa/flow/comm/handler/flowmanage/OverdueProjectCache.java @@ -111,9 +111,9 @@ public class OverdueProjectCache { try { Sqlca = Transaction.createTransaction(CacheLoaderFactory.getDataSource()); String sql="SELECT COUNT(*) outlist FROM lc_rent_plan inner join(SELECT IFNULL(lrp.rent,0)-IFNULL(lri.money,0) rent_overage,lrp.ID FROM lc_rent_plan lrp LEFT JOIN(SELECT SUM(IFNULL(rent,0))+SUM(IFNULL(interest_adjust,0)) money,plan_id FROM lc_rent_income WHERE roll_back ='0' GROUP BY plan_id) AS lri ON lri.plan_id=lrp.ID) l on l.id=lc_rent_plan.id WHERE lc_rent_plan.plan_date0 and contract_id=:contract_id and payment_number=:payment_number GROUP BY contract_id,payment_number"; - // if("ORACLE".equals(InitDBType.DBTYPE)){ + if("ORACLE".equals(InitDBType.DBTYPE)){ sql="SELECT COUNT(*) outlist FROM lc_rent_plan inner join(SELECT nvl(lrp.rent,0)-nvl(lri.money,0) rent_overage,lrp.ID FROM lc_rent_plan lrp LEFT JOIN(SELECT SUM(nvl(rent,0))+SUM(nvl(interest_adjust,0)) money,plan_id FROM lc_rent_income WHERE roll_back ='0' GROUP BY plan_id) lri ON lri.plan_id=lrp.ID) l on l.id=lc_rent_plan.id WHERE str_to_date(lc_rent_plan.plan_date,'%y/%m/%d')0 and contract_id=:contract_id and payment_number=:payment_number GROUP BY contract_id,payment_number"; - // } + } SqlObject asql = new SqlObject(sql); asql.setParameter("contract_id", id); asql.setParameter("payment_number", payment_number); diff --git a/src_tenwa/com/tenwa/lease/app/quartzmession/AutoFiveGradeClassification.java b/src_tenwa/com/tenwa/lease/app/quartzmession/AutoFiveGradeClassification.java index ec1a1d40c..17c37a465 100644 --- a/src_tenwa/com/tenwa/lease/app/quartzmession/AutoFiveGradeClassification.java +++ b/src_tenwa/com/tenwa/lease/app/quartzmession/AutoFiveGradeClassification.java @@ -109,12 +109,13 @@ public class AutoFiveGradeClassification implements Job { //0.获取逾期天数和期次 String overday = OverdueProjectCache.getOverDays(lccs.getAttribute("CONTRACT_ID").getString(), lccs.getAttribute("PAYMENT_NUMBER").getString()); // Integer overdays=Integer.parseInt(overday.replaceAll("\\.0", "")); - String outlist = OverdueProjectCache.getOutList(lccs.getAttribute("CONTRACT_ID").getString(), lccs.getAttribute("PAYMENT_NUMBER").getString()); - outlist=outlist.replaceAll("\\.0", ""); +// String outlist = OverdueProjectCache.getOutList(lccs.getAttribute("CONTRACT_ID").getString(), lccs.getAttribute("PAYMENT_NUMBER").getString()); +// outlist=outlist.replaceAll("\\.0", ""); //1.获取等级 String fiveGrade = getFiveConfig(overday);//ProductParamUtil.getFiveGradeClassification(productId, overdays); //2.更新跑批状态表(最新) - lccsManager.createQuery("update o set FIVE_GRADE='"+fiveGrade+"',FIVE_GRADE_DATE=:fivegradedate,overduedays='"+overday+"',overdue='"+outlist+"' where CONTRACT_ID=:id ").setParameter("fivegradedate",DateAssistant.getToday()).setParameter("id",lccs.getAttribute("CONTRACT_ID").getString()).executeUpdate(); + lccsManager.createQuery("update o set FIVE_GRADE='"+fiveGrade+"',FIVE_GRADE_DATE=:fivegradedate where CONTRACT_ID=:id ") + .setParameter("fivegradedate",DateAssistant.getToday()).setParameter("id",lccs.getAttribute("CONTRACT_ID").getString()).executeUpdate(); FIVE_GRADE=fiveGrade; BizObject singleResult = five_gr.createQuery("select * from o where FIVE_GRADE_DATE=:fivegradedate and CONTRACT_ID=:id ").setParameter("fivegradedate",DateAssistant.getToday()).setParameter("id",lccs.getAttribute("CONTRACT_ID").getString()).getSingleResult(false); //3.入分类等级明细表(累计) @@ -170,11 +171,12 @@ public class AutoFiveGradeClassification implements Job { public String getFiveConfig(String overDays) throws JBOException{ - BizObject gradeConfg = JBOFactory.getBizObjectManager(LM_GRADE_CLASSIFICATION.CLASS_NAME).createQuery("select * from O where "+overDays+" BETWEEN overdue_loan_min and overdue_loan_max").getSingleResult(false); + BizObject gradeConfg = JBOFactory.getBizObjectManager(LM_GRADE_CLASSIFICATION.CLASS_NAME).createQuery(overDays+" BETWEEN overdue_loan_min and overdue_loan_max").getSingleResult(false); if(gradeConfg!=null){ return gradeConfg.getAttribute(LM_GRADE_CLASSIFICATION.loan_result).getString(); + }else{ + return "getGrade01"; } - throw new JBOException("五级分类未配置……"); }