diff --git a/WebContent/Accounting/LoanSimulation/LCCalcSubsectionInfoTempList.jsp b/WebContent/Accounting/LoanSimulation/LCCalcSubsectionInfoTempList.jsp
new file mode 100644
index 000000000..d341e3d87
--- /dev/null
+++ b/WebContent/Accounting/LoanSimulation/LCCalcSubsectionInfoTempList.jsp
@@ -0,0 +1,117 @@
+<%@ page contentType="text/html; charset=GBK"%>
+<%@ include file="/Frame/resources/include/include_begin_list.jspf"%><%
+ /*
+ Author: undefined 2021-07-20
+ Content:
+ History Log:
+ */
+ String flowunid = CurPage.getParameter("flowunid");
+ String projectId = CurPage.getParameter("projectId");
+ ASObjectModel doTemp = new ASObjectModel("LCCalcSubsectionInfoTemp");
+ doTemp.setHtmlEvent( "DISCOUNT", "onblur", "changeDiscount" );
+ doTemp.setHtmlEvent( "DISCOUNT_RATE", "onblur", "changeDiscountRate" );
+ doTemp.setHtmlEvent( "CLEAN_LEASE_RATIO", "onblur", "changeCleanLeaseRatio" );
+ ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
+ dwTemp.Style="1"; //--设置为Grid风格--
+ dwTemp.ReadOnly = "0"; //只读模式
+ dwTemp.setPageSize(10);
+ dwTemp.genHTMLObjectWindow(flowunid);
+
+ //0、是否展示 1、 权限控制 2、 展示类型 3、按钮显示名称 4、按钮解释文字 5、按钮触发事件代码 6、 7、 8、 9、图标,CSS层叠样式 10、风格
+ String sButtons[][] = {
+ {"true","All","Button","保存","保存","save()","","","","btn_icon_save",""},
+ };
+%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
+
+<%@ include file="/Frame/resources/include/include_end.jspf"%>
diff --git a/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp b/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp
index 78b172d26..a21918983 100644
--- a/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp
+++ b/WebContent/Accounting/LoanSimulation/LoanBasicInfo.jsp
@@ -41,7 +41,7 @@
}
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);
@@ -87,8 +87,8 @@
String carTypea = Sqlca.getString( "SELECT car_typea FROM lb_equipment_car_temp WHERE flowunid='" + flowunid + "' LIMIT 1 " );
//获取产品配置的留购价款
String nominalPrice= ProductParamUtil.getProductParameterValue( productId, "PRD0315", "NOMINAL_PRICE", "CostType08" ) ;
-
-
+
+
ASObjectModel doTemp = new ASObjectModel(templateNo);
Map> productRates = ProductParamUtil.getProductComponentType(productId, "PRD0350");
@@ -108,7 +108,7 @@
}
if("02".equals(termType)){
doTemp.setColumnAttribute("INCOME_NUMBER", "coleditstyle", "1");
-
+
}
if("N".equals(isFixedRate)){
doTemp.setReadOnly("YEAR_RATE", false);
@@ -123,7 +123,7 @@
doTemp.setHtmlEvent( "YEAR_RATE", "onchange", "changeYearRate" ); // 年利率事件
doTemp.setHtmlEvent( "RENT_VALUE", "onchange", "changeRentValue" ); // 预计租金事件
doTemp.setDefaultValue( "GPS_DIFFERENCE", ProductParamUtil.getProductParameterValue( productId, "PRD0390", "GPSDifference", "GPSDifference" ) );
-
+
Map> ProductRevenue = ProductParamUtil.getProductComponentType(productId, "PRD0390");
Map bondAndPayments = ProductRevenue.get("bondAndPayments");
bondAndPaymentsMin = bondAndPayments.get("bondAndPayments-MIN");
@@ -150,8 +150,7 @@
doTemp.setHtmlEvent("FIRST_PLAN_DATE", "onchange", "changeFistPlanDate");//第一期计划日期
doTemp.setHtmlEvent("CORPUS_RATIO", "onchange", "changeCorpusRatio");//期限内本金比例
doTemp.setHtmlEvent("EQUIP_AMT", "onchange", "changgeCompare");//车价
- doTemp.setHtmlEvent("is_subsection", "onchange", "isSubsection");//是否分段
- doTemp.setHtmlEvent("subsection_num", "onchange", "subsectionNum");//是否分段
+ doTemp.setHtmlEvent("SUBSECTION_CONFIG", "onchange", "changeSubsectionConfig");//车价
/*设置字段事件*/
/*设置模板属性*/
@@ -159,13 +158,13 @@
//费用规则
ProductCondition pc=new ProductCondition();
pc.getProductFundRules(doTemp, productId);
- String calcRules=pc.getProductRules(doTemp, productId,vali);
-
+ String calcRules=pc.getProductRules(doTemp, productId, vali, flowunid );
+
//获取产品名称
BizObject bo = JBOFactory.createBizObjectQuery(BUSINESS_TYPE.CLASS_NAME,"typeno=:productID")
.setParameter("productID", productId).getSingleResult(false);
String productName = (bo==null)?"":bo.getAttribute("typename").getString();
-
+
//非车辆产品,融资额可编辑
String productType = Sqlca.getString(new SqlObject("select attribute2 from business_type where typeno='"+productId+"'"));
if("car_product".equals(productType)){
@@ -174,7 +173,7 @@
// doTemp.setVisible("CORPUS_RATIO", true);
// doTemp.setVisible("CORPUS", true);
// doTemp.setRequired("CORPUS_RATIO", true);
- }
+ }
if("quoted_price".equals(calType)){//客户报价 流程号存的是客户主键
doTemp.setDefaultValue("cust_id", flowunid);
}
@@ -183,33 +182,32 @@
doTemp.setDefaultValue(planCName, plannumber);
doTemp.setDefaultValue("flowunid", flowunid);
doTemp.setDefaultValue("PRODUCT_NAME", productName);
- doTemp.setDefaultValue("is_subsection", "no");
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);
- /*设置页面属性*/
+ /*设置页面属性*/
boolean flag=CurUser.hasRole("401");
if(CurUser.hasRole("401")){
doTemp.setVisible("CAUTION_MONEY_METHOD",false);
doTemp.setVisible("DISCOUNT", false);
// doTemp.setColumnAttribute("DISCOUNT","colvisible","0");
- }
+ }
if(CurUser.hasRole("800R00000013")||CurUser.hasRole("800R00000014")||CurUser.hasRole("800R00000015")){
doTemp.setVisible("YEAR_RATE", true);
doTemp.setVisible("RENT_RATIO",true);
}
-
+
ASObjectWindowCalc dwTemp = new ASObjectWindowCalc(CurPage, doTemp,request);
-
-
+
+
dwTemp.Style = "2";//freeform
if((null!=RightType&&RightType.equals("ReadOnly"))||(null!=ishistory&&ishistory.equals("true"))){
dwTemp.ReadOnly = "1";//只读模式
@@ -223,15 +221,15 @@
dwTemp.setAttr("showRatio", true);
dwTemp.genHTMLObjectWindow(flowunid);
CurPage.getCurComp().setAttribute("RightType", RightType);
-
+
String compClientID = request.getParameter("CompClientID");
- dwTemp.replaceColumn("condition_plan", "", CurPage.getObjectWindowOutput());
- //dwTemp.replaceColumn("even_subsection", "", CurPage.getObjectWindowOutput());
+ dwTemp.replaceColumn("condition_plan", "", CurPage.getObjectWindowOutput());
+ //dwTemp.replaceColumn("even_subsection", "", CurPage.getObjectWindowOutput());
//dwTemp.replaceColumn("knowing_config", "", CurPage.getObjectWindowOutput());
- dwTemp.replaceColumn("subsection_info", "", CurPage.getObjectWindowOutput());
+ dwTemp.replaceColumn("subsection_info", "", CurPage.getObjectWindowOutput());
String businessDate = DateHelper.getBusinessDate();
-
+
//获取对应车辆指导价
BizObject bo1 = JBOFactory.createBizObjectQuery(LB_EQUIPMENT_CAR_TEMP.CLASS_NAME,"PROJECT_ID=:projectId")
.setParameter("projectId",projectId).getSingleResult(false);
@@ -259,7 +257,7 @@ $(function(){
rentOrRateOption=$("#RENT_OR_RATE").children();
incomeNumberYear=$("#INCOME_NUMBER_YEAR").children();
adjustType=$("#ADJUST_TYPE").children();
-
+
incomeNumber=$("#INCOME_NUMBER").children();
var fundRules=calcRules["fund"];
for(var key in fundRules){
@@ -294,11 +292,11 @@ $(function(){
if(inco[value]==1){
$("#INCOME_NUMBER").append(this);
}
- });
+ });
$("#INCOME_NUMBER").val(inerNumber);
-
+
count++;
- }else{
+ }else{
changeSettleMethod3();
}
// getRatioByMoney(getObj(0, "EQUIP_AMT"));
@@ -313,10 +311,21 @@ $(function(){
if( "BusinessApplyFlow"==flowNo || "BusinessChangeFlow" == flowNo ){
setItemValue( 0, 0, 'NOMINAL_PRICE', Number(nominalPrice)*carNum );
}
- isSubsection();
-
});
+function changeSubsectionConfig() {
+ var settleMethod = getItemValue( 0, 0, 'SETTLE_METHOD' );
+ var subsectionConfig = getItemValue( 0, 0, 'SUBSECTION_CONFIG' );
+ if ( 'segmented_financing' === settleMethod && '' !== subsectionConfig ) {
+ var equipAmt = getItemValue( 0, 0, 'EQUIP_AMT' );
+ var cleanLeaseMoney = getItemValue( 0, 0, 'CLEAN_LEASE_MONEY' );
+ var result = RunJavaMethodTrans( 'com.tenwa.reckon.executor.CreateTransactionExecutor', 'resetSubsection', 'flowunid=<%=flowunid%>,equipAmt=' + equipAmt + ',cleanLeasemoney=' + cleanLeaseMoney + ',subsectionConfig=' + subsectionConfig );
+ if ( result === 'SUCCESS' ) {
+ subsection_list.window.reloadSelf();
+ }
+ }
+}
+
function changeYearRate() {
if ( getItemValue( 0, 0, 'YEAR_RATE' ) !== '' ) {
setItemValue( 0, 0, 'RENT_VALUE', '0.00' );
@@ -370,7 +379,7 @@ function importCustomerQuot(){
var param2="FlowUnid=<%=flowunid%>&calType=<%=calType%>&plannumber=<%=plannumber%>";
AsControl.OpenView("/Accounting/LoanSimulation/LoanBasicInfo.jsp",param2, "_self");
},"请选择客户报价",'');
-
+
}
@@ -481,7 +490,7 @@ CalcControl.InitSecondPlanDate=function(){
var firstPlanDate=getItemValue(0,0,"FIRST_PLAN_DATE");
if(!firstPlanDate)return;
setItemValue(0,0,"SECOND_PLAN_DATE",dateAdd('m',incomenumberyear,new Date(firstPlanDate)).format('yyyy\/MM\/dd'));
-
+
}
@@ -562,7 +571,7 @@ CalcControl.SettleMethodView=function(){
}
var ids="RENT_OR_RATE,INCOME_NUMBER_YEAR,INCOME_INTERVAL_MONTH,INCOME_NUMBER,PERIOD_TYPE,GRACE,RATE_FLOAT_TYPE,BASE_RATE,RATE_FLOAT_AMT,YEAR_RATE,RENT_VALUE,FIRST_PLAN_DATE,SECOND_PLAN_DATE";
if(method == 'irregular_rent'||method=="even_subsection"){
-
+
setDisable(ids);
var showIds="RATE_FLOAT_DAY,FIRST_PLAN_DATE,SECOND_PLAN_DATE,PERIOD_TYPE,GRACE";
if(method == 'irregular_rent'){
@@ -582,7 +591,7 @@ CalcControl.SettleMethodView=function(){
CalcControl.RentOrRateView();
setItemRequired(0,"YEAR_RATE",true);
}
-
+
//日期
//计划日期
var plan = "";
@@ -670,8 +679,13 @@ CalcControl.SettleMethodView=function(){
setItemRequired(0,"RATE",false);
setItemRequired(0,"ADDITIONAL_RATE",false);
}
+
+ if ( 'segmented_financing' === method ) {
+ setItemRequired( 0, 'YEAR_RATE', false );
+ }
+
var param="CompClientID=<%=compClientID%>&flowunid=<%=flowunid%>&plannumber=<%=plannumber%>&planCName=<%=planCName%>&IsHistory=<%=ishistory%>&NodeNo=<%=nodeNo%>&calType=<%=calType%>&ProductId=<%=productId%>&method="+method;
- AsControl.OpenView("/Accounting/LoanSimulation/condition_plan.jsp",param, "frame_list");
+ AsControl.OpenView("/Accounting/LoanSimulation/condition_plan.jsp",param, "frame_list");
}
CalcControl.SettleMethodInit=function(){
var method=getItemValue(0,getRow(),"SETTLE_METHOD");
@@ -710,7 +724,7 @@ CalcControl.SettleMethodInit=function(){
setItemValue(0,0,"ADDITIONAL_RATE",calcRules['method'][method]["AdditionalRate"]);
setItemValue(0,0,"INTEREST_DAY_TYPE",calcRules['method'][method]["InterestDayType"]);
}
-
+
}
CalcControl.RentOrRateView=function(){
var rentOrRate = getItemValue(0,getRow(),"RENT_OR_RATE");//租金推算方式
@@ -721,22 +735,22 @@ CalcControl.RentOrRateView=function(){
setItemRequired(0,"RENT_VALUE",false);
if(rentOrRate == 'rate'){//按年利率算租金
if(method=="irregular_rent"||method=="even_subsection"){
-
+
}else{
setEnable(ids);
setEnable(ids2);
CalcControl.RateFloatTypeView();
setItemRequired(0,"YEAR_RATE",true);
}
-
- }else if(rentOrRate == 'rent'){//按租金算年利率
+
+ }else if(rentOrRate == 'rent'){//按租金算年利率
setDisable(ids);
setEnable(ids2);
setEnable('RENT_VALUE');
setEnable('INCOME_NUMBER');
setItemRequired(0,"YEAR_RATE",false);
setItemRequired(0,"RENT_VALUE",true);
- }else if(rentOrRate == 'knowing_rent'){//已知租金规则 只能固定利率
+ }else if(rentOrRate == 'knowing_rent'){//已知租金规则 只能固定利率
setDisable(ids);
setEnable(ids2);
setItemRequired(0,"YEAR_RATE",false);
@@ -809,19 +823,18 @@ CalcControl.RentOrRateInit=function(){
setItemValue(0,0,"FIRST_PLAN_DATE","");
setItemValue(0,0,"SECOND_PLAN_DATE","");
}
-
+
}
//改变租金计算方式
function changeSettleMethod(){
CalcControl.SettleMethodInit();
changeSettleMethod2();
CalcControl.SettleMethodView();
- if(count > 0){
- AsControl.RunJavaMethod("com.tenwa.reckon.executor.CreateTransactionExecutor","runDeleSubsection","flowunid=<%=flowunid%>,plannumber=<%=plannumber%>,planCName=<%=planCName%>,calType=<%=calType%>");
-
- }
+ <%--if(count > 0){--%>
+ <%-- AsControl.RunJavaMethod("com.tenwa.reckon.executor.CreateTransactionExecutor","runDeleSubsection","flowunid=<%=flowunid%>,plannumber=<%=plannumber%>,planCName=<%=planCName%>,calType=<%=calType%>");--%>
+ <%--}--%>
rentOrRateChange();
-
+
}
@@ -841,8 +854,9 @@ function changeSettleMethod2(){
a["even_rent_day"]={"rate":1,"rent":1,"knowing_rent":1,"rent_period":1,"rent_period_360":1};
a["even_subsection"]={"rate":1};
a["irregular_rent"]={"rate":1};
+ a["segmented_financing"]={"rate":1};
a[""]={};
-
+
//***********设置租金推算方法
var settleMethod=getItemValue(0,0,"SETTLE_METHOD");
@@ -884,7 +898,16 @@ function changeSettleMethod2(){
});
$("#INCOME_NUMBER_YEAR").val(incomeValue);
}
-
+
+ document.all( 'A_Group_0020' ).style.display = 'none';
+ if ( settleMethod === 'segmented_financing' ) {
+ document.all( 'A_Group_0020' ).style.display = 'block';
+ var param = 'CompClientID=<%=compClientID%>&flowunid=<%=flowunid%>&plannumber=<%=plannumber%>&planCName=<%=planCName%>&IsHistory=<%=ishistory%>&NodeNo=<%=nodeNo%>&calType=<%=calType%>';
+ AsControl.OpenView( '/Accounting/LoanSimulation/LCCalcSubsectionInfoTempList.jsp', param, 'subsection_list' );
+ setItemRequired( 0, 'SUBSECTION_CONFIG', true );
+ setItemRequired( 0, 'INCOME_NUMBER', false );
+ setItemRequired( 0, 'YEAR_RATE', false );
+ }
}
function changeRateType(){
@@ -893,10 +916,10 @@ function changeRateType(){
a["base"]={"fixed":1,"add":1};
a["proportion"]={"fixed":1,"calculation":1,"add":1};
a["add"]={"fixed":1,"calculation":1,"add":1};
-
+
var RATE_FLOAT_TYPE=getItemValue(0,0,"RATE_FLOAT_TYPE");
var adjustTypeValue=getItemValue(0,0,"ADJUST_TYPE");
-
+
$("#ADJUST_TYPE").empty();
$(adjustType).each(function(){
var value=$(this).attr("value");
@@ -919,7 +942,7 @@ function getRatioByMoney(e){
var cleanLeaseMoney=getItemValue(0,0,"CLEAN_LEASE_MONEY");//融资额
var allMoney = 0;
var fundRules=calcRules["fund"];
-
+
for(var key in fundRules) {
var fundMoney = getItemValue(0,0,key);//金额
if(typeof(fundRules[key]["financing"]) != "undefined" && fundRules[key]["financing"] == "true") {
@@ -954,11 +977,11 @@ function getRatioByMoney(e){
cleanLeaseMoney = equipAmt - firstPayment + Number(allMoney);
setItemValue(0, 0, "CLEAN_LEASE_MONEY", cleanLeaseMoney + "");
allMoney = eval(allMoney + "+" + equipAmt);
-
+
for(var key in fundRules){
var fundMoney=getItemValue(0,0,key);//金额
var fundRatio=getItemValue(0,0,key+"_RATIO");// 比例
-
+
var money=0;
if(fundRules[key]["ratioFee"]=="EquipEndAmt"&&key!="FIRST_PAYMENT"){//比例参照项
money=cleanLeaseMoney;
@@ -967,7 +990,7 @@ function getRatioByMoney(e){
}else{
money=equipAmt;
}
-
+
if(fundRules[key]["ratioType"]=="InputMode03"){//互算
if(e.id==key){
if(Number(equipAmt)!=0){
@@ -991,7 +1014,7 @@ function getRatioByMoney(e){
}
fundRatio=Number(fundMoney/money*100).toFixed(6);
}else{
- fundRatio=Number(0).toFixed(6);
+ fundRatio=Number(0).toFixed(6);
}
setValue(key+"_RATIO",fundRatio);
if(fundRules[key]["isShowRatio"]!="false"){
@@ -1104,7 +1127,7 @@ function saveRecord(sPostEvents){
alert('还租次数需大于0 !!!');
return ;
}
-
+
var termMin = parseInt("<%=termMin%>");
var termMax = parseInt("<%=termMax%>");
var incomeNumber = parseInt(getItemValue(0,0,"INCOME_NUMBER"));
@@ -1169,7 +1192,7 @@ function saveRecord(sPostEvents){
alert("第一期租金计划日期不能小于起租日!");
return ;
}
-
+
//已知本金已知租金,判断保存后的租金和本地是否跟净融资额匹配?
var rentOrRate = getItemValue(0,getRow(),"RENT_OR_RATE");
var cleanLeaseMoney = getItemValue(0,getRow(),"CLEAN_LEASE_MONEY");
@@ -1204,16 +1227,16 @@ function saveRecord(sPostEvents){
alert("保证金和首付款和不在产品配置的值内!!!");
return;
}
-
+
}
// 如果是不规则租金测算的话,那么仅保存商务报价。
var settleMethod = getItemValue(0,getRow(),"SETTLE_METHOD");
if(settleMethod == 'irregular_rent'){
- as_save("myiframe0");
+ as_save("myiframe0");
}else{
as_save("myiframe0","run()");
-
+
}
}
function run()
@@ -1233,15 +1256,15 @@ function run()
function dateAdd(strInterval, num, date){
date = arguments[2] || new Date();
switch (strInterval) {
- case 's' :return new Date(date.getTime() + (1000 * num));
- case 'n' :return new Date(date.getTime() + (60000 * num));
- case 'h' :return new Date(date.getTime() + (3600000 * num));
- case 'd' :return new Date(date.getTime() + (86400000 * num));
- case 'w' :return new Date(date.getTime() + ((86400000 * 7) * num));
- case 'm' :return new Date(date.getFullYear(), (date.getMonth()) + num, date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds());
- case 'y' :return new Date((date.getFullYear() + num), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds());
- }
-}
+ case 's' :return new Date(date.getTime() + (1000 * num));
+ case 'n' :return new Date(date.getTime() + (60000 * num));
+ case 'h' :return new Date(date.getTime() + (3600000 * num));
+ case 'd' :return new Date(date.getTime() + (86400000 * num));
+ case 'w' :return new Date(date.getTime() + ((86400000 * 7) * num));
+ case 'm' :return new Date(date.getFullYear(), (date.getMonth()) + num, date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds());
+ case 'y' :return new Date((date.getFullYear() + num), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds());
+ }
+}
//在input框后设置比例
function setItemRatio(fieldName,unit){
var dwname=0;
@@ -1374,13 +1397,12 @@ function changeFistPlanDate(){
function rentOrRateChange(){
CalcControl.RentOrRateInit();
CalcControl.RentOrRateView();
-
- //document.all("frame_list_knowing").src = document.all("frame_list_knowing").src;
-
- if(count > 0){
- AsControl.RunJavaMethod("com.tenwa.reckon.executor.CreateTransactionExecutor","runDelteKnowing","flowunid=<%=flowunid%>,plannumber=<%=plannumber%>,planCName=<%=planCName%>,calType=<%=calType%>");
- }
+ //document.all("frame_list_knowing").src = document.all("frame_list_knowing").src;
+
+ <%--if(count > 0){--%>
+ <%-- AsControl.RunJavaMethod("com.tenwa.reckon.executor.CreateTransactionExecutor","runDelteKnowing","flowunid=<%=flowunid%>,plannumber=<%=plannumber%>,planCName=<%=planCName%>,calType=<%=calType%>");--%>
+ <%--}--%>
}
@@ -1394,10 +1416,10 @@ function changeSettleMethod3(){
}
<%-- var param="CompClientID=<%=compClientID%>&flowunid=<%=flowunid%>&plannumber=<%=plannumber%>&planCName=<%=planCName%>&IsHistory=<%=ishistory%>&NodeNo=<%=nodeNo%>&calType=<%=calType%>&method="+method;
AsControl.OpenView("/Accounting/LoanSimulation/condition_plan.jsp",param, "frame_list"); --%>
-
+
var rentOrRate ="<%=dwTemp.getData().get("RENT_OR_RATE")%>";//租金推算方式
// document.all("A_Group_calc_config").style.display="none";
- if(rentOrRate == 'knowing_rent'){//已知租金规则 只能固定利率
+ if(rentOrRate == 'knowing_rent'){//已知租金规则 只能固定利率
document.all("A_Group_calc_config").style.display="block";
var param="CompClientID=<%=compClientID%>&flowunid=<%=flowunid%>&plannumber=<%=plannumber%>&planCName=<%=planCName%>&IsHistory=<%=ishistory%>&NodeNo=<%=nodeNo%>&calType=<%=calType%>";
AsControl.OpenView("/Accounting/LoanSimulation/KnowConfigList.jsp",param,"frame_list_knowing");
@@ -1530,7 +1552,7 @@ var fundError={};
var ele_error = document.createElement("li");
var errmsg = fundError[list[ii].element.getAttribute('name')];;
ele_error.innerHTML = "" + errmsg + "";
-
+
if(ii>=iExtCount){
document.getElementById("ul_error_1").appendChild(ele_error);
}else{
@@ -1557,7 +1579,7 @@ var fundError={};
}
catch(e){}
}
-}
+}
jQuery.validator.prototype.showLabel = function(element,message){
var id=element.getAttribute('id');
@@ -1567,36 +1589,5 @@ jQuery.validator.prototype.showLabel = function(element,message){
}
fundError[id]=message;
};
-
- function isSubsection(){
- var isSubsection = getItemValue(0,getRow(),"is_subsection");
- if("yes" == isSubsection){
- showItem(0,"subsection_num",'');
- showItem(0,"subsection_config",'');
- setItemRequired(0,"subsection_num",true);
- setItemRequired(0,"subsection_config",true);
- var subsectionNum = getItemValue(0,getRow(),"subsection_num");
- if(typeof(subsectionNum) == "undefined" || subsectionNum.length == 0 ){
- subsectionNum = "0";
- }
- $("#A_Group_0020").attr("style","display:block;");//显示
- subsection_list.window.saveData(subsectionNum);
- }else{
- showItem(0,"subsection_num",'none');
- showItem(0,"subsection_config",'none');
- setItemRequired(0,"subsection_num",false);
- setItemRequired(0,"subsection_config",false);
- $("#A_Group_0020").attr("style","display:none;");//隐藏
- }
- }
- function subsectionNum(){
- var subsectionNum = getItemValue(0,getRow(),"subsection_num");
- if(typeof(subsectionNum) == "undefined" || subsectionNum.length == 0 ){
- subsectionNum = "0";
- }
- subsection_list.window.saveData(subsectionNum);
- }
-
-
<%@ include file="/Frame/resources/include/include_end.jspf"%>
diff --git a/WebContent/Accounting/LoanSimulation/lbSubsectionTempList.jsp b/WebContent/Accounting/LoanSimulation/lbSubsectionTempList.jsp
deleted file mode 100644
index bd40cb7b3..000000000
--- a/WebContent/Accounting/LoanSimulation/lbSubsectionTempList.jsp
+++ /dev/null
@@ -1,44 +0,0 @@
-<%@ page contentType="text/html; charset=GBK"%>
-<%@ include file="/Frame/resources/include/include_begin_list.jspf"%><%
- /*
- Author: undefined 2021-07-20
- Content:
- History Log:
- */
- String flowunid = CurPage.getParameter("flowunid");
- String projectId = CurPage.getParameter("projectId");
- ASObjectModel doTemp = new ASObjectModel("lbSubsectionTempList");
- ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
- dwTemp.Style="1"; //--设置为Grid风格--
- dwTemp.ReadOnly = "0"; //只读模式
- dwTemp.setPageSize(10);
- dwTemp.genHTMLObjectWindow(flowunid);
-
- //0、是否展示 1、 权限控制 2、 展示类型 3、按钮显示名称 4、按钮解释文字 5、按钮触发事件代码 6、 7、 8、 9、图标,CSS层叠样式 10、风格
- String sButtons[][] = {
- {"false","All","Button","新增","新增","newRecord()","","","","btn_icon_add",""},
- {"false","","Button","详情","详情","viewAndEdit()","","","","btn_icon_detail",""},
- {"false","","Button","删除","删除","if(confirm('确实要删除吗?'))as_delete(0,'alert(getRowCount(0))')","","","","btn_icon_delete",""},
- };
-%><%@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/Frame/page/jspf/include/jsp_head_res_dw.jspf b/WebContent/Frame/page/jspf/include/jsp_head_res_dw.jspf
index 9c9822217..33c380e93 100644
--- a/WebContent/Frame/page/jspf/include/jsp_head_res_dw.jspf
+++ b/WebContent/Frame/page/jspf/include/jsp_head_res_dw.jspf
@@ -2,5 +2,6 @@
+
-
\ No newline at end of file
+
diff --git a/WebContent/WEB-INF/etc/app/component/component-config.xml b/WebContent/WEB-INF/etc/app/component/component-config.xml
index ed29faeb3..630aa8b74 100644
--- a/WebContent/WEB-INF/etc/app/component/component-config.xml
+++ b/WebContent/WEB-INF/etc/app/component/component-config.xml
@@ -1,434 +1,434 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-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-
-
-
-
-
-
-
-
-
\ No newline at end of file
+ -->
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/WebContent/WEB-INF/etc/app/component/component-parameter-config.xml b/WebContent/WEB-INF/etc/app/component/component-parameter-config.xml
index d723735bf..25ee0562e 100644
--- a/WebContent/WEB-INF/etc/app/component/component-parameter-config.xml
+++ b/WebContent/WEB-INF/etc/app/component/component-parameter-config.xml
@@ -1,199 +1,199 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/WebContent/WEB-INF/etc/jbo/jbo_calc.xml b/WebContent/WEB-INF/etc/jbo/jbo_calc.xml
index 56093ba88..14aada50c 100644
--- a/WebContent/WEB-INF/etc/jbo/jbo_calc.xml
+++ b/WebContent/WEB-INF/etc/jbo/jbo_calc.xml
@@ -68,7 +68,7 @@
-
+
@@ -105,7 +105,7 @@
-
+
@@ -385,7 +385,7 @@
-
+
@@ -487,7 +487,7 @@
-
+
@@ -541,7 +541,7 @@
-
+
@@ -592,7 +592,7 @@
-
+
@@ -1499,7 +1499,7 @@
-
+
@@ -1554,7 +1554,7 @@
-
+
@@ -1605,7 +1605,7 @@
-
+
@@ -1664,7 +1664,7 @@
-
+
@@ -1737,7 +1737,7 @@
-
+
@@ -1800,13 +1800,13 @@
-
+
@@ -1869,13 +1869,13 @@
-
+
@@ -2512,7 +2512,7 @@
-
+
@@ -2566,7 +2566,7 @@
-
+
@@ -2984,7 +2984,7 @@
-
+
@@ -3185,7 +3185,7 @@
-
+
@@ -3212,8 +3212,8 @@
-
-
+
+
@@ -3376,7 +3376,7 @@
-
+
@@ -3423,7 +3423,7 @@
-
+
@@ -3453,7 +3453,7 @@
-
+
@@ -3687,7 +3687,7 @@
-
+
@@ -4157,7 +4157,7 @@
-
+
@@ -4236,7 +4236,7 @@
-
+
@@ -4307,7 +4307,7 @@
-
+
@@ -4633,31 +4633,173 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/WebContent/js/decimal/decimal.min.js b/WebContent/js/decimal/decimal.min.js
new file mode 100644
index 000000000..f3afe8a7a
--- /dev/null
+++ b/WebContent/js/decimal/decimal.min.js
@@ -0,0 +1,2 @@
+/* decimal.js v10.2.0 https://github.com/MikeMcl/decimal.js/LICENCE */
+!function(n){"use strict";var h,R,e,o,u=9e15,g=1e9,m="0123456789abcdef",t="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",r="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",c={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-u,maxE:u,crypto:!1},N=!0,f="[DecimalError] ",w=f+"Invalid argument: ",s=f+"Precision limit exceeded",a=f+"crypto unavailable",L=Math.floor,v=Math.pow,l=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,d=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,p=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,b=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,T=1e7,U=7,E=t.length-1,x=r.length-1,y={name:"[object Decimal]"};function M(n){var e,i,t,r=n.length-1,s="",o=n[0];if(0i-1&&(void 0===s[t+1]&&(s[t+1]=0),s[t+1]+=s[t]/i|0,s[t]%=i)}return s.reverse()}y.absoluteValue=y.abs=function(){var n=new this.constructor(this);return n.s<0&&(n.s=1),_(n)},y.ceil=function(){return _(new this.constructor(this),this.e+1,2)},y.comparedTo=y.cmp=function(n){var e,i,t,r,s=this,o=s.d,u=(n=new s.constructor(n)).d,c=s.s,f=n.s;if(!o||!u)return c&&f?c!==f?c:o===u?0:!o^c<0?1:-1:NaN;if(!o[0]||!u[0])return o[0]?c:u[0]?-f:0;if(c!==f)return c;if(s.e!==n.e)return s.e>n.e^c<0?1:-1;for(e=0,i=(t=o.length)<(r=u.length)?t:r;eu[e]^c<0?1:-1;return t===r?0:rthis.d.length-2},y.isNaN=function(){return!this.s},y.isNegative=y.isNeg=function(){return this.s<0},y.isPositive=y.isPos=function(){return 0e&&(e=this.e+1)):e=NaN,e},y.round=function(){var n=this.constructor;return _(new n(this),this.e+1,n.rounding)},y.sine=y.sin=function(){var n,e,i=this,t=i.constructor;return i.isFinite()?i.isZero()?new t(i):(n=t.precision,e=t.rounding,t.precision=n+Math.max(i.e,i.sd())+U,t.rounding=1,i=function(n,e){var i,t=e.d.length;if(t<3)return W(n,2,e,e);i=16<(i=1.4*Math.sqrt(t))?16:0|i,e=e.times(1/J(5,i)),e=W(n,2,e,e);for(var r,s=new n(5),o=new n(16),u=new n(20);i--;)r=e.times(e),e=e.times(s.plus(r.times(o.times(r).minus(u))));return e}(t,z(t,i)),t.precision=n,t.rounding=e,_(2=n.d.length-1&&(i=f<0?-f:f)<=9007199254740991)return r=I(c,u,i,t),n.s<0?new c(1).div(r):_(r,t,s);if((o=u.s)<0){if(ec.maxE+1||e=r.toExpPos):(q(n,1,g),void 0===e?e=r.rounding:q(e,0,8),A(t=_(new r(t),n,e),n<=t.e||t.e<=r.toExpNeg,n)),t.isNeg()&&!t.isZero()?"-"+i:i},y.toSignificantDigits=y.toSD=function(n,e){var i=this.constructor;return void 0===n?(n=i.precision,e=i.rounding):(q(n,1,g),void 0===e?e=i.rounding:q(e,0,8)),_(new i(this),n,e)},y.toString=function(){var n=this,e=n.constructor,i=A(n,n.e<=e.toExpNeg||n.e>=e.toExpPos);return n.isNeg()&&!n.isZero()?"-"+i:i},y.truncated=y.trunc=function(){return _(new this.constructor(this),this.e+1,1)},y.valueOf=y.toJSON=function(){var n=this,e=n.constructor,i=A(n,n.e<=e.toExpNeg||n.e>=e.toExpPos);return n.isNeg()?"-"+i:i};var F=function(){function S(n,e,i){var t,r=0,s=n.length;for(n=n.slice();s--;)t=n[s]*e+r,n[s]=t%i|0,r=t/i|0;return r&&n.unshift(r),n}function Z(n,e,i,t){var r,s;if(i!=t)s=te[r]?1:-1;break}return s}function P(n,e,i,t){for(var r=0;i--;)n[i]-=r,r=n[i](F[c]||0)&&u--,null==i?(N=i=O.precision,t=O.rounding):N=r?i+(n.e-e.e)+1:i,N<0)g.push(1),h=!0;else{if(N=N/a+2|0,c=0,1==M){for(A=A[f=0],N++;(c=s/2&&++y;f=0,(o=Z(A,m,M,w))<0?(v=m[0],M!=w&&(v=v*s+(m[1]||0)),1<(f=v/y|0)?(s<=f&&(f=s-1),1==(o=Z(l=S(A,f,s),m,d=l.length,w=m.length))&&(f--,P(l,Md.maxE?(n.d=null,n.e=NaN):n.en.constructor.maxE?(n.d=null,n.e=NaN):n.er-1;)h[i]=0,i||(++s,h.unshift(1));for(c=h.length;!h[c-1];--c);for(o=0,a="";oc)for(s-=c;s--;)a+="0";else se)return n.length=e,!0}function Q(n){return new this(n).abs()}function X(n){return new this(n).acos()}function Y(n){return new this(n).acosh()}function nn(n,e){return new this(n).plus(e)}function en(n){return new this(n).asin()}function tn(n){return new this(n).asinh()}function rn(n){return new this(n).atan()}function sn(n){return new this(n).atanh()}function on(n,e){n=new this(n),e=new this(e);var i,t=this.precision,r=this.rounding,s=t+4;return n.s&&e.s?n.d||e.d?!e.d||n.isZero()?(i=e.s<0?P(this,t,r):new this(0)).s=n.s:!n.d||e.isZero()?(i=P(this,s,1).times(.5)).s=n.s:i=e.s<0?(this.precision=s,this.rounding=1,i=this.atan(F(n,e,s,1)),e=P(this,s,1),this.precision=t,this.rounding=r,n.s<0?i.minus(e):i.plus(e)):this.atan(F(n,e,s,1)):(i=P(this,s,1).times(0s.maxE?(r.e=NaN,r.d=null):n.e bos = bom.createQuery( "flowunid = :flowunid" ).setParameter( "flowunid", this.flowunid ).getResultList( true );
+ for ( BizObject bo : bos ) {
+ String cleanLeaseRatio = bo.getAttribute( "CLEAN_LEASE_RATIO" ).toString();
+ if ( !"".equals( cleanLeaseRatio ) ) {
+ BigDecimal cleanLeaseMoney;
+ if ( "CarPrice".equals( subsectionConfig ) ) {
+ cleanLeaseMoney = new BigDecimal( cleanLeaseRatio ).multiply( new BigDecimal( equipAmt ) )
+ .divide( new BigDecimal( 100 ), 2, 4 );
+ } else {
+ cleanLeaseMoney = new BigDecimal( cleanLeaseRatio ).multiply( new BigDecimal( cleanLeasemoney ) )
+ .divide( new BigDecimal( 100 ), 2, 4 );
+ }
+ bo.setAttributeValue( "CLEAN_LEASE_MONEY", cleanLeaseMoney.toString() );
+ bom.saveObject( bo );
+ }
+ }
+ } catch ( Exception e ) {
+ e.printStackTrace();
+ tx.rollback();
+ return "ERROR";
+ }
+ return "SUCCESS";
}
public void checkYearRate( ConditionBean cb, TabCalBean tcb, BigDecimal yearRate ) throws BusinessException {
@@ -155,7 +198,7 @@ public class CreateTransactionExecutor implements Transaction {
try {
Map> productRevenues = ProductParamUtil.getProductComponentType( tcb.getProductId(), "PRD0390" );
tcb.setProductRevenues( productRevenues );
-
+
Map> productRates = ProductParamUtil.getProductComponentType(productId, "PRD0350");
Map productRate = productRates.get("product_rate");
String isFixedRate = productRate.get("isFixedRate");
@@ -326,19 +369,19 @@ public class CreateTransactionExecutor implements Transaction {
}
return "success";
}
-
+
/**
* 插入分润计划
* @param splittingRatio,Sqlca
* @return
- * @throws JBOException
+ * @throws JBOException
* @throws Exception
*/
public void insertRentPlan_SP (String splittingRatio,com.amarsoft.awe.util.Transaction Sqlca,String splitType) throws Exception{
BizObjectManager BmLRP=JBOFactory.getBizObjectManager(LC_RENT_PLAN.CLASS_NAME, Sqlca);
BizObjectManager BmLCC=JBOFactory.getBizObjectManager(LC_CALC_CONDITION.CLASS_NAME, Sqlca);
java.text.SimpleDateFormat format = new java.text.SimpleDateFormat("yyyy/MM/dd");
-
+
List BoLRP = BmLRP.createQuery("payment_number=:payment_number order by plan_list").setParameter("payment_number", this.plannumber).getResultList(false);
BizObject boLCC = BmLCC.createQuery("select IRR,CAUTION_MONEY,HANDLING_CHARGE_MONEY from O where payment_number=:payment_number").setParameter("payment_number", this.plannumber).getSingleResult(false);
String irr = boLCC.getAttribute("IRR").toString();
@@ -392,8 +435,8 @@ public class CreateTransactionExecutor implements Transaction {
} finally {
if(ps != null) ps.close();
}
-
-
+
+
}
public String getSplitByProductId(JBOTransaction tx) {
@@ -1372,7 +1415,7 @@ public class CreateTransactionExecutor implements Transaction {
tx.commit();
return "Success";
}
-
+
//校验融资金额是否超额
public String checkMoney()throws Exception{
BigDecimal sumMoney = new BigDecimal("0") ;
@@ -1384,8 +1427,8 @@ public class CreateTransactionExecutor implements Transaction {
sumMoney = sumMoney.setScale(2, BigDecimal.ROUND_HALF_UP);
return sumMoney.toString();
}
-
-
+
+
public String getCalType() {
return calType;
}
diff --git a/calc/com/tenwa/reckon/executor/ManageSubsectionData.java b/calc/com/tenwa/reckon/executor/ManageSubsectionData.java
index a48fd77bf..2f8d07c5f 100644
--- a/calc/com/tenwa/reckon/executor/ManageSubsectionData.java
+++ b/calc/com/tenwa/reckon/executor/ManageSubsectionData.java
@@ -1,66 +1,66 @@
-package com.tenwa.reckon.executor;
-
-import java.util.List;
-
-import com.amarsoft.are.jbo.BizObject;
-import com.amarsoft.are.jbo.BizObjectManager;
-import com.amarsoft.are.jbo.JBOFactory;
-import com.amarsoft.are.jbo.JBOTransaction;
-
-import jbo.app.tenwa.calc.LB_SUBSECTION_INFO_TEMP;
-
-public class ManageSubsectionData {
-
- private String subsectionNumber;
- private String projectId;
- private String flowunid;
-
- public String getSubsectionNumber() {
- return subsectionNumber;
- }
- public void setSubsectionNumber(String subsectionNumber) {
- this.subsectionNumber = subsectionNumber;
- }
- public String getProjectId() {
- return projectId;
- }
- public void setProjectId(String projectId) {
- this.projectId = projectId;
- }
- public String getFlowunid() {
- return flowunid;
- }
- public void setFlowunid(String flowunid) {
- this.flowunid = flowunid;
- }
-
- public String saveSubsection(JBOTransaction tx) throws Exception {
- Integer sn = new Integer(subsectionNumber);
- BizObjectManager lsitManger = JBOFactory.getBizObjectManager(LB_SUBSECTION_INFO_TEMP.CLASS_NAME, tx);
- List lsitList = lsitManger.createQuery(" flowunid=:flowunid ").setParameter("flowunid", flowunid).getResultList(false);
- if( sn >= 0 ) {
- if(lsitList.size()==0 || sn > lsitList.size()) {
- int i = ( lsitList.size()+1 ) ;
- for( ; i<=sn ; i++ ) {
- BizObject lsit = lsitManger.newObject();
- lsit.setAttributeValue("subsection_number", i);
- lsit.setAttributeValue("projectid", projectId);
- lsit.setAttributeValue("flowunid", flowunid);
- lsitManger.saveObject(lsit);
- }
- }else if( sn < lsitList.size()){
- int i = (sn +1);
- for( ; i<= lsitList.size() ; i++ ) {
- BizObject lsit = lsitManger.createQuery("flowunid =:flowunid and subsection_number =:subsectionNumber").setParameter("flowunid", flowunid).setParameter("subsectionNumber", i).getSingleResult(true);
- if(lsit!=null ) {
- lsitManger.deleteObject(lsit);
- }
- }
- }
- }
- return "success";
- }
-
-
-
-}
+//package com.tenwa.reckon.executor;
+//
+//import java.util.List;
+//
+//import com.amarsoft.are.jbo.BizObject;
+//import com.amarsoft.are.jbo.BizObjectManager;
+//import com.amarsoft.are.jbo.JBOFactory;
+//import com.amarsoft.are.jbo.JBOTransaction;
+//
+//import jbo.app.tenwa.calc.LB_SUBSECTION_INFO_TEMP;
+//
+//public class ManageSubsectionData {
+//
+// private String subsectionNumber;
+// private String projectId;
+// private String flowunid;
+//
+// public String getSubsectionNumber() {
+// return subsectionNumber;
+// }
+// public void setSubsectionNumber(String subsectionNumber) {
+// this.subsectionNumber = subsectionNumber;
+// }
+// public String getProjectId() {
+// return projectId;
+// }
+// public void setProjectId(String projectId) {
+// this.projectId = projectId;
+// }
+// public String getFlowunid() {
+// return flowunid;
+// }
+// public void setFlowunid(String flowunid) {
+// this.flowunid = flowunid;
+// }
+//
+// public String saveSubsection(JBOTransaction tx) throws Exception {
+// Integer sn = new Integer(subsectionNumber);
+// BizObjectManager lsitManger = JBOFactory.getBizObjectManager(LB_SUBSECTION_INFO_TEMP.CLASS_NAME, tx);
+// List lsitList = lsitManger.createQuery(" flowunid=:flowunid ").setParameter("flowunid", flowunid).getResultList(false);
+// if( sn >= 0 ) {
+// if(lsitList.size()==0 || sn > lsitList.size()) {
+// int i = ( lsitList.size()+1 ) ;
+// for( ; i<=sn ; i++ ) {
+// BizObject lsit = lsitManger.newObject();
+// lsit.setAttributeValue("subsection_number", i);
+// lsit.setAttributeValue("projectid", projectId);
+// lsit.setAttributeValue("flowunid", flowunid);
+// lsitManger.saveObject(lsit);
+// }
+// }else if( sn < lsitList.size()){
+// int i = (sn +1);
+// for( ; i<= lsitList.size() ; i++ ) {
+// BizObject lsit = lsitManger.createQuery("flowunid =:flowunid and subsection_number =:subsectionNumber").setParameter("flowunid", flowunid).setParameter("subsectionNumber", i).getSingleResult(true);
+// if(lsit!=null ) {
+// lsitManger.deleteObject(lsit);
+// }
+// }
+// }
+// }
+// return "success";
+// }
+//
+//
+//
+//}
diff --git a/calc/com/tenwa/reckon/product/ProductCondition.java b/calc/com/tenwa/reckon/product/ProductCondition.java
index 041967437..2f6161b84 100644
--- a/calc/com/tenwa/reckon/product/ProductCondition.java
+++ b/calc/com/tenwa/reckon/product/ProductCondition.java
@@ -7,6 +7,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Vector;
+import com.amarsoft.are.jbo.BizObjectManager;
import jbo.com.tenwa.lease.comm.CONFIGURATE;
import jbo.prd.BUSINESS_TYPE;
import jbo.sys.CODE_LIBRARY;
@@ -32,13 +33,13 @@ public class ProductCondition {
* @return
* @throws Exception
*/
- public String getProductRules(ASObjectModel doTemp,String productId,Vector vali) throws Exception{
+ public String getProductRules(ASObjectModel doTemp, String productId, Vector vali, String flowunid) throws Exception{
doTemp.setDefaultValue("LEASE_AMT_DATE", DateUtil.getToday());
StringBuilder sb=new StringBuilder();
sb.append("{");
sb.append("'fund':"+getProductFundRules(doTemp, productId,vali));//资金配置项
sb.append(",'grace':"+this.getProductGraceRules(doTemp, productId, vali));//宽限期
- sb.append(",'method':"+this.getProductSettleRules(doTemp, productId));//计算方式
+ sb.append(",'method':"+this.getProductSettleRules(doTemp, productId, flowunid));//计算方式
sb.append(",'incomeNumber':"+this.getIncomeNumber(productId));
sb.append("}");
setRentOrRate(doTemp, productId);//租金推算方法
@@ -50,7 +51,7 @@ public class ProductCondition {
this.getCautionRatio(doTemp, productId);//保证金比例
return sb.toString();
}
-
+
public String getProductRulesBusiness(ASObjectModel doTemp,String productId,Vector vali) throws Exception{
doTemp.setDefaultValue("LEASE_AMT_DATE", DateUtil.getToday());
StringBuilder sb=new StringBuilder();
@@ -68,7 +69,7 @@ public class ProductCondition {
this.getCautionRatio(doTemp, productId);//保证金比例
return sb.toString();
}
-
+
public String getProductRulesApp(List