diff --git a/WebContent/Tenwa/Lease/Flow/Fund/FundCollection/GetPenalty.jsp b/WebContent/Tenwa/Lease/Flow/Fund/FundCollection/GetPenalty.jsp index 5c31cf036..d0c2957dd 100644 --- a/WebContent/Tenwa/Lease/Flow/Fund/FundCollection/GetPenalty.jsp +++ b/WebContent/Tenwa/Lease/Flow/Fund/FundCollection/GetPenalty.jsp @@ -8,8 +8,8 @@ String PAYMENT_NUMBER = CurPage.getParameter("PAYMENT_NUMBER"); String PLAN_LIST = CurPage.getParameter("PLAN_LIST"); String HIRE_DATE = CurPage.getParameter("HIRE_DATE"); - String penalty = JBOFactory.getBizObjectManager(LB_CONTRACT_INFO.CLASS_NAME) - .createQuery("select v.round(v.ifnull(v.getRentPenalty('"+PAYMENT_NUMBER+"','"+PLAN_LIST+"','"+HIRE_DATE+"'),0),2) as v.penalty from O").getSingleResult(false).getAttribute("penalty").getString(); - + String quwetSql = "select round(getRentPenalty('"+PAYMENT_NUMBER+"','"+PLAN_LIST+"','"+HIRE_DATE+"')-(ifnull(`lcfd`.`penalty`, 0) + ifnull(`lcfd`.`penalty_adjust`, 0)),2) as penalty from lc_rent_plan lrp LEFT JOIN lc_rent_income_transfer lcfd ON lrp.PAYMENT_NUMBER = lcfd.payment_number AND lrp.PLAN_LIST = lcfd.plan_list where lrp.payment_number ='"+PAYMENT_NUMBER+"' and lrp.plan_list = '"+PLAN_LIST+"'"; + String penalty = Sqlca.getString(quwetSql); + penalty = penalty.indexOf("-")>=0?"0.00":penalty; out.println(penalty); %><%@ include file="/IncludeEndAJAX.jsp"%> \ No newline at end of file diff --git a/WebContent/Tenwa/Lease/Flow/Rent/PenaltyReduction/LCRentIncomeTempReductionList.jsp b/WebContent/Tenwa/Lease/Flow/Rent/PenaltyReduction/LCRentIncomeTempReductionList.jsp index 1229e420d..dc602a87f 100644 --- a/WebContent/Tenwa/Lease/Flow/Rent/PenaltyReduction/LCRentIncomeTempReductionList.jsp +++ b/WebContent/Tenwa/Lease/Flow/Rent/PenaltyReduction/LCRentIncomeTempReductionList.jsp @@ -40,7 +40,7 @@ }; }else{ sButtons = new String[][]{ - {"true","","Button","保存","保存","as_save(0)","","","","btn_icon_save",""}, + {"true","","Button","保存","保存","as_save(0,'bindEvent()')","","","","btn_icon_save",""}, {"true","","Button","撤销","撤销","doDelete()","","","","btn_icon_delete",""} }; } @@ -95,16 +95,25 @@ var PLAN_LIST = getCurrentItemValue("PLAN_LIST"); var HIRE_DATE = datelist; var penalty = AsControl.RunJsp("/Tenwa/Lease/Flow/Fund/FundCollection/GetPenalty.jsp","PAYMENT_NUMBER="+PAYMENT_NUMBER+"&PLAN_LIST="+PLAN_LIST+"&HIRE_DATE="+HIRE_DATE); - setItemValue(0, getRow(0), "PENALTY_ADJUST", penalty); - setItemValue(0, getRow(0), "HIRE_DATE", datelist); - } - $(function(){ - for (var i=0;ieval(getItemValue(0,getRow(0),"PENALTY_OVER")) ){ + alert("计算罚息:"+penalty+",应在0与"+getItemValue(0,getRow(0),"PENALTY_OVER")+"之间!"); + setItemValue(0, getRow(0), "PENALTY_ADJUST", DZ[0][2][getRow(0)][22]); + setItemValue(0, getRow(0), "HIRE_DATE", DZ[0][2][getRow(0)][9]); + return false; } - - }); + setItemValue(0, getRow(0), "PENALTY_ADJUST", penalty); + setItemValue(0, getRow(0), "HIRE_DATE", datelist); + } + function bindEvent() { + for (var i=0;i <%@ include file="/Frame/resources/include/include_end.jspf"%> \ No newline at end of file