Merge branch 'release20210831' into dailyfix
# Conflicts: # src_core/com/tenwa/voucher/CreateVoucherProcess/InsertVoucherRentIncome.java
This commit is contained in:
commit
352c3b8315
@ -0,0 +1,228 @@
|
||||
<%@ 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" );
|
||||
doTemp.setHtmlEvent( "CLEAN_LEASE_MONEY", "onblur", "changeCleanLeaseMoney" );
|
||||
doTemp.setHtmlEvent( "INCOME_NUMBER", "onchange", "changeIncomeNumber" );
|
||||
String discountCalcMethod = Sqlca.getString("select DISCOUNT_CALC_METHOD from LC_CALC_SUBSECTION_INFO_TEMP where FLOWUNID='"+flowunid+"'");
|
||||
if(discountCalcMethod != null){
|
||||
if(discountCalcMethod.equals("1")){
|
||||
doTemp.setReadOnly("DISCOUNT",true);
|
||||
doTemp.setReadOnly("DISCOUNT_RATE",false);
|
||||
}else if (discountCalcMethod.equals("2")){
|
||||
doTemp.setReadOnly("DISCOUNT",false);
|
||||
doTemp.setReadOnly("DISCOUNT_RATE",true);
|
||||
}else if (discountCalcMethod.equals("3")){//固定值,对应的值改为只读
|
||||
doTemp.setReadOnly("DISCOUNT_RATE",true);
|
||||
doTemp.setReadOnly("FINANCING_RATE",true);
|
||||
doTemp.setReadOnly("INCOME_NUMBER",true);
|
||||
doTemp.setReadOnly("DISCOUNT",true);
|
||||
}
|
||||
}
|
||||
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",""},
|
||||
{"true","","Button","详情","保存","viewAndEdit()","","","","btn_icon_detail",""},
|
||||
};
|
||||
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
|
||||
<script type="text/javascript">
|
||||
function changeDiscount() {
|
||||
var discountCalcMethod = getItemValue( 0, getRow(), 'DISCOUNT_CALC_METHOD' );
|
||||
var discount = getItemValue( 0, getRow(), 'DISCOUNT' );
|
||||
if ( '2' === discountCalcMethod ) {
|
||||
var maximumDiscount = getItemValue( 0, getRow(), 'MAXIMUM_DISCOUNT' );
|
||||
if ( discount ) {
|
||||
if ( Decimal( discount ).gt( maximumDiscount ) ) {
|
||||
alert( '贴息金额超出最大贴息金额,请重新输入' );
|
||||
setItemValue( 0, getRow(), 'DISCOUNT', '' );
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if ( discount ) {
|
||||
alert( '贴息计算方式为根据利率计算金额,不需要输入贴息金额' );
|
||||
setItemValue( 0, getRow(), 'DISCOUNT', '' );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function changeDiscountRate() {
|
||||
var discountCalcMethod = getItemValue( 0, getRow(), 'DISCOUNT_CALC_METHOD' );
|
||||
var discountRate = getItemValue( 0, getRow(), 'DISCOUNT_RATE' );
|
||||
if ( '2' === discountCalcMethod ) {
|
||||
if ( discountRate ) {
|
||||
alert( '贴息计算方式为根据金额计算利率,不需要输入产品利率' );
|
||||
setItemValue( 0, getRow(), 'DISCOUNT_RATE', '' );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function changeCleanLeaseRatio() {
|
||||
var subsectionConfig = parent.getItemValue( 0, 0, 'SUBSECTION_CONDIG' );
|
||||
var equipAmt = parent.getItemValue( 0, 0, 'EQUIP_AMT' );
|
||||
var cleanLeaseMoney = parent.getItemValue( 0, 0, 'CLEAN_LEASE_MONEY' );
|
||||
var cleanLeaseRatio = getItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO' );
|
||||
if ( subsectionConfig ) {
|
||||
var fcleanLeaseMoney ;
|
||||
if ( 'CarPrice' === subsectionConfig ) {
|
||||
fcleanLeaseMoney = Decimal( equipAmt ).mul( cleanLeaseRatio ).div( 100 ).toFixed( 2 );
|
||||
} else {
|
||||
fcleanLeaseMoney = Decimal( cleanLeaseMoney ).mul( cleanLeaseRatio ).div( 100 ).toFixed( 2 )
|
||||
}
|
||||
var maxLeaseMoney = getItemValue( 0, getRow(), 'MAX_LEASE_MONEY' ) ;
|
||||
var minLeaseMoney = getItemValue( 0, getRow(), 'MIN_LEASE_MONEY' );
|
||||
if(typeof(fcleanLeaseMoney)!="undefined" && fcleanLeaseMoney.length!=0 && (Number(fcleanLeaseMoney) > Number(maxLeaseMoney) || Number(fcleanLeaseMoney) < Number(minLeaseMoney))){
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_MONEY', '');
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO', '');
|
||||
alert("该段的融资金额不在产品配置的区间内,请检查!");
|
||||
return
|
||||
}
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_MONEY', fcleanLeaseMoney);
|
||||
} else {
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_MONEY', '' );
|
||||
}
|
||||
}
|
||||
|
||||
function changeCleanLeaseMoney() {
|
||||
var subsectionConfig = parent.getItemValue( 0, 0, 'SUBSECTION_CONDIG' );
|
||||
var equipAmt = parent.getItemValue( 0, 0, 'EQUIP_AMT' );
|
||||
var cleanLeaseMoney = parent.getItemValue( 0, 0, 'CLEAN_LEASE_MONEY' );
|
||||
var clm = getItemValue( 0, getRow(), 'CLEAN_LEASE_MONEY' );
|
||||
var maxLeaseMoney = getItemValue( 0, getRow(), 'MAX_LEASE_MONEY' );
|
||||
var minLeaseMoney = getItemValue( 0, getRow(), 'MIN_LEASE_MONEY' );
|
||||
if(typeof(clm)!="undefined" && clm.length!=0 && ( Number(clm) > Number(maxLeaseMoney) || Number(clm) < Number(minLeaseMoney) )){
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_MONEY', '');
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO', '');
|
||||
alert("该段的融资金额不在产品配置的区间内,请检查!");
|
||||
return
|
||||
}
|
||||
if ( subsectionConfig ) {
|
||||
if ( 'CarPrice' === subsectionConfig ) {
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO', Decimal( clm ).div( equipAmt ).mul( 100 ).toFixed( 2 ) );
|
||||
} else {
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO', Decimal( clm ).div( cleanLeaseMoney ).mul( 100 ).toFixed( 2 ) );
|
||||
}
|
||||
} else {
|
||||
setItemValue( 0, getRow(), 'CLEAN_LEASE_RATIO', '' );
|
||||
}
|
||||
}
|
||||
|
||||
function save() {
|
||||
var rowCount = getRowCount( 0 );
|
||||
// var allRatio = Decimal( 0 );
|
||||
var clmCheck = Decimal( 0 );
|
||||
for ( var i = 0; i < rowCount; i ++ ) {
|
||||
// var cleanLeaseRatio = getItemValue( 0, i, 'CLEAN_LEASE_RATIO' );
|
||||
var cleanLeaseMoney = getItemValue( 0, i, 'CLEAN_LEASE_MONEY' );
|
||||
if ( cleanLeaseMoney ) {
|
||||
clmCheck = clmCheck.add( cleanLeaseMoney );
|
||||
}
|
||||
|
||||
if ( '' === cleanLeaseMoney ) {
|
||||
alert( '请选择分段配置' );
|
||||
return;
|
||||
}
|
||||
var discountCalcMethod = getItemValue( 0, i, 'DISCOUNT_CALC_METHOD' );
|
||||
if ( '2' === discountCalcMethod ) {
|
||||
var discount = getItemValue( 0, i, 'DISCOUNT' );
|
||||
if ( '' === discount ) {
|
||||
alert( '请填写第' + ( i + 1 ) + '行贴息金额' );
|
||||
return;
|
||||
}else{
|
||||
var ifd = getItemValue( 0, i, 'IS_FIXED_DISCOUNT' );
|
||||
if(ifd=="N"){
|
||||
var mind = getItemValue( 0, i, 'MINIMUM_DISCOUNT' );
|
||||
var maxd = getItemValue( 0, i, 'MAXIMUM_DISCOUNT' );
|
||||
if( Number(discount) < Number(mind) || Number(discount)>Number(maxd) ){
|
||||
alert( '请填写第' + ( i + 1 ) + '行贴息金额不在产品配置的区间内,请检查!' );
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
var discountRate = getItemValue( 0, i, 'DISCOUNT_RATE' );
|
||||
if ( '' === discountRate ) {
|
||||
alert( '请填写第' + ( i + 1 ) + '行产品利率' );
|
||||
return;
|
||||
}
|
||||
var financingRate = getItemValue( 0, i, 'FINANCING_RATE' );
|
||||
if ( '' === financingRate ) {
|
||||
alert( '请填写第' + ( i + 1 ) + '行融资利率' );
|
||||
return;
|
||||
}
|
||||
}
|
||||
var incomeNumber = getItemValue( 0, i, 'INCOME_NUMBER' );
|
||||
if ( '' === incomeNumber ) {
|
||||
alert( '请填写第' + ( i + 1 ) + '行期次' );
|
||||
return;
|
||||
}
|
||||
}
|
||||
var parCLM = Decimal (parent.getItemValue( 0, 0, 'CLEAN_LEASE_MONEY' ) );
|
||||
if ( parseFloat(clmCheck) != parseFloat(parCLM) ) {
|
||||
alert( '融资金额和综合融资不相等,请检查!' );
|
||||
return;
|
||||
}
|
||||
as_save( 0 );
|
||||
}
|
||||
function viewAndEdit(){
|
||||
var subsectionNumber = getItemValue( 0, getRow(), 'SUBSECTION_NUMBER' );
|
||||
AsDialog.PopView("/Accounting/LoanSimulation/LCSubsectionRentPlanTempList.jsp","flowunid=<%=flowunid%>&subsectionNumber="+subsectionNumber,"resizable=yes;dialogWidth=1250px;dialogHeight=600px;center:yes;status:no;statusbar:no",function(){reloadSelf();},"详细信息");
|
||||
}
|
||||
|
||||
function afterSearch(){
|
||||
for(var i=0;i<getRowCount(0);i++){
|
||||
var ioin = getItemValue( 0, i, 'IS_ONLYREAD_INCOME_NUMBER' );
|
||||
if(ioin=="Y"){
|
||||
var select = $("select[id^=INPUT][id*=INCOME_NUMBER_"+i+"]");
|
||||
var div = select.parent('div');
|
||||
select.remove();
|
||||
var incomeNumber = getItemValue( 0, i, 'INCOME_NUMBER' );
|
||||
var spanObj = document.createElement('span');
|
||||
spanObj.innerText = incomeNumber ;
|
||||
div.append(spanObj);
|
||||
}
|
||||
var iulmr = getItemValue( 0, i, 'IS_UPDATE_LEASE_MONEY_RATIO' );
|
||||
if(iulmr=="Y"){
|
||||
$("input[id*=FINANCING_RATE_"+i+"]").attr('readonly',true);
|
||||
$("input[id*=FINANCING_RATE_"+i+"]").css('border','0');
|
||||
}
|
||||
|
||||
var ifdr = getItemValue( 0, i, 'IS_FIXED_DISCOUNT_RATE' );
|
||||
if(ifdr=="Y"){
|
||||
$("input[id*=DISCOUNT_RATE_"+i+"]").attr('readonly',true);
|
||||
$("input[id*=DISCOUNT_RATE_"+i+"]").css('border','0');
|
||||
}
|
||||
|
||||
var ifd = getItemValue( 0, i, 'IS_FIXED_DISCOUNT' );
|
||||
if(ifd =="Y"){
|
||||
$("input[id*=DISCOUNT_"+i+"]").attr('readonly',true);
|
||||
$("input[id*=DISCOUNT_"+i+"]").css('border','0');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function changeIncomeNumber(){
|
||||
var inumber = getItemValue( 0, getRow(), 'INCOME_NUMBER' );
|
||||
var maxIn = getItemValue( 0, getRow(), 'MAX_INCOME_NUMBER' );
|
||||
var minIn = getItemValue( 0, getRow(), 'MIN_INCOME_NUMBER' );
|
||||
if( Number(inumber) > Number(maxIn) || Number(inumber) < Number(minIn)){
|
||||
alert("该段的期次不在产品配置的区间内,请检查!");
|
||||
setItemValue( 0, getRow(), 'INCOME_NUMBER', '');
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -0,0 +1,37 @@
|
||||
<%@ page contentType="text/html; charset=GBK"%>
|
||||
<%@ include file="/Frame/resources/include/include_begin_list.jspf"%><%
|
||||
/*
|
||||
Author: undefined 2021-07-28
|
||||
Content:
|
||||
History Log:
|
||||
*/
|
||||
ASObjectModel doTemp = new ASObjectModel("LCSubsectionRentPlanTempList");
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
|
||||
dwTemp.Style="1"; //--设置为Grid风格--
|
||||
dwTemp.ReadOnly = "1"; //只读模式
|
||||
dwTemp.setPageSize((pageSize==null||"undefined".equals(pageSize))?24:Integer.parseInt(pageSize));
|
||||
dwTemp.genHTMLObjectWindow(CurPage.getParameter("flowunid")+","+CurPage.getParameter("subsectionNumber"));
|
||||
|
||||
//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"%>
|
||||
<script type="text/javascript">
|
||||
function newRecord(){
|
||||
var sUrl = "";
|
||||
AsControl.OpenView(sUrl,'','_self','');
|
||||
}
|
||||
function viewAndEdit(){
|
||||
var sUrl = "";
|
||||
var sPara = getItemValue(0,getRow(0),'SerialNo');
|
||||
if(typeof(sPara)=="undefined" || sPara.length==0 ){
|
||||
alert("参数不能为空!");
|
||||
return ;
|
||||
}
|
||||
AsControl.OpenView(sUrl,'SerialNo=' +sPara ,'_self','');
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -18,6 +18,7 @@
|
||||
<%@ include file="/Frame/resources/include/include_begin_info.jspf"%>
|
||||
<%
|
||||
/*获取参数*/
|
||||
String flowNo = CurPage.getParameter("FlowNo");
|
||||
String flowunid = CurPage.getParameter("FlowUnid");
|
||||
String plannumber=CurPage.getParameter("plannumber");
|
||||
String productId=CurPage.getParameter("ProductId");
|
||||
@ -40,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);
|
||||
@ -86,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<String, Map<String, String>> productRates = ProductParamUtil.getProductComponentType(productId, "PRD0350");
|
||||
@ -107,7 +108,7 @@
|
||||
}
|
||||
if("02".equals(termType)){
|
||||
doTemp.setColumnAttribute("INCOME_NUMBER", "coleditstyle", "1");
|
||||
|
||||
|
||||
}
|
||||
if("N".equals(isFixedRate)){
|
||||
doTemp.setReadOnly("YEAR_RATE", false);
|
||||
@ -122,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<String, Map<String, String>> ProductRevenue = ProductParamUtil.getProductComponentType(productId, "PRD0390");
|
||||
Map<String, String> bondAndPayments = ProductRevenue.get("bondAndPayments");
|
||||
bondAndPaymentsMin = bondAndPayments.get("bondAndPayments-MIN");
|
||||
@ -149,6 +150,7 @@
|
||||
doTemp.setHtmlEvent("FIRST_PLAN_DATE", "onchange", "changeFistPlanDate");//第一期计划日期
|
||||
doTemp.setHtmlEvent("CORPUS_RATIO", "onchange", "changeCorpusRatio");//期限内本金比例
|
||||
doTemp.setHtmlEvent("EQUIP_AMT", "onchange", "changgeCompare");//车价
|
||||
doTemp.setHtmlEvent("SUBSECTION_CONDIG", "onchange", "changeSubsectionConfig");//车价
|
||||
/*设置字段事件*/
|
||||
|
||||
/*设置模板属性*/
|
||||
@ -156,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)){
|
||||
@ -171,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);
|
||||
}
|
||||
@ -185,27 +187,28 @@
|
||||
doTemp.setDataQueryClass("com.tenwa.lease.flow.flowarchive.calcarchive.CalcCondtionInfoArachiveShow");//如果是历史则新显示历史数据
|
||||
} */
|
||||
/*设置模板属性*/
|
||||
|
||||
|
||||
/*设置页面属性*/
|
||||
CurPage.getCurComp().setAttribute("RightType", null);
|
||||
Parameter p=new Parameter("plannumber",plannumber);
|
||||
Vector<Parameter> 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.setVisible("DISCOUNT_INTEREST", 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";//只读模式
|
||||
@ -219,13 +222,15 @@
|
||||
dwTemp.setAttr("showRatio", true);
|
||||
dwTemp.genHTMLObjectWindow(flowunid);
|
||||
CurPage.getCurComp().setAttribute("RightType", RightType);
|
||||
|
||||
|
||||
String compClientID = request.getParameter("CompClientID");
|
||||
dwTemp.replaceColumn("condition_plan", "<iframe type='iframe' id='frame_list' name=\"frame_list\" width=\"100%\" height=\"600px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/condition_plan.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"&NodeNo="+nodeNo+"&RightType="+RightType+"&ProductId="+productId+"&calType="+calType+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
//dwTemp.replaceColumn("even_subsection", "<iframe type='iframe' id='frame_even_break' name=\"frame_even_subsection\" width=\"100%\" height=\"300px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/subsection/LCCalcSubsectionList.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"&NodeNo="+nodeNo+"&RightType="+RightType+"&calType="+calType+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
dwTemp.replaceColumn("condition_plan", "<iframe type='iframe' id='frame_list' name=\"frame_list\" width=\"100%\" height=\"600px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/condition_plan.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"&NodeNo="+nodeNo+"&RightType="+RightType+"&ProductId="+productId+"&calType="+calType+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
//dwTemp.replaceColumn("even_subsection", "<iframe type='iframe' id='frame_even_break' name=\"frame_even_subsection\" width=\"100%\" height=\"300px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/subsection/LCCalcSubsectionList.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"&NodeNo="+nodeNo+"&RightType="+RightType+"&calType="+calType+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
//dwTemp.replaceColumn("knowing_config", "<iframe type='iframe' id='frame_list_knowing' name=\"frame_list_knowing\" width=\"100%\" height=\"400px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/KnowConfigList.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"NodeNo="+nodeNo+"&RightType="+RightType+"&calType="+calType+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
dwTemp.replaceColumn("subsection_info", "<iframe type='iframe' id='subsection_list' name=\"subsection_list\" width=\"100%\" height=\"200px\" frameborder=\"0\" src=\""+sWebRootPath+"/Accounting/LoanSimulation/LCCalcSubsectionInfoTempList.jsp?CompClientID="+compClientID+"&flowunid="+flowunid+"&plannumber="+plannumber+"&planCName="+planCName+"&IsHistory="+ishistory+"&NodeNo="+nodeNo+"&RightType="+RightType+"&ProductId="+productId+"&calType="+calType+"&projectId="+projectId+"\"></iframe>", CurPage.getObjectWindowOutput());
|
||||
|
||||
String businessDate = DateHelper.getBusinessDate();
|
||||
|
||||
|
||||
//获取对应车辆指导价
|
||||
BizObject bo1 = JBOFactory.createBizObjectQuery(LB_EQUIPMENT_CAR_TEMP.CLASS_NAME,"PROJECT_ID=:projectId")
|
||||
.setParameter("projectId",projectId).getSingleResult(false);
|
||||
@ -253,7 +258,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){
|
||||
@ -288,11 +293,11 @@ $(function(){
|
||||
if(inco[value]==1){
|
||||
$("#INCOME_NUMBER").append(this);
|
||||
}
|
||||
});
|
||||
});
|
||||
$("#INCOME_NUMBER").val(inerNumber);
|
||||
|
||||
|
||||
count++;
|
||||
}else{
|
||||
}else{
|
||||
changeSettleMethod3();
|
||||
}
|
||||
// getRatioByMoney(getObj(0, "EQUIP_AMT"));
|
||||
@ -303,10 +308,25 @@ $(function(){
|
||||
}
|
||||
var nominalPrice = "<%=nominalPrice%>" ;
|
||||
var carNum = parseInt("<%=carNum%>");
|
||||
setItemValue( 0, 0, 'NOMINAL_PRICE', Number(nominalPrice)*carNum );
|
||||
|
||||
var flowNo = "<%=flowNo%>";
|
||||
if( "BusinessApplyFlow"==flowNo || "BusinessChangeFlow" == flowNo ){
|
||||
setItemValue( 0, 0, 'NOMINAL_PRICE', Number(nominalPrice)*carNum );
|
||||
}
|
||||
});
|
||||
|
||||
function changeSubsectionConfig() {
|
||||
var settleMethod = getItemValue( 0, 0, 'SETTLE_METHOD' );
|
||||
var subsectionConfig = getItemValue( 0, 0, 'SUBSECTION_CONDIG' );
|
||||
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' );
|
||||
@ -360,7 +380,7 @@ function importCustomerQuot(){
|
||||
var param2="FlowUnid=<%=flowunid%>&calType=<%=calType%>&plannumber=<%=plannumber%>";
|
||||
AsControl.OpenView("/Accounting/LoanSimulation/LoanBasicInfo.jsp",param2, "_self");
|
||||
},"请选择客户报价",'');
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -426,7 +446,7 @@ CalcControl.InitStartDate=function(){
|
||||
break;
|
||||
}
|
||||
//是按起租日计算的情况,直接读取当前日期
|
||||
if(calcRules["method"][methodName]["DefaultDueDay"] != "02") {
|
||||
if( calcRules["method"][methodName]["DefaultDueDay"] && calcRules["method"][methodName]["DefaultDueDay"] != "02") {
|
||||
rentDay = calcRules["method"][methodName]["ActualDay"];
|
||||
}
|
||||
|
||||
@ -471,7 +491,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'));
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -552,7 +572,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'){
|
||||
@ -572,7 +592,7 @@ CalcControl.SettleMethodView=function(){
|
||||
CalcControl.RentOrRateView();
|
||||
setItemRequired(0,"YEAR_RATE",true);
|
||||
}
|
||||
|
||||
|
||||
//日期
|
||||
//计划日期
|
||||
var plan = "";
|
||||
@ -660,8 +680,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");
|
||||
@ -700,7 +725,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");//租金推算方式
|
||||
@ -711,22 +736,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);
|
||||
@ -799,19 +824,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();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -831,8 +855,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");
|
||||
|
||||
@ -874,7 +899,19 @@ function changeSettleMethod2(){
|
||||
});
|
||||
$("#INCOME_NUMBER_YEAR").val(incomeValue);
|
||||
}
|
||||
|
||||
document.all( 'A_Group_0020' ).style.display = 'none';
|
||||
showItem(0,"SUBSECTION_CONDIG",'none');
|
||||
showItem(0,"COMPREHENSIVE_RATE",'none');
|
||||
if ( settleMethod === 'segmented_financing' ) {
|
||||
showItem(0,"SUBSECTION_CONDIG",'block');
|
||||
showItem(0,"COMPREHENSIVE_RATE",'block');
|
||||
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_CONDIG', true );
|
||||
setItemRequired( 0, 'INCOME_NUMBER', false );
|
||||
setItemRequired( 0, 'YEAR_RATE', false );
|
||||
}
|
||||
}
|
||||
|
||||
function changeRateType(){
|
||||
@ -883,10 +920,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");
|
||||
@ -909,7 +946,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") {
|
||||
@ -944,11 +981,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;
|
||||
@ -957,7 +994,7 @@ function getRatioByMoney(e){
|
||||
}else{
|
||||
money=equipAmt;
|
||||
}
|
||||
|
||||
|
||||
if(fundRules[key]["ratioType"]=="InputMode03"){//互算
|
||||
if(e.id==key){
|
||||
if(Number(equipAmt)!=0){
|
||||
@ -981,7 +1018,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"){
|
||||
@ -1052,6 +1089,21 @@ function changeCorpusRatio(){
|
||||
}
|
||||
|
||||
function saveRecord(sPostEvents){
|
||||
var settleMethod=getItemValue(0,0,"SETTLE_METHOD");
|
||||
if(settleMethod == 'segmented_financing'){
|
||||
var subsectionCondig=getItemValue(0,0,"SUBSECTION_CONDIG");
|
||||
if(typeof(subsectionCondig) == "undefined" || subsectionCondig.length == 0 ){
|
||||
alert("请先选择分段配置信息!");
|
||||
return ;
|
||||
}
|
||||
var equipAmt=getItemValue(0,0,"EQUIP_AMT");
|
||||
var cleanLeaseMoney=getItemValue(0,0,"CLEAN_LEASE_MONEY");
|
||||
var checkSubsectionInfo= AsControl.RunJavaMethod("com.tenwa.reckon.check.SubsectionCheck","checkSubsectionInfo","flowUnid=<%=flowunid%>"+",equipAmt="+equipAmt+",cleanLeaseMoney="+cleanLeaseMoney+",subsectionCondig="+subsectionCondig);
|
||||
if(checkSubsectionInfo != "success"){
|
||||
alert(checkSubsectionInfo);
|
||||
return ;
|
||||
}
|
||||
}
|
||||
if(getItemValue(0,0,"PURCHASE_TAX") < 0){
|
||||
alert("购置税不能小于0");
|
||||
return;
|
||||
@ -1089,63 +1141,65 @@ function saveRecord(sPostEvents){
|
||||
alert('融资额需大于0 !!!');
|
||||
return ;
|
||||
}
|
||||
var incomeNumebr = getItemValue(0,getRow(),"INCOME_NUMBER");
|
||||
if(incomeNumebr && Number(incomeNumebr) <= 0){
|
||||
alert('还租次数需大于0 !!!');
|
||||
return ;
|
||||
}
|
||||
|
||||
var termMin = parseInt("<%=termMin%>");
|
||||
var termMax = parseInt("<%=termMax%>");
|
||||
var incomeNumber = parseInt(getItemValue(0,0,"INCOME_NUMBER"));
|
||||
if("02"=="<%=termType%>"){
|
||||
if(incomeNumber<termMin){
|
||||
alert("期数不能小于"+termMin);
|
||||
return;
|
||||
}
|
||||
if(incomeNumber>termMax){
|
||||
alert("期数不能大于"+termMax);
|
||||
return;
|
||||
}
|
||||
}
|
||||
//校验年利率是否合法
|
||||
var isFixedRate = "<%=isFixedRate%>";
|
||||
var yearRae = getItemValue(0,0,"YEAR_RATE");
|
||||
if("N" == isFixedRate && yearRae > 0 ){
|
||||
var rateTermMin = "<%=rateTermMin%>";
|
||||
var rateTermMax = "<%=rateTermMax%>";
|
||||
console.log(rateTermMin +"===" +yearRae+"====" +rateTermMax);
|
||||
console.log(rateTermMin > yearRae);
|
||||
console.log(Number(yearRae) > Number(rateTermMax));
|
||||
if(Number(rateTermMin) > Number(yearRae) || Number(yearRae) > Number(rateTermMax)){
|
||||
alert("年利率必须大于等于:"+rateTermMin+",并且小于等于:"+rateTermMax);
|
||||
return;
|
||||
}
|
||||
}
|
||||
//贷款比例不能大于产品配置
|
||||
var cleanLeaseMoney=eval(getItemValue(0,0,"CLEAN_LEASE_MONEY"));//融资额
|
||||
var EQUIP_AMT=eval(getItemValue(0,0,"EQUIP_AMT"));
|
||||
var LeaseMoneyRatio = Number(cleanLeaseMoney/EQUIP_AMT*100).toFixed(6);
|
||||
if(calcRules["fund"]["CLEAN_LEASE_MONEY"]){
|
||||
var productCleanLeaseMoneyRatioMax = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["LeaseMoneyRatio"]["max"]);//贷款比例上限
|
||||
var productCleanLeaseMoneyRatioMin = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["LeaseMoneyRatio"]["min"]);//贷款比例下限
|
||||
var productCleanLeaseMoneyMax = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["max"]);//融资额上限
|
||||
var productCleanLeaseMoneyMin = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["min"]);//融资额下限
|
||||
if((LeaseMoneyRatio<productCleanLeaseMoneyRatioMin)&&(productCleanLeaseMoneyRatioMin!=null)&&(productCleanLeaseMoneyRatioMin!="")){
|
||||
AsDebug.showMessage("提示","综合融资额比例不能小于"+productCleanLeaseMoneyRatioMin+"%","","",true);
|
||||
if(settleMethod != 'segmented_financing') {
|
||||
var incomeNumebr = getItemValue(0,getRow(),"INCOME_NUMBER");
|
||||
if(incomeNumebr && Number(incomeNumebr) <= 0){
|
||||
alert('还租次数需大于0 !!!');
|
||||
return ;
|
||||
}
|
||||
if((LeaseMoneyRatio>productCleanLeaseMoneyRatioMax)&&(productCleanLeaseMoneyRatioMax!=null)&&(productCleanLeaseMoneyRatioMax!="")){
|
||||
AsDebug.showMessage("提示","综合融资额比例不能大于"+productCleanLeaseMoneyRatioMax+"%","","",true);
|
||||
return ;
|
||||
var termMin = parseInt("<%=termMin%>");
|
||||
var termMax = parseInt("<%=termMax%>");
|
||||
var incomeNumber = parseInt(getItemValue(0, 0, "INCOME_NUMBER"));
|
||||
if ("02" == "<%=termType%>") {
|
||||
if (incomeNumber < termMin) {
|
||||
alert("期数不能小于" + termMin);
|
||||
return;
|
||||
}
|
||||
if (incomeNumber > termMax) {
|
||||
alert("期数不能大于" + termMax);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if((cleanLeaseMoney<productCleanLeaseMoneyMin)&&(productCleanLeaseMoneyMin!=null)&&(productCleanLeaseMoneyMin!="")){
|
||||
AsDebug.showMessage("提示","融资额不能小于"+productCleanLeaseMoneyMin,"","",true);
|
||||
return ;
|
||||
//校验年利率是否合法
|
||||
var isFixedRate = "<%=isFixedRate%>";
|
||||
var yearRae = getItemValue(0, 0, "YEAR_RATE");
|
||||
if ("N" == isFixedRate && yearRae > 0) {
|
||||
var rateTermMin = "<%=rateTermMin%>";
|
||||
var rateTermMax = "<%=rateTermMax%>";
|
||||
console.log(rateTermMin + "===" + yearRae + "====" + rateTermMax);
|
||||
console.log(rateTermMin > yearRae);
|
||||
console.log(Number(yearRae) > Number(rateTermMax));
|
||||
if (Number(rateTermMin) > Number(yearRae) || Number(yearRae) > Number(rateTermMax)) {
|
||||
alert("年利率必须大于等于:" + rateTermMin + ",并且小于等于:" + rateTermMax);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if((cleanLeaseMoney>productCleanLeaseMoneyMax)&&(productCleanLeaseMoneyMax!=null)&&(productCleanLeaseMoneyMax!="")){
|
||||
AsDebug.showMessage("提示","融资额不能大于"+productCleanLeaseMoneyMax,"","",true);
|
||||
return ;
|
||||
|
||||
//贷款比例不能大于产品配置
|
||||
var cleanLeaseMoney=eval(getItemValue(0,0,"CLEAN_LEASE_MONEY"));//融资额
|
||||
var EQUIP_AMT=eval(getItemValue(0,0,"EQUIP_AMT"));
|
||||
var LeaseMoneyRatio = Number(cleanLeaseMoney/EQUIP_AMT*100).toFixed(6);
|
||||
if(calcRules["fund"]["CLEAN_LEASE_MONEY"]){
|
||||
var productCleanLeaseMoneyRatioMax = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["LeaseMoneyRatio"]["max"]);//贷款比例上限
|
||||
var productCleanLeaseMoneyRatioMin = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["LeaseMoneyRatio"]["min"]);//贷款比例下限
|
||||
var productCleanLeaseMoneyMax = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["max"]);//融资额上限
|
||||
var productCleanLeaseMoneyMin = eval(calcRules["fund"]["CLEAN_LEASE_MONEY"]["min"]);//融资额下限
|
||||
if((LeaseMoneyRatio<productCleanLeaseMoneyRatioMin)&&(productCleanLeaseMoneyRatioMin!=null)&&(productCleanLeaseMoneyRatioMin!="")){
|
||||
AsDebug.showMessage("提示","综合融资额比例不能小于"+productCleanLeaseMoneyRatioMin+"%","","",true);
|
||||
return ;
|
||||
}
|
||||
if((LeaseMoneyRatio>productCleanLeaseMoneyRatioMax)&&(productCleanLeaseMoneyRatioMax!=null)&&(productCleanLeaseMoneyRatioMax!="")){
|
||||
AsDebug.showMessage("提示","综合融资额比例不能大于"+productCleanLeaseMoneyRatioMax+"%","","",true);
|
||||
return ;
|
||||
}
|
||||
if((cleanLeaseMoney<productCleanLeaseMoneyMin)&&(productCleanLeaseMoneyMin!=null)&&(productCleanLeaseMoneyMin!="")){
|
||||
AsDebug.showMessage("提示","融资额不能小于"+productCleanLeaseMoneyMin,"","",true);
|
||||
return ;
|
||||
}
|
||||
if((cleanLeaseMoney>productCleanLeaseMoneyMax)&&(productCleanLeaseMoneyMax!=null)&&(productCleanLeaseMoneyMax!="")){
|
||||
AsDebug.showMessage("提示","融资额不能大于"+productCleanLeaseMoneyMax,"","",true);
|
||||
return ;
|
||||
}
|
||||
}
|
||||
}
|
||||
var startDate=getItemValue(0,getRow(),"START_DATE");
|
||||
@ -1159,7 +1213,7 @@ function saveRecord(sPostEvents){
|
||||
alert("第一期租金计划日期不能小于起租日!");
|
||||
return ;
|
||||
}
|
||||
|
||||
|
||||
//已知本金已知租金,判断保存后的租金和本地是否跟净融资额匹配?
|
||||
var rentOrRate = getItemValue(0,getRow(),"RENT_OR_RATE");
|
||||
var cleanLeaseMoney = getItemValue(0,getRow(),"CLEAN_LEASE_MONEY");
|
||||
@ -1194,16 +1248,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()
|
||||
@ -1215,6 +1269,7 @@ function run()
|
||||
setItemValue(0,getRow(),p.toUpperCase(),result.info[p]);
|
||||
}
|
||||
}
|
||||
subsection_list.window.reloadSelf();
|
||||
if(result.message){
|
||||
alert(result.message);
|
||||
}
|
||||
@ -1223,15 +1278,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;
|
||||
@ -1364,13 +1419,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%>");--%>
|
||||
<%--}--%>
|
||||
}
|
||||
|
||||
|
||||
@ -1384,10 +1438,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");
|
||||
@ -1491,6 +1545,15 @@ function changeSettleMethod3(){
|
||||
//setItemRequired(0,"RATE",false);
|
||||
//setItemRequired(0,"ADDITIONAL_RATE",false);
|
||||
}
|
||||
var settleMethod=getItemValue(0,0,"SETTLE_METHOD");
|
||||
document.all( 'A_Group_0020' ).style.display = 'none';
|
||||
showItem(0,"SUBSECTION_CONDIG",'none');
|
||||
if ( settleMethod === 'segmented_financing' ) {
|
||||
showItem(0,"SUBSECTION_CONDIG",'block');
|
||||
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' );
|
||||
}
|
||||
}
|
||||
var ischeck=true;
|
||||
function checkModified(){
|
||||
@ -1520,7 +1583,7 @@ var fundError={};
|
||||
var ele_error = document.createElement("li");
|
||||
var errmsg = fundError[list[ii].element.getAttribute('name')];;
|
||||
ele_error.innerHTML = "<a href='javascript:void(0)' target='_self' element_name='"+list[ii].element.getAttribute('name')+"'>" + errmsg + "</a>";
|
||||
|
||||
|
||||
if(ii>=iExtCount){
|
||||
document.getElementById("ul_error_1").appendChild(ele_error);
|
||||
}else{
|
||||
@ -1547,7 +1610,7 @@ var fundError={};
|
||||
}
|
||||
catch(e){}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
jQuery.validator.prototype.showLabel = function(element,message){
|
||||
var id=element.getAttribute('id');
|
||||
|
||||
@ -2,5 +2,6 @@
|
||||
<script type="text/javascript" src="<%=sWebRootPath%>/Frame/resources/js/checkdatavalidity.js"> </script>
|
||||
<script type="text/javascript" src="<%=sWebRootPath%>/Frame/page/js/common.js"> </script>
|
||||
<script type="text/javascript" src="<%=sWebRootPath%>/Frame/page/js/message.js"> </script>
|
||||
<script type="text/javascript" src="<%=sWebRootPath%>/js/decimal/decimal.min.js"> </script>
|
||||
<script type="text/javascript" src="<%=sWebRootPath%>/Frame/resources/js/chart/json2.js"></script>
|
||||
<!-- <script type="text/javascript" src="<%=sWebRootPath%>/AppMain/resources/js/as_credit.js"> </script> -->
|
||||
<!-- <script type="text/javascript" src="<%=sWebRootPath%>/AppMain/resources/js/as_credit.js"> </script> -->
|
||||
|
||||
@ -100,11 +100,11 @@
|
||||
alert("收款暂不支持银企直连!");
|
||||
return;
|
||||
}
|
||||
if(state_="0010"){
|
||||
if(state=="0010"){
|
||||
var sParams = "accountType="+accountType+",accType="+accType+",state="+state+",FbSdk="+FbSdk+",ownId="+ownId;
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.reckon.copydata.CalcRentCompare", "compare",sParams );
|
||||
|
||||
if(id==null||id==""||accountPurpose!="default"||sReturn=="null"||sReturn==id){
|
||||
if(accountPurpose!="default" || sReturn=="null" || (id != "" && sReturn == id)){
|
||||
as_save("myiframe0","parent.AsDialog.ClosePage()");
|
||||
}else{
|
||||
alert("相同类型的账户只能存在一个,请检查(银行账号类型 ,是否为企银直连,银行账户用途,状态等字段)!");
|
||||
|
||||
@ -166,20 +166,24 @@
|
||||
if(!confirm("核销差额不为0,是否确认核销?")){return;}
|
||||
}
|
||||
if(confirm("核销后批次号和核销信息将不可修改,是否确认核销?")){
|
||||
as_save("myiframe0","parent.AsDialog.ClosePage()");
|
||||
var SPARE_BATCH_NO = getItemValue(0, 0, "SPARE_BATCH_NO"); // 批次号
|
||||
var OWN_NUMBER = getItemValue(0, 0, "OWN_NUMBER"); // 银行账号
|
||||
var CHARGEBACK_DATE_S = getItemValue(0, 0, "CHARGEBACK_DATE_S"); // 扣款成功日期
|
||||
var CHARGEBACK_MONEY_S = getItemValue(0, 0, "CHARGEBACK_MONEY_S"); // 扣款成功金额
|
||||
var ACHIEVED_MONEY = getItemValue(0, 0, "ACHIEVED_MONEY"); // 银行到账金额
|
||||
var ACHIEVED_DATE = getItemValue(0, 0, "ACHIEVED_DATE"); // 银行到账日期
|
||||
var ACC_TITLE = getItemValue(0, 0, "ACC_TITLE"); // 银行科目
|
||||
var SEREVICE_CHARGE = getItemValue(0, 0, "SEREVICE_CHARGE"); // 手续费
|
||||
var CHARGEBACK_BALANCE = getItemValue(0, 0, "CHARGEBACK_BALANCE"); // 核销差额
|
||||
var sparam = "SPARE_BATCH_NO="+SPARE_BATCH_NO+",ACHIEVED_MONEY="+ACHIEVED_MONEY+",SEREVICE_CHARGE="+SEREVICE_CHARGE+",CHARGEBACK_BALANCE="+CHARGEBACK_BALANCE+",CHARGEBACK_MONEY_S="+CHARGEBACK_MONEY_S+",ACHIEVED_DATE="+ACHIEVED_DATE+",OWN_NUMBER="+OWN_NUMBER+",ACC_TITLE="+ACC_TITLE+",userId="+"<%=CurUser.getUserID()%>";
|
||||
// 调用生成卡扣汇总凭证
|
||||
var result = RunJavaMethodTrans("com.tenwa.voucher.CreateVoucherProcess.CreateVoucherForCardSummarizing","createCardSummarizingVoucher",sparam);
|
||||
}
|
||||
as_save("myiframe0","createVoucher()");
|
||||
}
|
||||
}
|
||||
|
||||
function createVoucher(){
|
||||
var SPARE_BATCH_NO = getItemValue(0, 0, "SPARE_BATCH_NO"); // 批次号
|
||||
var OWN_NUMBER = getItemValue(0, 0, "OWN_NUMBER"); // 银行账号
|
||||
var CHARGEBACK_DATE_S = getItemValue(0, 0, "CHARGEBACK_DATE_S"); // 扣款成功日期
|
||||
var CHARGEBACK_MONEY_S = getItemValue(0, 0, "CHARGEBACK_MONEY_S"); // 扣款成功金额
|
||||
var ACHIEVED_MONEY = getItemValue(0, 0, "ACHIEVED_MONEY"); // 银行到账金额
|
||||
var ACHIEVED_DATE = getItemValue(0, 0, "ACHIEVED_DATE"); // 银行到账日期
|
||||
var ACC_TITLE = getItemValue(0, 0, "ACC_TITLE"); // 银行科目
|
||||
var SEREVICE_CHARGE = getItemValue(0, 0, "SEREVICE_CHARGE"); // 手续费
|
||||
var CHARGEBACK_BALANCE = getItemValue(0, 0, "CHARGEBACK_BALANCE"); // 核销差额
|
||||
var sparam = "SPARE_BATCH_NO="+SPARE_BATCH_NO+",ACHIEVED_MONEY="+ACHIEVED_MONEY+",SEREVICE_CHARGE="+SEREVICE_CHARGE+",CHARGEBACK_BALANCE="+CHARGEBACK_BALANCE+",CHARGEBACK_MONEY_S="+CHARGEBACK_MONEY_S+",ACHIEVED_DATE="+ACHIEVED_DATE+",OWN_NUMBER="+OWN_NUMBER+",ACC_TITLE="+ACC_TITLE+",userId="+"<%=CurUser.getUserID()%>";
|
||||
// 调用生成卡扣汇总凭证
|
||||
var result = RunJavaMethodTrans("com.tenwa.voucher.CreateVoucherProcess.CreateVoucherForCardSummarizing","createCardSummarizingVoucher",sparam);
|
||||
parent.AsDialog.ClosePage();
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -157,7 +157,11 @@
|
||||
setItemValue(0,0,'bank_code',res[0]);
|
||||
setItemValue(0,0,'bank_type',res[1]);
|
||||
setItemValue(0,0,"bank_name",res[1]);
|
||||
setItemValue(0,0,"collect_type",res[2]);
|
||||
if("<%=subjectId%>"=="aa740e4111c111eaaa0000163e0e11e6"){//深圳主体都是广州银联
|
||||
setItemValue(0,0,"collect_type","YLcollect");
|
||||
}else{
|
||||
setItemValue(0,0,"collect_type",res[2]);
|
||||
}
|
||||
bool = false;
|
||||
}
|
||||
|
||||
@ -181,7 +185,11 @@
|
||||
setItemValue(0,0,'bank_code',sReturn[0]);
|
||||
setItemValue(0,0,'bank_type',sReturn[1]);
|
||||
setItemValue(0,0,"bank_name",sReturn[1]);
|
||||
setItemValue(0,0,"collect_type",sReturn[2]);
|
||||
if("<%=subjectId%>"=="aa740e4111c111eaaa0000163e0e11e6"){//深圳主体都是广州银联
|
||||
setItemValue(0,0,"collect_type","YLcollect");
|
||||
}else{
|
||||
setItemValue(0,0,"collect_type",sReturn[2]);
|
||||
}
|
||||
},"选择银行名称");
|
||||
}
|
||||
</script>
|
||||
|
||||
@ -199,6 +199,8 @@
|
||||
setItemRequired(0,"FRAME_NUMBER",true);
|
||||
setItemRequired(0,"CAR_COLOUR",true);
|
||||
setItemRequired(0,"ENGINE_NUMBER",true);
|
||||
setItemRequired(0,"EQUIP_PRICE",false);
|
||||
setItemRequired(0,"head_name",false);
|
||||
setItemReadOnly(0,0,"MEMO",false);
|
||||
setItemReadOnly(0,0,"DEVICE_TYPE",true);
|
||||
setItemReadOnly(0,0,"gears",true);
|
||||
@ -338,11 +340,15 @@
|
||||
}
|
||||
setItemValue(0,0,"project_id",projectId);//设置项目id
|
||||
}
|
||||
var equipPrice = getItemValue(0,getRow(0),"EQUIP_PRICE");
|
||||
if(equipPrice <= 0){
|
||||
alert("请输入正确车辆交易价!!!");
|
||||
return ;
|
||||
|
||||
var equipPrice = getItemValue(0,getRow(0),"EQUIP_PRICE");
|
||||
if(!("合同制作流程"=="<%=flowName%>"||"合同变更流程"=="<%=flowName%>")){
|
||||
if(equipPrice <= 0){
|
||||
alert("请输入正确车辆交易价!!!");
|
||||
return ;
|
||||
}
|
||||
}
|
||||
|
||||
if("SYC"==carTypea){//如果是商用车,将车辆交易价赋值给新车指导价
|
||||
setItemValue(0,0,"NOW_TOTAL", equipPrice );
|
||||
}
|
||||
@ -768,9 +774,12 @@
|
||||
function changeHeadInfo(){
|
||||
var carAttribute=getItemValue(0,getRow(0),"car_attribute");
|
||||
if("tail"==carAttribute){
|
||||
showItem(0,"head_name",'');
|
||||
setItemRequired(0,"head_name",true);
|
||||
setItemRequired(0,"ENGINE_NUMBER",false);
|
||||
showItem(0,"head_name",'');
|
||||
setItemRequired(0,"head_name",true);
|
||||
setItemRequired(0,"ENGINE_NUMBER",false);
|
||||
if("合同制作流程"=="<%=flowName%>"||"合同变更流程"=="<%=flowName%>"){
|
||||
setItemRequired(0,"head_name",false);
|
||||
}
|
||||
}else{
|
||||
showItem(0,"head_name",'none');
|
||||
setItemRequired(0,"head_name",false);
|
||||
|
||||
@ -8,33 +8,18 @@
|
||||
String sFileSaveMode = CurConfig.getConfigure("FileSaveMode");
|
||||
String sFileSavePath = CurConfig.getConfigure("FileSavePath");
|
||||
String sFileNameType = CurConfig.getConfigure("FileNameType");
|
||||
|
||||
String phaseNo = CurPage.getParameter("PhaseNo");
|
||||
String rightType = CurComp.getParameter("RightType");
|
||||
String flowunid = CurPage.getParameter("FlowUnid");
|
||||
String ishistory = CurPage.getParameter("IsHistory");
|
||||
String contract_id = CurPage.getParameter("contract_id");
|
||||
String projectId = CurPage.getParameter("ProjectId");
|
||||
String payType = Sqlca.getString(new SqlObject("SELECT payType FROM LC_FUND_INCOME_TEMP_HXM WHERE flowunid='"+flowunid+"'"));
|
||||
ASObjectModel doTemp = new ASObjectModel("ActualPaymentCarTempList");
|
||||
/* if(null!=ishistory&&ishistory.equals("true")){
|
||||
doTemp.setDataQueryClass("com.tenwa.flow.flowHistory.FlowDataListHistory");
|
||||
} */
|
||||
String customertype = null;
|
||||
String customer_id = null;
|
||||
String project_id = null;
|
||||
String product_id = null;
|
||||
String contract_number = null;
|
||||
ASResultSet rs = Sqlca.getASResultSet(new SqlObject("select customertype,contract_number,customer_id,LC_FUND_INCOME_TEMP.project_id,Product_Id from LC_FUND_INCOME_TEMP left join LB_CONTRACT_INFO lpi on lpi.PROJECT_ID=LC_FUND_INCOME_TEMP.PROJECT_ID left join LB_UNION_LESSEE ul on LC_FUND_INCOME_TEMP.contract_id=ul.contract_id and ul.is_main='Y' left join CUSTOMER_INFO cu on ul.customer_id=cu.customerid where LC_FUND_INCOME_TEMP.contract_id = "+contract_id));
|
||||
if(rs.next()){
|
||||
customertype = rs.getString("customertype");
|
||||
customer_id = rs.getString("customer_id");
|
||||
project_id = rs.getString("project_id");
|
||||
product_id = rs.getString("Product_Id");
|
||||
contract_number = rs.getString("contract_number");
|
||||
}else{
|
||||
customertype = "gaoxiao";
|
||||
}
|
||||
String payMode = Sqlca.getString(new SqlObject("SELECT pay_mode FROM LB_ACTUAL_PAYMENT_INFO_TEMP WHERE flowunid='"+flowunid+"'"));
|
||||
|
||||
ASObjectModel doTemp = new ASObjectModel("ActualPaymentCarTempList");
|
||||
if("cgb".equals(payMode)){
|
||||
doTemp.setVisible("REQSTS",false);
|
||||
doTemp.setVisible("RTNFLG",false);
|
||||
doTemp.setVisible("RTNNAR",true);
|
||||
}
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage,doTemp,request);
|
||||
dwTemp.Style="1"; //--设置为Grid风格--
|
||||
dwTemp.MultiSelect = true;
|
||||
@ -114,7 +99,7 @@
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
setColRequired();
|
||||
})
|
||||
});
|
||||
function cmb_tp_pay(){
|
||||
var plist = getItemValueArray(0,"CONTRACT_ID")+"";
|
||||
if(typeof(plist)=="undefined" || plist.length==0 ){
|
||||
@ -134,29 +119,51 @@
|
||||
}
|
||||
if(confirm("确认要发起付款申请吗?")){
|
||||
ids=plist.replace(/\,/g,"@");
|
||||
var sParams = "CurUserID=<%=CurUser.getUserID()%>,contract_ids="+ids+",FLOWUNID=<%=flowunid%>";
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.sdk.controller.CmbToPayController", "action",sParams );
|
||||
if(typeof(sReturn)=="undefined" || sReturn=="") return;
|
||||
if(sReturn.code==1){
|
||||
alert(sReturn.msg);
|
||||
}else{
|
||||
alert(sReturn.msg);
|
||||
reloadSelf();
|
||||
if('cmb'=='<%=payMode%>'){
|
||||
var sParams = "CurUserID=<%=CurUser.getUserID()%>,contract_ids="+ids+",FLOWUNID=<%=flowunid%>";
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.sdk.controller.CmbToPayController", "action",sParams );
|
||||
if(typeof(sReturn)=="undefined" || sReturn=="") return;
|
||||
if(sReturn.code==1){
|
||||
alert(sReturn.msg);
|
||||
}else{
|
||||
alert(sReturn.msg);
|
||||
reloadSelf();
|
||||
}
|
||||
}else if('cgb'=='<%=payMode%>'){
|
||||
var sParams = "userId=<%=CurUser.getUserID()%>,contractIds="+ids+",flowUnid=<%=flowunid%>,orgId=<%=CurUser.getOrgID()%>";
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.cgb.controller.OperateOfCGBController", "batchPayOfCGB",sParams );
|
||||
if('success'==sReturn.substring(0,7)){
|
||||
alert(sReturn.substring(7));
|
||||
reloadSelf();
|
||||
}else{
|
||||
alert(sReturn);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
function cmb_tp_callback(){
|
||||
var contractId = getItemValueArray(0,"CONTRACT_ID")+"";
|
||||
var contractIds = contractId.replace(",","@");
|
||||
var sParams = "CurUserID=<%=CurUser.getUserID()%>,FLOWUNID=<%=flowunid%>,contractIds="+contractIds;
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.sdk.controller.CmbToCallbackController", "action",sParams );
|
||||
if(typeof(sReturn)=="undefined" || sReturn=="") return;
|
||||
if(sReturn.code==1){
|
||||
alert(sReturn.msg);
|
||||
}else{
|
||||
alert(sReturn.msg);
|
||||
reloadSelf();
|
||||
}
|
||||
if('cmb'=='<%=payMode%>'){
|
||||
var sParams = "CurUserID=<%=CurUser.getUserID()%>,FLOWUNID=<%=flowunid%>,contractIds="+contractIds;
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.sdk.controller.CmbToCallbackController", "action",sParams );
|
||||
if(typeof(sReturn)=="undefined" || sReturn=="") return;
|
||||
if(sReturn.code==1){
|
||||
alert(sReturn.msg);
|
||||
}else{
|
||||
alert(sReturn.msg);
|
||||
reloadSelf();
|
||||
}
|
||||
}else if('cgb'=='<%=payMode%>'){
|
||||
var sParams = "userId=<%=CurUser.getUserID()%>,flowUnid=<%=flowunid%>,orgId=<%=CurUser.getOrgID()%>";
|
||||
var sReturn = RunJavaMethodTrans("com.tenwa.cgb.controller.OperateOfCGBController", "batchQueryOfCGB",sParams );
|
||||
if('success'==sReturn.substring(0,7)){
|
||||
alert(sReturn.substring(7));
|
||||
reloadSelf();
|
||||
}else{
|
||||
alert(sReturn);
|
||||
}
|
||||
}
|
||||
}
|
||||
/*function afterSearch(){
|
||||
var rows = getRowCount(0);
|
||||
@ -171,8 +178,6 @@
|
||||
}
|
||||
} */
|
||||
function createFundIncomeExcel(){
|
||||
|
||||
|
||||
var param={};
|
||||
var tempParam={};
|
||||
var sparam="";
|
||||
|
||||
@ -6,17 +6,49 @@
|
||||
History Log:
|
||||
*/
|
||||
String flowunid = CurPage.getParameter("FlowUnid");
|
||||
String phaseNo = CurPage.getParameter("PhaseNo");
|
||||
String sTempletNo = "LBActualPaymentInfoTemp";//--Ä£°åºÅ--
|
||||
ASObjectModel doTemp = new ASObjectModel(sTempletNo);
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
|
||||
dwTemp.Style = "2";//freeform
|
||||
dwTemp.ReadOnly = "1";//Ö»¶Áģʽ
|
||||
dwTemp.ReadOnly = "0";//只读模式
|
||||
dwTemp.genHTMLObjectWindow(flowunid);
|
||||
|
||||
String sButtons[][] = {
|
||||
{"0020".equals(phaseNo)?"true":"false","","Button","保存","保存所有修改","saveRecord()","","","",""},
|
||||
};
|
||||
sButtonPosition = "south";
|
||||
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
|
||||
<script type="text/javascript">
|
||||
|
||||
function saveRecord(){
|
||||
var ret = RunJavaMethodSqlca("com.tenwa.cgb.controller.OperateOfCGBController","vaildate","flowUnid=<%=flowunid%>");
|
||||
if(ret!='succ'){
|
||||
alert(ret);
|
||||
return false;
|
||||
}
|
||||
as_save(0)
|
||||
}
|
||||
|
||||
function selectOwnAccount(){
|
||||
var position = getRow(0);
|
||||
var account = getItemValue(0,0,'ACCOUNT');
|
||||
if(account == ""){
|
||||
return false;
|
||||
}
|
||||
AsDialog.OpenSelector("SelectOwnAccountPay","accName,"+account,"dialogWidth=" + parseInt(window.screen.width * 0.6) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px",function(sReturn){
|
||||
if(!sReturn||sReturn=="_CANCEL_"){
|
||||
return;
|
||||
}
|
||||
sReturn = sReturn.split("@");
|
||||
setItemValue(0,position,"ACC_NUMBER", sReturn[0]);
|
||||
setItemValue(0,position,"BANK", sReturn[1]);
|
||||
setItemValue(0,position,"ACCOUNT", sReturn[2]);
|
||||
if (sReturn[1].indexOf('广发') >= 0) {
|
||||
setItemValue(0, position, "PAY_MODE", 'cgb');
|
||||
} else if (sReturn[1].indexOf('招商') >= 0) {
|
||||
setItemValue(0, position, "PAY_MODE", 'cmb');
|
||||
}
|
||||
},"请选择本方账户信息");
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -86,11 +86,12 @@
|
||||
}
|
||||
function checkMailingAddress(){//当邮寄地址选择为户籍地址时,户籍地址必填
|
||||
var mailingAddress = getItemValue(0,0,'Mailing_Address');
|
||||
if("户籍地址" == mailingAddress){
|
||||
setItemRequired(0, "NATIVEPLACE", true);
|
||||
}else{
|
||||
setItemRequired(0, "NATIVEPLACE", false);
|
||||
}
|
||||
setItemRequired(0, "NATIVEPLACE", true);
|
||||
// if("户籍地址" == mailingAddress){
|
||||
// setItemRequired(0, "NATIVEPLACE", true);
|
||||
// }else{
|
||||
// setItemRequired(0, "NATIVEPLACE", true);
|
||||
// }
|
||||
}
|
||||
|
||||
/* function identityVerification(){//身份校验
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -68,13 +68,14 @@
|
||||
<attribute name="INNER_NUMBER" label="内部编号" type="STRING" length="32"/>
|
||||
<attribute name="BUSINESS_TYPE" label="业务类型" type="STRING" length="32"/>
|
||||
<attribute name="CUSTOMER_TYPE" label="客商类型" type="STRING" length="32"/>
|
||||
|
||||
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="LC_EBANK" />
|
||||
<property name="createKey" value="true" />
|
||||
<property name="keyDatePrefix" value="'LCE'yyyyMMdd"/>
|
||||
<property name="query.largeResultLimit" value="20000"/>
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
@ -105,7 +106,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_EBANK_BILL" label="网银挂账" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -385,7 +386,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_CALC_RULES_TEMP" label="测算租金规则" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -487,7 +488,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_RENT_PLAN_TEMP" label="测算租金计划临时表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -541,7 +542,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_RENT_PLAN_SP_TEMP" label="测算租金计划临时表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -592,7 +593,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_PROJ_CASH_FLOW" label="项目层现金流" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -1080,6 +1081,7 @@
|
||||
<attribute name="SPLIT_TYPE" label="是否灵活分润" type="STRING"/>
|
||||
<attribute name="PERSONAL_INSURANCE" label="个人意外险" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="DISCOUNT_INTEREST" label="贴息" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="SUBSECTION_CONDIG" label="分段配置" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -1423,6 +1425,8 @@
|
||||
<attribute name="SPLIT_TYPE" label="是否灵活分润" type="STRING"/>
|
||||
<attribute name="PERSONAL_INSURANCE" label="个人意外险" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="DISCOUNT_INTEREST" label="贴息" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="SUBSECTION_CONDIG" label="分段配置" type="STRING" length="32"/>
|
||||
<attribute name="COMPREHENSIVE_RATE" label="综合利率" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -1499,7 +1503,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_RENT_PLAN" label="测算租金计划表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识编号" type="STRING" length="32"/>
|
||||
@ -1554,7 +1558,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_RENT_PLAN_SP" label="测算租金计划表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识编号" type="STRING" length="32"/>
|
||||
@ -1605,7 +1609,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_FUND_INCOME" label="资金收付表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -1664,7 +1668,7 @@
|
||||
<attribute name="FUND_FEETYPE" label="抵扣资金项" type="STRING" length="100"/>
|
||||
<attribute name="DISTRIBUTOR_ID" label="经销商ID" type="STRING" length="32"/>
|
||||
<attribute name="DEDUCTION_ID" label="保证金抵扣编号" type="STRING" length="32"/>
|
||||
|
||||
|
||||
<!-- <attribute name="FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="FPHM" label="发票号码" type="STRING" length="10"/> -->
|
||||
<attribute name="isCompany" label="是否关联公司" type="STRING" length="2"/>
|
||||
@ -1737,7 +1741,7 @@
|
||||
<attribute name="FUND_FEETYPE" label="抵扣资金项" type="STRING" length="100"/>
|
||||
<attribute name="DISTRIBUTOR_ID" label="经销商ID" type="STRING" length="32"/>
|
||||
<attribute name="DEDUCTION_ID" label="保证金抵扣编号" type="STRING" length="32"/>
|
||||
|
||||
|
||||
<!-- <attribute name="FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="FPHM" label="发票号码" type="STRING" length="10"/> -->
|
||||
<attribute name="isCompany" label="是否关联公司" type="STRING" length="2"/>
|
||||
@ -1800,13 +1804,13 @@
|
||||
<attribute name="penalty_reduce" label="减免罚息" type="STRING" length="32"/>
|
||||
<attribute name="SPARE_BATCH_NO" label="扣款批次号" type="STRING" length="32"/>
|
||||
<attribute name="CHARGE_WAY" label="手续费方式" type="STRING" length="10"/>
|
||||
|
||||
|
||||
<!-- <attribute name="RENT_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="RENT_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="INTEREST_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="INTEREST_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
-->
|
||||
</attributes>
|
||||
<manager>
|
||||
@ -1869,13 +1873,13 @@
|
||||
<attribute name="penalty_reduce" label="减免罚息" type="STRING" length="32"/>
|
||||
<attribute name="SPARE_BATCH_NO" label="扣款批次号" type="STRING" length="32"/>
|
||||
<attribute name="CHARGE_WAY" label="手续费方式" type="STRING" length="10"/>
|
||||
|
||||
|
||||
<!-- <attribute name="RENT_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="RENT_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="INTEREST_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="INTEREST_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPDM" label="发票代码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
<attribute name="PENALTY_FPHM" label="发票号码" type="STRING" length="10"/>
|
||||
-->
|
||||
</attributes>
|
||||
<manager>
|
||||
@ -1964,6 +1968,7 @@
|
||||
<attribute name="interest_over" label="利息余额" type="STRING"/>
|
||||
<attribute name="penalty_over" label="罚息余额" type="STRING"/>
|
||||
<attribute name="planstatus" label="回笼状态" type="STRING"/>
|
||||
<attribute name="project_id" label="项目id" type="STRING"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -2512,7 +2517,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_RENT_PLAN_HIS" label="测算租金计划历史表" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识编号" type="STRING" length="32"/>
|
||||
@ -2566,7 +2571,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_CASH_FLOW_TEMP" label="测算现金流" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -2783,6 +2788,8 @@
|
||||
<attribute name="SPLIT_TYPE" label="是否灵活分润" type="STRING"/>
|
||||
<attribute name="PERSONAL_INSURANCE" label="个人意外险" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="DISCOUNT_INTEREST" label="贴息" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="SUBSECTION_CONDIG" label="分段配置" type="STRING" length="32"/>
|
||||
<attribute name="COMPREHENSIVE_RATE" label="综合利率" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -2984,7 +2991,7 @@
|
||||
<attribute name="INCIDENTAL_RATIO" label="杂费比例" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="PURCHASE_TAX_RATIO" label="购置税比例" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="INSURANCE_PREMIUM_RATIO" label="保险费比例" type="DOUBLE" length="22" scale="2"/>
|
||||
|
||||
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -3185,7 +3192,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="VI_RENT_PLAN" label="" keyAttributes="">
|
||||
<attributes>
|
||||
<attribute name="contract_id" label="contract_id" type="STRING"/>
|
||||
@ -3212,8 +3219,8 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
|
||||
|
||||
<class name="LC_CALC_CONDITION_TEMP" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -3368,6 +3375,8 @@
|
||||
<attribute name="SPLIT_TYPE" label="是否灵活分润" type="STRING"/>
|
||||
<attribute name="PERSONAL_INSURANCE" label="个人意外险" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="DISCOUNT_INTEREST" label="贴息" type="DOUBLE" length="22" scale="2"/>
|
||||
<attribute name="SUBSECTION_CONDIG" label="分段配置" type="STRING" length="32"/>
|
||||
<attribute name="COMPREHENSIVE_RATE" label="综合利率" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -3376,7 +3385,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LB_ACTUAL_PAYMENT_INFO" label="实际放款信息" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="ID" type="STRING" length="32"/>
|
||||
@ -3389,6 +3398,10 @@
|
||||
<attribute name="UPDATEUSERID" label="UPDATEUSERID" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="UPDATEORGID" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="UPDATETIME" type="STRING" length="32"/>
|
||||
<attribute name="bank" label="本方银行" type="STRING" length="200"/>
|
||||
<attribute name="account" label="本方账户" type="STRING" length="200"/>
|
||||
<attribute name="acc_number" label="本方帐号" type="STRING" length="200"/>
|
||||
<attribute name="pay_mode" label="付款方式" type="STRING" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -3409,7 +3422,12 @@
|
||||
<attribute name="UPDATEUSERID" label="UPDATEUSERID" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="UPDATEORGID" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="UPDATETIME" type="STRING" length="32"/>
|
||||
|
||||
<attribute name="FLOWUNID" label="FLOWUNID" type="STRING" length="32"/>
|
||||
<attribute name="bank" label="本方银行" type="STRING" length="200"/>
|
||||
<attribute name="account" label="本方账户" type="STRING" length="200"/>
|
||||
<attribute name="acc_number" label="本方帐号" type="STRING" length="200"/>
|
||||
<attribute name="pay_mode" label="付款方式" type="STRING" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -3418,7 +3436,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="VI_ACTUAL_FUND_PLAN" label="实际付款计划视图" keyAttributes="">
|
||||
<attributes>
|
||||
<attribute name="id" label="标识" type="STRING"/>
|
||||
@ -3448,7 +3466,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="VI_LC_RENT_COLLECTION" label="租金通知书" keyAttributes="">
|
||||
<attributes>
|
||||
<attribute name="id" label="id" type="STRING"/>
|
||||
@ -3682,7 +3700,7 @@
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
</class>
|
||||
<class name="LI_INVOICE_CONFIRM_DETAIL" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -4152,7 +4170,7 @@
|
||||
<attribute name="attrid" label="attrid" type="STRING"/>
|
||||
<attribute name="orgid" label="orgid" type="STRING"/>
|
||||
<attribute name="subjectid" label="主体id" type="STRING"/>
|
||||
|
||||
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
@ -4231,7 +4249,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_FUND_PLAN_HIS" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -4302,7 +4320,7 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
|
||||
<class name="LC_COLLECT_MANUAL_INFO" label="" keyAttributes="id">
|
||||
<attributes>
|
||||
<attribute name="id" label="id" type="STRING"/>
|
||||
@ -4628,5 +4646,452 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_CALC_SUBSECTION_INFO" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="SUBSECTION_NUMBER" label="分段号" type="INT" length="10"/>
|
||||
<attribute name="CLEAN_LEASE_RATIO" label="融资额比例" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="CLEAN_LEASE_MONEY" label="融资额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RATE" label="标准利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="DISCOUNT_RATE" label="产品利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="FINANCING_RATE" label="融资利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="INCOME_NUMBER" label="期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT" label="贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="MAXIMUM_DISCOUNT" label="最大贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="DISCOUNT_COLLECTION_PERIOD" label="贴息回款期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT_CALC_METHOD" label="贴息计算方式" type="STRING" length="10"/>
|
||||
<attribute name="IS_BALANCE_LENDING" label="是否差额放款" type="STRING" length="10"/>
|
||||
<attribute name="INPUTUSERID" label="录入人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="录入部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="录入时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="IS_ONLYREAD_INCOME_NUMBER" label="期次是否只读" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT" label="贴息金额是否固定金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_UPDATE_LEASE_MONEY_RATIO" label="融资利率是否可修改" type="STRING" length="10"/>
|
||||
<attribute name="MAX_LEASE_MONEY" label="融资金额最大值" type="STRING" length="32"/>
|
||||
<attribute name="MINIMUM_DISCOUNT" label="最小贴息金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT_RATE" label="贴息后利率是否固定" type="STRING" length="10"/>
|
||||
<attribute name="MAX_INCOME_NUMBER" label="最大期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_INCOME_NUMBER" label="最小期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_LEASE_MONEY" label="融资金额最小值" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_calc_subsection_info" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_CALC_SUBSECTION_INFO_HIS" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="SUBSECTION_NUMBER" label="分段号" type="INT" length="10"/>
|
||||
<attribute name="CLEAN_LEASE_RATIO" label="融资额比例" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="CLEAN_LEASE_MONEY" label="融资额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RATE" label="标准利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="DISCOUNT_RATE" label="产品利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="FINANCING_RATE" label="融资利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="INCOME_NUMBER" label="期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT" label="贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="MAXIMUM_DISCOUNT" label="最大贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="DISCOUNT_COLLECTION_PERIOD" label="贴息回款期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT_CALC_METHOD" label="贴息计算方式" type="STRING" length="10"/>
|
||||
<attribute name="IS_BALANCE_LENDING" label="是否差额放款" type="STRING" length="10"/>
|
||||
<attribute name="INPUTUSERID" label="录入人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="录入部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="录入时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="IS_ONLYREAD_INCOME_NUMBER" label="期次是否只读" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT" label="贴息金额是否固定金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_UPDATE_LEASE_MONEY_RATIO" label="融资利率是否可修改" type="STRING" length="10"/>
|
||||
<attribute name="MAX_LEASE_MONEY" label="融资金额最大值" type="STRING" length="32"/>
|
||||
<attribute name="MINIMUM_DISCOUNT" label="最小贴息金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT_RATE" label="贴息后利率是否固定" type="STRING" length="10"/>
|
||||
<attribute name="MAX_INCOME_NUMBER" label="最大期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_INCOME_NUMBER" label="最小期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_LEASE_MONEY" label="融资金额最小值" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_calc_subsection_info_his" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_CALC_SUBSECTION_INFO_TEMP" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="SUBSECTION_NUMBER" label="分段号" type="INT" length="10"/>
|
||||
<attribute name="CLEAN_LEASE_RATIO" label="融资额比例" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="CLEAN_LEASE_MONEY" label="融资额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RATE" label="标准利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="DISCOUNT_RATE" label="产品利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="FINANCING_RATE" label="融资利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="INCOME_NUMBER" label="期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT" label="贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="MAXIMUM_DISCOUNT" label="最大贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="DISCOUNT_COLLECTION_PERIOD" label="贴息回款期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT_CALC_METHOD" label="贴息计算方式" type="STRING" length="10"/>
|
||||
<attribute name="IS_BALANCE_LENDING" label="是否差额放款" type="STRING" length="10"/>
|
||||
<attribute name="INPUTUSERID" label="录入人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="录入部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="录入时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="FLOWUNID" label="流程标识" type="STRING" length="32"/>
|
||||
<attribute name="IS_ONLYREAD_INCOME_NUMBER" label="期次是否只读" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT" label="贴息金额是否固定金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_UPDATE_LEASE_MONEY_RATIO" label="融资利率是否可修改" type="STRING" length="10"/>
|
||||
<attribute name="MAX_LEASE_MONEY" label="融资金额最大值" type="STRING" length="32"/>
|
||||
<attribute name="MINIMUM_DISCOUNT" label="最小贴息金额" type="STRING" length="10"/>
|
||||
<attribute name="IS_FIXED_DISCOUNT_RATE" label="贴息后利率是否固定" type="STRING" length="10"/>
|
||||
<attribute name="MAX_INCOME_NUMBER" label="最大期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_INCOME_NUMBER" label="最小期次" type="STRING" length="32"/>
|
||||
<attribute name="MIN_LEASE_MONEY" label="融资金额最小值" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_calc_subsection_info_temp" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_CONTRACT_SUBSECTION_INFO" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="SUBSECTION_NUMBER" label="分段号" type="INT" length="10"/>
|
||||
<attribute name="CLEAN_LEASE_RATIO" label="融资额比例" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="CLEAN_LEASE_MONEY" label="融资额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RATE" label="标准利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="DISCOUNT_RATE" label="产品利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="FINANCING_RATE" label="融资利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="INCOME_NUMBER" label="期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT" label="贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="MAXIMUM_DISCOUNT" label="最大贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="DISCOUNT_COLLECTION_PERIOD" label="贴息回款期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT_CALC_METHOD" label="贴息计算方式" type="STRING" length="10"/>
|
||||
<attribute name="IS_BALANCE_LENDING" label="是否差额放款" type="STRING" length="10"/>
|
||||
<attribute name="INPUTUSERID" label="录入人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="录入部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="录入时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_contract_subsection_info" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_PROJ_SUBSECTION_INFO" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="SUBSECTION_NUMBER" label="分段号" type="INT" length="10"/>
|
||||
<attribute name="CLEAN_LEASE_RATIO" label="融资额比例" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="CLEAN_LEASE_MONEY" label="融资额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RATE" label="标准利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="DISCOUNT_RATE" label="产品利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="FINANCING_RATE" label="融资利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="INCOME_NUMBER" label="期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT" label="贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="MAXIMUM_DISCOUNT" label="最大贴息金额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="DISCOUNT_COLLECTION_PERIOD" label="贴息回款期次" type="INT" length="10"/>
|
||||
<attribute name="DISCOUNT_CALC_METHOD" label="贴息计算方式" type="STRING" length="10"/>
|
||||
<attribute name="IS_BALANCE_LENDING" label="是否差额放款" type="STRING" length="10"/>
|
||||
<attribute name="INPUTUSERID" label="录入人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="录入部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="录入时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_proj_subsection_info" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_CONTRACT_SUBSECTION_RENT_PLAN" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="QUOT_ID" label="报价编号" type="STRING" length="32"/>
|
||||
<attribute name="CUST_ID" label="客户编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_LIST" label="期次" type="INT" length="10"/>
|
||||
<attribute name="PLAN_DATE" label="计划日期" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_STATUS" label="收付状态" type="STRING" length="32"/>
|
||||
<attribute name="RENT" label="租金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS" label="财务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST" label="财务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="PENALTY" label="应收罚息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS_BUSINESS" label="业务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_BUSINESS" label="业务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RENT_ADJUST" label="租金调整值" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="ALL_REMAIN_CORPUS" label="本期后本金余额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="SETTLE_METHOD" label="结算方式" type="STRING" length="32"/>
|
||||
<attribute name="COIN" label="币种" type="STRING" length="32"/>
|
||||
<attribute name="YEAR_RATE" label="年利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="MEMO" label="备注" type="STRING" length="100"/>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING" length="32"/>
|
||||
<attribute name="INPUTUSERID" label="登记人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="登记部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="登记时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="INTEREST_DATE" label="计息日" type="STRING" length="32"/>
|
||||
<attribute name="subsection_number" label="subsection_number" type="INT" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_contract_subsection_rent_plan" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_PROJ_SUBSECTION_RENT_PLAN" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="QUOT_ID" label="报价编号" type="STRING" length="32"/>
|
||||
<attribute name="CUST_ID" label="客户编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_LIST" label="期次" type="INT" length="10"/>
|
||||
<attribute name="PLAN_DATE" label="计划日期" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_STATUS" label="收付状态" type="STRING" length="32"/>
|
||||
<attribute name="RENT" label="租金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS" label="财务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST" label="财务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="PENALTY" label="应收罚息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS_BUSINESS" label="业务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_BUSINESS" label="业务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RENT_ADJUST" label="租金调整值" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="ALL_REMAIN_CORPUS" label="本期后本金余额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="SETTLE_METHOD" label="结算方式" type="STRING" length="32"/>
|
||||
<attribute name="COIN" label="币种" type="STRING" length="32"/>
|
||||
<attribute name="YEAR_RATE" label="年利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="MEMO" label="备注" type="STRING" length="100"/>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING" length="32"/>
|
||||
<attribute name="INPUTUSERID" label="登记人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="登记部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="登记时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="INTEREST_DATE" label="计息日" type="STRING" length="32"/>
|
||||
<attribute name="subsection_number" label="subsection_number" type="INT" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_proj_subsection_rent_plan" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_SUBSECTION_RENT_PLAN" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="QUOT_ID" label="报价编号" type="STRING" length="32"/>
|
||||
<attribute name="CUST_ID" label="客户编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_LIST" label="期次" type="INT" length="10"/>
|
||||
<attribute name="PLAN_DATE" label="计划日期" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_STATUS" label="收付状态" type="STRING" length="32"/>
|
||||
<attribute name="RENT" label="租金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS" label="财务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST" label="财务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="PENALTY" label="应收罚息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS_BUSINESS" label="业务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_BUSINESS" label="业务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RENT_ADJUST" label="租金调整值" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="ALL_REMAIN_CORPUS" label="本期后本金余额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="SETTLE_METHOD" label="结算方式" type="STRING" length="32"/>
|
||||
<attribute name="COIN" label="币种" type="STRING" length="32"/>
|
||||
<attribute name="YEAR_RATE" label="年利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="MEMO" label="备注" type="STRING" length="100"/>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING" length="32"/>
|
||||
<attribute name="INPUTUSERID" label="登记人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="登记部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="登记时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="INTEREST_DATE" label="计息日" type="STRING" length="32"/>
|
||||
<attribute name="AUDIT_STATE" label="代收审计状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_STATUS" label="收款状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_MSG" label="收款描述" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_TIME" label="失败时间" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_REASON" label="失败原因" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_NO" label="批量交易流水号,若拆分,以,分割" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_STATUS" label="批量处理状态" type="STRING" length="200"/>
|
||||
<attribute name="batch_sn" label="batch_sn" type="STRING" length="200"/>
|
||||
<attribute name="SPARE_BATCH_NO" label="SPARE_BATCH_NO" type="STRING" length="32"/>
|
||||
<attribute name="CORPUS_SP" label="CORPUS_SP" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_sp" label="INTEREST_sp" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="splitting_status" label="splitting_status" type="STRING" length="2"/>
|
||||
<attribute name="charge_way" label="charge_way" type="STRING" length="10"/>
|
||||
<attribute name="subsection_number" label="subsection_number" type="INT" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_subsection_rent_plan" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_SUBSECTION_RENT_PLAN_HIS" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="QUOT_ID" label="报价编号" type="STRING" length="32"/>
|
||||
<attribute name="CUST_ID" label="客户编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_LIST" label="期次" type="INT" length="10"/>
|
||||
<attribute name="PLAN_DATE" label="计划日期" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_STATUS" label="收付状态" type="STRING" length="32"/>
|
||||
<attribute name="RENT" label="租金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS" label="财务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST" label="财务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="PENALTY" label="应收罚息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS_BUSINESS" label="业务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_BUSINESS" label="业务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RENT_ADJUST" label="租金调整值" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="ALL_REMAIN_CORPUS" label="本期后本金余额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="SETTLE_METHOD" label="结算方式" type="STRING" length="32"/>
|
||||
<attribute name="COIN" label="币种" type="STRING" length="32"/>
|
||||
<attribute name="YEAR_RATE" label="年利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="MEMO" label="备注" type="STRING" length="100"/>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING" length="32"/>
|
||||
<attribute name="INPUTUSERID" label="登记人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="登记部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="登记时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="INTEREST_DATE" label="计息日" type="STRING" length="32"/>
|
||||
<attribute name="AUDIT_STATE" label="代收审计状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_STATUS" label="收款状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_MSG" label="收款描述" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_TIME" label="失败时间" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_REASON" label="失败原因" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_NO" label="批量交易流水号,若拆分,以,分割" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_STATUS" label="批量处理状态" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_SN" label="一笔批量交易流水内项数SN" type="STRING" length="200"/>
|
||||
<attribute name="SPARE_BATCH_NO" label="SPARE_BATCH_NO" type="STRING" length="32"/>
|
||||
<attribute name="CORPUS_SP" label="CORPUS_SP" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_sp" label="INTEREST_sp" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="splitting_status" label="splitting_status" type="STRING" length="2"/>
|
||||
<attribute name="charge_way" label="charge_way" type="STRING" length="10"/>
|
||||
<attribute name="subsection_number" label="subsection_number" type="INT" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_subsection_rent_plan_his" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LC_SUBSECTION_RENT_PLAN_TEMP" label="" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
<attribute name="QUOT_ID" label="报价编号" type="STRING" length="32"/>
|
||||
<attribute name="CUST_ID" label="客户编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_ID" label="项目编号" type="STRING" length="32"/>
|
||||
<attribute name="PROJECT_PLAN_NUMBER" label="项目方案编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同编号" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_PLAN_NUMBER" label="合同方案编号" type="STRING" length="32"/>
|
||||
<attribute name="PAYMENT_NUMBER" label="投放编号" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_LIST" label="期次" type="INT" length="10"/>
|
||||
<attribute name="PLAN_DATE" label="计划日期" type="STRING" length="32"/>
|
||||
<attribute name="PLAN_STATUS" label="收付状态" type="STRING" length="32"/>
|
||||
<attribute name="RENT" label="租金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS" label="财务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST" label="财务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="PENALTY" label="应收罚息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="CORPUS_BUSINESS" label="业务本金" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_BUSINESS" label="业务租息" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="RENT_ADJUST" label="租金调整值" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="ALL_REMAIN_CORPUS" label="本期后本金余额" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="SETTLE_METHOD" label="结算方式" type="STRING" length="32"/>
|
||||
<attribute name="COIN" label="币种" type="STRING" length="32"/>
|
||||
<attribute name="YEAR_RATE" label="年利率" type="DOUBLE" length="18" scale="6"/>
|
||||
<attribute name="MEMO" label="备注" type="STRING" length="100"/>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING" length="32"/>
|
||||
<attribute name="INPUTUSERID" label="登记人" type="STRING" length="32"/>
|
||||
<attribute name="INPUTORGID" label="登记部门" type="STRING" length="32"/>
|
||||
<attribute name="INPUTTIME" label="登记时间" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEUSERID" label="更新人" type="STRING" length="32"/>
|
||||
<attribute name="UPDATEORGID" label="更新部门" type="STRING" length="32"/>
|
||||
<attribute name="UPDATETIME" label="更新时间" type="STRING" length="32"/>
|
||||
<attribute name="INTEREST_DATE" label="计息日" type="STRING" length="32"/>
|
||||
<attribute name="AUDIT_STATE" label="代收审计状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_STATUS" label="收款状态" type="STRING" length="32"/>
|
||||
<attribute name="COLLECT_MSG" label="收款描述" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_TIME" label="失败时间" type="STRING" length="200"/>
|
||||
<attribute name="FAILURE_REASON" label="失败原因" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_NO" label="交易流水号,若拆分,以,分割" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_STATUS" label="批量处理状态" type="STRING" length="200"/>
|
||||
<attribute name="BATCH_SN" label="一笔批量交易流水内项数SN" type="STRING" length="200"/>
|
||||
<attribute name="SPARE_BATCH_NO" label="SPARE_BATCH_NO" type="STRING" length="32"/>
|
||||
<attribute name="CORPUS_SP" label="CORPUS_SP" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="INTEREST_sp" label="INTEREST_sp" type="DOUBLE" length="18" scale="2"/>
|
||||
<attribute name="splitting_status" label="splitting_status" type="STRING" length="2"/>
|
||||
<attribute name="charge_way" label="charge_way" type="STRING" length="10"/>
|
||||
<attribute name="subsection_number" label="subsection_number" type="INT" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="lc_subsection_rent_plan_temp" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
</package>
|
||||
</jbo>
|
||||
|
||||
@ -3862,11 +3862,11 @@
|
||||
<attributes>
|
||||
<attribute name="ID" label="ID" type="STRING" length="32"/>
|
||||
<attribute name="CMB_PAY_NO" label="付款流水号" type="STRING" length="32"/>
|
||||
<attribute name="CMB_PAY_LOG" label="付款日志" type="STRING" length="32"/>
|
||||
<attribute name="CMB_PAY_LOG" label="付款日志(未使用字段,暂存广发批次号)" type="STRING" length="32"/>
|
||||
<attribute name="CONTRACT_ID" label="合同ID" type="STRING" length="32"/>
|
||||
<attribute name="DISTRIBUTOR_ID" label="经销商编号" type="STRING" length="32"/>
|
||||
<attribute name="FLOWUNID" label="流程号" type="STRING" length="32"/>
|
||||
<attribute name="SQRNBR" label="流水号" type="STRING" length="10"/>
|
||||
<attribute name="SQRNBR" label="流水号" type="STRING" length="50"/>
|
||||
<attribute name="YURREF" label="业务参考号" type="STRING" length="30"/>
|
||||
<attribute name="REQNBR" label="流程实例号" type="STRING" length="10"/>
|
||||
<attribute name="REQSTS" label="业务请求状态" type="STRING" length="3"/>
|
||||
|
||||
2
WebContent/js/decimal/decimal.min.js
vendored
Normal file
2
WebContent/js/decimal/decimal.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
WebContent/js/decimal/decimal.min.js.map
Normal file
1
WebContent/js/decimal/decimal.min.js.map
Normal file
File diff suppressed because one or more lines are too long
@ -177,6 +177,9 @@ public class ConditionBean implements Cloneable{
|
||||
private String discountInterest; // 贴息(不参与融资)
|
||||
private String personalInsurance; // 个人意外险
|
||||
/*****************************/
|
||||
/* ******* 分段融 ****************/
|
||||
private String comprehensiveRate; // 综合利率
|
||||
/*****************************/
|
||||
|
||||
/***********************************************************************************
|
||||
* 暂时未使用字段(历史版本字段)
|
||||
@ -1453,6 +1456,7 @@ public class ConditionBean implements Cloneable{
|
||||
param = (param.isEmpty() ? "0" : param);
|
||||
return param;
|
||||
}
|
||||
|
||||
/*
|
||||
* 期初为租金计划的最后一期在加一期,期末为租金计划最后一期
|
||||
*/
|
||||
@ -1832,6 +1836,13 @@ public class ConditionBean implements Cloneable{
|
||||
public void setPersonalInsurance(String personalInsurance) {
|
||||
this.personalInsurance = personalInsurance;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public void setComprehensiveRate(String comprehensiveRate) {
|
||||
this.comprehensiveRate = comprehensiveRate;
|
||||
}
|
||||
|
||||
public String getComprehensiveRate() {
|
||||
return defaultZero(comprehensiveRate);
|
||||
}
|
||||
}
|
||||
|
||||
85
calc/com/tenwa/reckon/check/SubsectionCheck.java
Normal file
85
calc/com/tenwa/reckon/check/SubsectionCheck.java
Normal file
@ -0,0 +1,85 @@
|
||||
package com.tenwa.reckon.check;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public class SubsectionCheck {
|
||||
private String flowUnid ;
|
||||
private String equipAmt ;
|
||||
private String cleanLeaseMoney ;
|
||||
private String subsectionCondig ;
|
||||
|
||||
|
||||
public String checkSubsectionInfo() throws Exception{
|
||||
BizObjectManager lcsitManage = JBOFactory.getBizObjectManager(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME);
|
||||
List lcsits = lcsitManage.createQuery("flowunid=:flowunid").setParameter("flowunid", flowUnid).getResultList(false);
|
||||
if( lcsits == null || lcsits.size()==0){
|
||||
return "分段信息为空,请检查!";
|
||||
}
|
||||
lcsits = lcsitManage.createQuery("flowunid=:flowunid and (v.ifnull(CLEAN_LEASE_MONEY,0) > 0 or v.ifnull(FINANCING_RATE,0) > 0 or v.ifnull(INCOME_NUMBER,0) > 0)").setParameter("flowunid", flowUnid).getResultList(false);
|
||||
if( lcsits == null || lcsits.size()==0){
|
||||
return "分段信息中有融资金额、融资利率、期次为空,请检查!";
|
||||
}
|
||||
List<Map<String, String>> dataClm = DataOperatorUtil.getDataBySql("select sum(ifnull(CLEAN_LEASE_MONEY,0)) as CLEAN_LEASE_MONEY from LC_CALC_SUBSECTION_INFO_TEMP where flowunid='"+flowUnid+"' group by flowunid");
|
||||
BigDecimal clm = new BigDecimal("0");
|
||||
if( dataClm != null && dataClm.size() > 0 ){
|
||||
clm = new BigDecimal(dataClm.get(0).get("CLEAN_LEASE_MONEY"));
|
||||
}
|
||||
//不管根据什么计算,都校验分段融的金额和综合融资额
|
||||
if(new BigDecimal(cleanLeaseMoney).compareTo( clm ) != 0){
|
||||
return "分段融资额和综合融资额不一致,请检查!";
|
||||
}
|
||||
/*if(subsectionCondig.equals("CarPrice")){
|
||||
if(new BigDecimal(equipAmt).compareTo( clm ) != 0){
|
||||
return "分段融资额和车价金额不一致,请检查!";
|
||||
}
|
||||
}else if(subsectionCondig.equals("FinancingPrice")){
|
||||
if(new BigDecimal(cleanLeaseMoney).compareTo( clm ) != 0){
|
||||
return "分段融资额和综合融资额不一致,请检查!";
|
||||
}
|
||||
}else{
|
||||
return "没有检查到对应的分段配置,请检查!";
|
||||
}*/
|
||||
return "success";
|
||||
}
|
||||
|
||||
|
||||
public String getFlowUnid() {
|
||||
return flowUnid;
|
||||
}
|
||||
public void setFlowUnid(String flowUnid) {
|
||||
this.flowUnid = flowUnid;
|
||||
}
|
||||
|
||||
public String getEquipAmt() {
|
||||
return equipAmt;
|
||||
}
|
||||
|
||||
public void setEquipAmt(String equipAmt) {
|
||||
this.equipAmt = equipAmt;
|
||||
}
|
||||
|
||||
public String getCleanLeaseMoney() {
|
||||
return cleanLeaseMoney;
|
||||
}
|
||||
|
||||
public void setCleanLeaseMoney(String cleanLeaseMoney) {
|
||||
this.cleanLeaseMoney = cleanLeaseMoney;
|
||||
}
|
||||
|
||||
public String getSubsectionCondig() {
|
||||
return subsectionCondig;
|
||||
}
|
||||
|
||||
public void setSubsectionCondig(String subsectionCondig) {
|
||||
this.subsectionCondig = subsectionCondig;
|
||||
}
|
||||
}
|
||||
|
||||
@ -93,7 +93,7 @@ public class CalcRentCompare implements BizObjectCompare{
|
||||
}
|
||||
|
||||
public String compare(JBOTransaction tx) throws JBOException{
|
||||
String sql ="select id from O where O.own_id='"+ownId+"' and O.state_='0010' and O.ACC_TYPE='0010' and O.FbSdk='Y' and (O.account_type='out_account' or O.account_type='inAndOut_account')";
|
||||
String sql ="select id from O where O.own_id='"+ownId+"' and O.state_='0010' and O.ACC_TYPE='0010' and O.FbSdk='Y' and (O.account_type='out_account' or O.account_type='inAndOut_account') and account_purpose='default' ";
|
||||
if("in_account".equals(accountType)){
|
||||
sql ="select id from O where O.own_id='"+ownId+"' and O.state_='0010' and O.ACC_TYPE='0010' and (O.account_type='in_account' or O.account_type='inAndOut_account') and account_purpose='default'";
|
||||
}else if("inAndOut_account".equals(accountType)){
|
||||
|
||||
@ -15,6 +15,7 @@ import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.gnete.bc.util.Strings;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.reckon.bean.ConditionBean;
|
||||
import com.tenwa.reckon.bean.TabCalBean;
|
||||
@ -23,30 +24,52 @@ import com.tenwa.reckon.util.IRRCalculateUtil;
|
||||
import com.tenwa.reckon.util.IrrTools;
|
||||
|
||||
public class CashFlowExecutor {
|
||||
|
||||
|
||||
private JBOTransaction tx;
|
||||
|
||||
|
||||
public CashFlowExecutor(JBOTransaction tx){
|
||||
this.tx=tx;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public String run(ConditionBean cb , TabCalBean tcb) throws Exception{
|
||||
this.delete(tcb, cb);
|
||||
this.add(cb, tcb);
|
||||
String irr = this.getIrr(cb,tcb);
|
||||
String irr = "";
|
||||
if( "segmented_financing".equals( cb.getSettleMethod() ) ){
|
||||
irr = this.getIrr(cb,tcb,"subsectionIRR");
|
||||
String subsectionRate = this.getIrr(cb, tcb, "subsectionRate");
|
||||
cb.setComprehensiveRate( subsectionRate );
|
||||
}else{
|
||||
irr = this.getIrr(cb,tcb,"normal");
|
||||
}
|
||||
cb.setIrr(irr);
|
||||
return irr;
|
||||
}
|
||||
private String getIrr(ConditionBean cb ,TabCalBean tcb) throws Exception{
|
||||
//calcType 计算类型 normal正常合同计算IRR;subsectionIRR:分段融计算IRR,subsectionRate:分段融计算综合利率
|
||||
private String getIrr(ConditionBean cb , TabCalBean tcb, String calcType) throws Exception{
|
||||
String cashSql = "select NET_FLOW,PLAN_DATE from "+Tools.getTable(tcb.getContractCashTb())+" where flowunid ='"+tcb.getDocId()+"' and "+tcb.getPlanCName()+"='"+tcb.getPlanCValue()+"' order by plan_date";
|
||||
List<Map<String, String>> cashes =DataOperatorUtil.getDataBySql(tx, cashSql, null);
|
||||
List<String > netList = new ArrayList<String>();
|
||||
List<String > dateList = new ArrayList<String>();
|
||||
for(Map<String, String> cash :cashes){
|
||||
netList.add(cash.get("NET_FLOW"));
|
||||
dateList.add(cash.get("PLAN_DATE"));
|
||||
for(Map<String, String> cash :cashes){
|
||||
netList.add(cash.get("NET_FLOW"));
|
||||
dateList.add(cash.get("PLAN_DATE"));
|
||||
}
|
||||
if ("subsectionRate".equals(calcType) ){
|
||||
String subsectionSql = "select IS_BALANCE_LENDING,DISCOUNT,DISCOUNT_COLLECTION_PERIOD from lc_calc_subsection_info_temp where FLOWUNID='"+tcb.getDocId()+"'";
|
||||
List<Map<String, String>> subsectionData =DataOperatorUtil.getDataBySql(tx, subsectionSql, null);
|
||||
BigDecimal tempMoney = BigDecimal.ZERO;
|
||||
int coss = 0;
|
||||
for (Map<String, String> subsection :subsectionData) {
|
||||
String ibl = subsection.get("IS_BALANCE_LENDING");
|
||||
if(!"Y".equals(ibl)){
|
||||
coss = Integer.parseInt( subsection.get("DISCOUNT_COLLECTION_PERIOD") );
|
||||
}
|
||||
tempMoney = new BigDecimal( netList.get(coss) );
|
||||
netList.set(coss, ( tempMoney.subtract( new BigDecimal( subsection.get("DISCOUNT") ) ) ).toString() );
|
||||
}
|
||||
}
|
||||
String irr="";
|
||||
if("STAGE_IRR".equals(cb.getIrrType())){//按期IRR
|
||||
BigDecimal issueRate=IRRCalculateUtil.getIRR2(netList);
|
||||
@ -87,15 +110,15 @@ public class CashFlowExecutor {
|
||||
}
|
||||
return irr;
|
||||
}
|
||||
|
||||
|
||||
private void delete(TabCalBean tcb,ConditionBean cb) throws Exception{
|
||||
BizObjectManager bm=JBOFactory.getBizObjectManager(tcb.getContractCashTb(), tx);
|
||||
String sql = " delete from O where flowunid='" + tcb.getDocId() + "' and "+tcb.getPlanCName()+"='"+tcb.getPlanCValue()+"'";
|
||||
bm.createQuery(sql).executeUpdate();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void add(ConditionBean cb,TabCalBean tcb) throws Exception{
|
||||
|
||||
|
||||
Map<String, Map<String, String>> productRevenues = tcb.getProductRevenues();
|
||||
String GPSDifference = "0";//获取产品中的GPS差额配置
|
||||
Map<String, String> GPSMap = productRevenues == null ? null : productRevenues.get( "GPSDifference" );
|
||||
@ -115,7 +138,7 @@ public class CashFlowExecutor {
|
||||
personalInsuranceDifference = "0";
|
||||
}
|
||||
}*/
|
||||
|
||||
|
||||
String sql = "";
|
||||
if("MYSQL".equals(InitDBType.DBTYPE)){
|
||||
sql += "INSERT INTO " +Tools.getTable(tcb.getContractCashTb())+ " (id," + tcb.getPlanCName() + "";
|
||||
@ -127,7 +150,7 @@ public class CashFlowExecutor {
|
||||
sql += ",net_flow";
|
||||
sql += ",flowunid";//create_date,creator_ "+DateUtil.getSystemDate()+"' create_date ,'"+SecurityUtil.getPrincipal().getId()+"' creator_"
|
||||
sql += " )";
|
||||
|
||||
|
||||
sql +=" select replace(uuid(),'-','') id,'"+tcb.getPlanCValue()+"' "+tcb.getPlanCName()+",t.plan_date,sum(t.flowin) fundin,ifnull(group_concat(if(t.flowindetail='',null,t.flowindetail)),'-') fundindetails, ";
|
||||
sql +=" sum(t.flowout) fundout ,ifnull(group_concat(if(t.flowoutdetail='',null,t.flowoutdetail)),'-')fundoutdetails,sum(t.cleanfow)netflow ,'"+tcb.getDocId()+"' flowunid " ;
|
||||
sql +=" from (" ;
|
||||
@ -146,7 +169,7 @@ public class CashFlowExecutor {
|
||||
sql +=" if(fundplan.pay_type='pay_type_in',fundplan.plan_money,-fundplan.plan_money) cleanfow " ;
|
||||
sql +=" from "+Tools.getTable(tcb.getFundFundPlan_tb())+" fundplan " ;
|
||||
sql +=" left join code_library tdd on fundplan.fee_type = tdd.itemno and tdd.codeno='FeeType' " ;
|
||||
sql +=" where fundplan.flowunid = '"+ tcb.getDocId()+"' and fundplan."+tcb.getPlanCName()+"='"+tcb.getPlanCValue()+"' and fundplan.fee_type in ('feetype2','feetype1','feetype10','feetype16','feetype17','feetype33','feetype24') ";
|
||||
sql +=" where fundplan.flowunid = '"+ tcb.getDocId()+"' and fundplan."+tcb.getPlanCName()+"='"+tcb.getPlanCValue()+"' and fundplan.fee_type in ('feetype2','feetype1','feetype10','feetype16','feetype17','feetype33','feetype24','feetype27') ";
|
||||
//根据客户(张文竹)不管是否灵活产品,配置的GPS差额和个人意外险差额添加到IRR计算
|
||||
/*
|
||||
if( !"0".equals(personalInsuranceDifference) ){
|
||||
@ -156,7 +179,7 @@ public class CashFlowExecutor {
|
||||
if( !"0".equals(GPSDifference) ){
|
||||
sql += "union all select plan_date,'"+GPSDifference+"' flowin,'GPS差额:"+GPSDifference+"' flowindetail,'' flowout,'' flowoutdetil,'"+GPSDifference+"' cleanfow from lc_fund_plan_temp where flowunid = '"+tcb.getDocId()+"' and fee_type='feetype10' ";
|
||||
}
|
||||
|
||||
|
||||
}else if("ORACLE".equals(InitDBType.DBTYPE)){
|
||||
sql += "INSERT INTO " +Tools.getTable(tcb.getContractCashTb())+ " (id," + tcb.getPlanCName() + "";
|
||||
sql += ",plan_date";
|
||||
@ -167,7 +190,7 @@ public class CashFlowExecutor {
|
||||
sql += ",net_flow";
|
||||
sql += ",flowunid";//create_date,creator_ "+DateUtil.getSystemDate()+"' create_date ,'"+SecurityUtil.getPrincipal().getId()+"' creator_"
|
||||
sql += " )";
|
||||
|
||||
|
||||
sql +=" select sys_guid() id,'"+tcb.getPlanCValue()+"' "+tcb.getPlanCName()+",t.plan_date,sum(t.flowin) fundin,nvl(wmsys.wm_concat(case when t.flowindetail='' then null else t.flowindetail end ),'-') fundindetails, ";
|
||||
sql +=" sum(t.flowout) fundout ,nvl(wmsys.wm_concat(case when t.flowoutdetail='' then null else t.flowoutdetail end),'-') fundoutdetails,sum(t.cleanfow)netflow ,'"+tcb.getDocId()+"' flowunid " ;
|
||||
sql +=" from (" ;
|
||||
@ -207,10 +230,10 @@ public class CashFlowExecutor {
|
||||
sql +=" )t group by t.plan_date ";
|
||||
Transaction Sqlca =null;
|
||||
Sqlca = Transaction.createTransaction(tx);
|
||||
SqlObject asql = new SqlObject("");
|
||||
SqlObject asql = new SqlObject("");
|
||||
asql.setOriginalSql(sql);
|
||||
Sqlca.executeSQL(asql);
|
||||
|
||||
|
||||
String depositStyle = "";
|
||||
Map<String, Map<String, String>> productCost = ProductParamUtil.getProductComponentType(productId, "PRD0315");
|
||||
if( productCost != null && productCost.size() > 0 ){
|
||||
@ -244,7 +267,7 @@ public class CashFlowExecutor {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}else if ("caution_money_method02".equals( depositStyle )){//保证金退回
|
||||
outMoney = new BigDecimal(cb.getCautionMoney() );
|
||||
inMoney = new BigDecimal(lcftDate.get(0).get("FUND_IN") );
|
||||
@ -252,9 +275,9 @@ public class CashFlowExecutor {
|
||||
asql.setOriginalSql(updateSql);
|
||||
Sqlca.executeSQL(asql);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -59,9 +59,26 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
private String ebanknumber;
|
||||
private String projectId;
|
||||
private String distributorId;
|
||||
private String equipAmt;
|
||||
private String subsectionConfig;
|
||||
|
||||
public String getEquipAmt() {
|
||||
return equipAmt;
|
||||
}
|
||||
|
||||
public String getStartDate() {
|
||||
public void setEquipAmt(String equipAmt) {
|
||||
this.equipAmt = equipAmt;
|
||||
}
|
||||
|
||||
public String getSubsectionConfig() {
|
||||
return subsectionConfig;
|
||||
}
|
||||
|
||||
public void setSubsectionConfig(String subsectionConfig) {
|
||||
this.subsectionConfig = subsectionConfig;
|
||||
}
|
||||
|
||||
public String getStartDate() {
|
||||
return startDate;
|
||||
}
|
||||
|
||||
@ -146,16 +163,43 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public String resetSubsection( JBOTransaction tx ) throws Exception {
|
||||
try {
|
||||
BizObjectManager bom = JBOFactory.getBizObjectManager( "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP", tx );
|
||||
List<BizObject> 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 {
|
||||
// if ( "Y".equals( cb.getFlexible() ) ) {
|
||||
if( !"segmented_financing".equals( cb.getSettleMethod() ) ){
|
||||
// if ( "Y".equals( cb.getFlexible() ) ) {
|
||||
// 灵活产品验证年利率区间
|
||||
try {
|
||||
Map<String, Map<String, String>> productRevenues = ProductParamUtil.getProductComponentType( tcb.getProductId(), "PRD0390" );
|
||||
tcb.setProductRevenues( productRevenues );
|
||||
|
||||
|
||||
Map<String, Map<String, String>> productRates = ProductParamUtil.getProductComponentType(productId, "PRD0350");
|
||||
Map<String, String> productRate = productRates.get("product_rate");
|
||||
String isFixedRate = productRate.get("isFixedRate");
|
||||
@ -178,7 +222,9 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
e.printStackTrace();
|
||||
throw new BusinessException( e.getMessage() );
|
||||
}
|
||||
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@ -326,19 +372,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<BizObject> 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 +438,8 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
} finally {
|
||||
if(ps != null) ps.close();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
public String getSplitByProductId(JBOTransaction tx) {
|
||||
@ -667,6 +713,8 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
executor=new CarEvenInterestExecutor(tx,bean.getProductId());//车贷均息入口
|
||||
}else if(settleMethod.equals("car_even_rent")){
|
||||
executor=new CarEvenRentExecutor(tx,bean.getProductId());//车贷等租入口
|
||||
} else if ( "segmented_financing".equals( settleMethod ) ) {
|
||||
executor = new SegmentedFinancingExecutor( tx );
|
||||
} else {
|
||||
executor = new EvenRentExecutor(tx);
|
||||
}
|
||||
@ -1372,7 +1420,7 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
tx.commit();
|
||||
return "Success";
|
||||
}
|
||||
|
||||
|
||||
//校验融资金额是否超额
|
||||
public String checkMoney()throws Exception{
|
||||
BigDecimal sumMoney = new BigDecimal("0") ;
|
||||
@ -1384,8 +1432,8 @@ public class CreateTransactionExecutor implements Transaction {
|
||||
sumMoney = sumMoney.setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
return sumMoney.toString();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public String getCalType() {
|
||||
return calType;
|
||||
}
|
||||
|
||||
@ -29,7 +29,7 @@ import com.tenwa.reckon.bean.TabCalBean;
|
||||
import com.tenwa.reckon.util.UUIDUtil;
|
||||
|
||||
public class FundFundPlanExecutor {
|
||||
|
||||
|
||||
public void run(ConditionBean cb , TabCalBean tcb,FundRentPlanBean rentPlan,JBOTransaction tx) throws Exception{
|
||||
cb.setDocId(tcb.getDocId());
|
||||
List<FundPlanBean> fundPlanBeans=new ArrayList<FundPlanBean>();
|
||||
@ -43,6 +43,36 @@ public class FundFundPlanExecutor {
|
||||
cb.setDeductionLastPlanDate(cb.getLastPlanDate());//不生成保证金抵扣及退还计划
|
||||
}
|
||||
fundPlanBeans = this.create(tcb,fundPlanBeans,tx);
|
||||
|
||||
// 补上分段融贴息计划
|
||||
if ( "segmented_financing".equals( cb.getSettleMethod() ) ) {
|
||||
BizObjectManager bom = JBOFactory.getBizObjectManager( "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP", tx );
|
||||
List<BizObject> bos = bom.createQuery( "flowunid = :flowunid" ).setParameter( "flowunid", tcb.getDocId() ).getResultList( false );
|
||||
for ( BizObject bo : bos ) {
|
||||
String discount = bo.getAttribute( "DISCOUNT_INTEREST" ).getString();
|
||||
String subsectionNumber = bo.getAttribute( "SUBSECTION_NUMBER" ).getString();
|
||||
String isBalanceLending = bo.getAttribute( "IS_BALANCE_LENDING" ).getString();
|
||||
String discountCollectionPeriod = bo.getAttribute( "DISCOUNT_COLLECTION_PERIOD" ).getString();
|
||||
FundPlanBean fundPlanBean = new FundPlanBean();
|
||||
fundPlanBean.setFeeType( "feetype27" );
|
||||
fundPlanBean.setPlanList( subsectionNumber );
|
||||
fundPlanBean.setSettleMethod( "payfund6" );
|
||||
fundPlanBean.setPayType( "pay_type_in" );
|
||||
if ( "Y".equals( isBalanceLending ) ) {
|
||||
fundPlanBean.setPlanDate( getPlanDate( "PaymentTime1", cb ) );
|
||||
} else {
|
||||
if ( "0".equals( discountCollectionPeriod ) ) {
|
||||
fundPlanBean.setPlanDate( getPlanDate( "PaymentTime1", cb ) );
|
||||
} else {
|
||||
fundPlanBean.setPlanDate( rentPlan.getPlanDateList().get( Integer.parseInt( discountCollectionPeriod ) - 1 ) );
|
||||
}
|
||||
}
|
||||
fundPlanBean.setPlanMoney( discount );
|
||||
fundPlanBean.setPayCust( "" );
|
||||
fundPlanBeans.add( fundPlanBean );
|
||||
}
|
||||
}
|
||||
|
||||
this.delete(tcb,tx);
|
||||
this.add(fundPlanBeans, tcb,tx);
|
||||
}
|
||||
@ -110,7 +140,7 @@ public class FundFundPlanExecutor {
|
||||
if(Float.parseFloat(sdhandlingCharge)>0){
|
||||
ffcp=new FundPlanBean();
|
||||
ffcp.setId(UUID.randomUUID().toString().replaceAll("-", ""));
|
||||
ffcp.setFeeType("feetype30");//商定违约金
|
||||
ffcp.setFeeType("feetype30");//商定违约金
|
||||
ffcp.setPlanList("1");
|
||||
ffcp.setSettleMethod("payfund6");
|
||||
ffcp.setPayType("pay_type_in");
|
||||
@ -136,7 +166,7 @@ public class FundFundPlanExecutor {
|
||||
if(Float.parseFloat(otherIn)>0){
|
||||
ffcp=new FundPlanBean();
|
||||
ffcp.setId(UUID.randomUUID().toString().replaceAll("-", ""));
|
||||
ffcp.setFeeType("feetype8");//其他应收
|
||||
ffcp.setFeeType("feetype8");//其他应收
|
||||
ffcp.setPlanList("1");
|
||||
ffcp.setSettleMethod("payfund6");
|
||||
ffcp.setPayType("pay_type_in");
|
||||
@ -147,7 +177,7 @@ public class FundFundPlanExecutor {
|
||||
}
|
||||
return fundPlanBeans;
|
||||
}
|
||||
|
||||
|
||||
//创建资金计划
|
||||
private List<FundPlanBean> create(TabCalBean tcb,List<FundPlanBean> fundPlanBeans,JBOTransaction tx) throws Exception{
|
||||
//获取产品租赁物类型配置
|
||||
@ -167,7 +197,7 @@ public class FundFundPlanExecutor {
|
||||
if("quoted_price".equals(tcb.getCalType())){
|
||||
custid=tcb.getDocId();
|
||||
}else if(tcb.getUserId()==null||tcb.getUserId().equals("")){
|
||||
|
||||
|
||||
} else{
|
||||
String sql2="select customer_id from "+tcb.getUserId()+" where flowunid='"+tcb.getDocId()+"'";
|
||||
List<Map<String,String>> list=DataOperatorUtil.getDataBySql(tx, sql2, null);
|
||||
@ -175,10 +205,10 @@ public class FundFundPlanExecutor {
|
||||
custid=list.get(0).get("customer_id");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
BizObject con=tcb.getCondition();
|
||||
ConditionBean cb=tcb.getCb();
|
||||
|
||||
|
||||
//String sql="select itemno from O where codeno='FeeType' and relativecode=:code";
|
||||
Item[] items = CodeCache.getItems("FeeType");
|
||||
for(Map.Entry<String,Map<String,String>> entry:map.entrySet()){
|
||||
@ -192,11 +222,11 @@ public class FundFundPlanExecutor {
|
||||
&& "EQUIP_END_VALUE".equals(key)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
//取值
|
||||
BigDecimal temp = null;
|
||||
|
||||
if("business_product".equals(tcb.getProductType())
|
||||
|
||||
if("business_product".equals(tcb.getProductType())
|
||||
&& "CLEAN_LEASE_MONEY".equals(key)) {
|
||||
temp = new BigDecimal(con.getAttribute("EQUIP_AMT").getDouble());
|
||||
} else if("UNITE_MONEY_OUT".equals(key)){
|
||||
@ -204,7 +234,7 @@ public class FundFundPlanExecutor {
|
||||
}else{
|
||||
temp = new BigDecimal(con.getAttribute(key).getDouble());
|
||||
}
|
||||
|
||||
|
||||
Item item = null;
|
||||
for(Item it : items) {
|
||||
if(key.equals(it.getRelativeCode())) {
|
||||
@ -212,7 +242,7 @@ public class FundFundPlanExecutor {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//BizObject item=JBOFactory.createBizObjectQuery(CODE_LIBRARY.CLASS_NAME, sql).setParameter("code", entry.getKey()).getSingleResult(false);
|
||||
if (item!=null && temp.compareTo(BigDecimal.ZERO)>0) {
|
||||
FundPlanBean ffcp = new FundPlanBean();
|
||||
@ -224,7 +254,7 @@ public class FundFundPlanExecutor {
|
||||
ffcp.setId(boLFP.getAttribute("id").getString());
|
||||
bomLFP.deleteObject(boLFP);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
ffcp.setFeeType(item.getItemNo());//费用类型
|
||||
ffcp.setPlanList("1");
|
||||
@ -283,7 +313,7 @@ public class FundFundPlanExecutor {
|
||||
BizObjectManager bm=JBOFactory.getBizObjectManager(tcb.getFundFundPlan_tb(), tx);
|
||||
bm.createQuery(sql).executeUpdate();
|
||||
}
|
||||
|
||||
|
||||
//保存资金计划到表
|
||||
private void add(List<FundPlanBean> fp,TabCalBean tcb,JBOTransaction tx) throws Exception{
|
||||
com.amarsoft.awe.util.Transaction tran = com.amarsoft.awe.util.Transaction.createTransaction(tx);
|
||||
@ -341,17 +371,17 @@ public class FundFundPlanExecutor {
|
||||
fundPlan.setAttributeValue("PAY_OBJ", fund.getPayObj());
|
||||
fundPlan.setAttributeValue("SETTLE_METHOD",fund.getSettleMethod());
|
||||
fundPlan.setAttributeValue("PAY_TYPE", fund.getPayType());
|
||||
|
||||
|
||||
//联合方出资比例
|
||||
//BigDecimal unionRatio=new BigDecimal(tcb.getCb().getUnioRatio());
|
||||
//fundPlan.setAttributeValue("plan_money_union",new BigDecimal(fundPlan.getAttribute("PLAN_MONEY").getString()).multiply(unionRatio).divide(new BigDecimal(100), 2,BigDecimal.ROUND_HALF_UP).toString());
|
||||
//fundPlan.setAttributeValue("plan_money_company", new BigDecimal(fundPlan.getAttribute("PLAN_MONEY").getString()).subtract(new BigDecimal(fundPlan.getAttribute("plan_money_union").getString())).toString());
|
||||
|
||||
|
||||
bm.saveObject(fundPlan);
|
||||
}*/
|
||||
}
|
||||
|
||||
//生成抵扣保证金 保证金退还 资金计划
|
||||
|
||||
//生成抵扣保证金 保证金退还 资金计划
|
||||
private static List<FundPlanBean> splitFundFundPlan(FundRentPlanBean planBean,ConditionBean cb,String custID,String remainType,String reduceType) throws Exception{
|
||||
List<String> planDates = planBean.getPlanDateList();
|
||||
List<String> rentPlans = planBean.getRentList();
|
||||
@ -410,18 +440,19 @@ public class FundFundPlanExecutor {
|
||||
}
|
||||
return newFundPlans;
|
||||
}
|
||||
|
||||
//生成抵扣保证金 保证金退还 资金计划
|
||||
|
||||
//生成抵扣保证金 保证金退还 资金计划
|
||||
private static List<FundPlanBean> splitFundFundPlanList(FundRentPlanBean planBean,ConditionBean cb,String custID,String remainType,String reduceType) throws Exception{
|
||||
List<String> planDates = planBean.getPlanDateList();
|
||||
List<String> rentPlans = planBean.getRentList();
|
||||
//安鹏逻辑,只抵最后一期租金
|
||||
BigDecimal lastRent = new BigDecimal(rentPlans.get(rentPlans.size() - 1));
|
||||
BigDecimal cautionMoneyDeduction = new BigDecimal(cb.getCautionDeductionMoney());
|
||||
if(lastRent.compareTo(cautionMoneyDeduction) < 0) {
|
||||
cb.setCautionMoneyRemain(cautionMoneyDeduction.subtract(lastRent).toString());
|
||||
cb.setCautionDeductionMoney(lastRent.toString());
|
||||
}
|
||||
// 取消安鹏只抵最后一期逻辑 by zhulh 2021/08/19
|
||||
// BigDecimal lastRent = new BigDecimal(rentPlans.get(rentPlans.size() - 1));
|
||||
// BigDecimal cautionMoneyDeduction = new BigDecimal(cb.getCautionDeductionMoney());
|
||||
// if(lastRent.compareTo(cautionMoneyDeduction) < 0) {
|
||||
// cb.setCautionMoneyRemain(cautionMoneyDeduction.subtract(lastRent).toString());
|
||||
// cb.setCautionDeductionMoney(lastRent.toString());
|
||||
// }
|
||||
List<FundPlanBean> newFundPlans = new ArrayList<FundPlanBean>();
|
||||
if(Double.parseDouble(cb.getCautionMoneyRemain()) > 0){//退还保证金
|
||||
FundPlanBean newFundPlan=new FundPlanBean();
|
||||
@ -437,16 +468,7 @@ public class FundFundPlanExecutor {
|
||||
}
|
||||
if(Double.parseDouble(cb.getCautionDeductionMoney()) > 0){//抵扣保证金
|
||||
BigDecimal planMoney=new BigDecimal(cb.getCautionDeductionMoney());
|
||||
FundPlanBean newFundPlan=new FundPlanBean();
|
||||
newFundPlan.setFeeType(reduceType);
|
||||
newFundPlan.setPlanList("1");
|
||||
newFundPlan.setSettleMethod("payfund6");
|
||||
newFundPlan.setPayType("pay_type_out");
|
||||
newFundPlan.setPlanMoney(planMoney.toString());
|
||||
newFundPlan.setPlanDate(planDates.get(planDates.size() - 1));
|
||||
newFundPlan.setPayCust(custID);
|
||||
newFundPlans.add(newFundPlan);
|
||||
/*int planList=0;
|
||||
int planList=0;
|
||||
for(int i = planDates.size()-1 ; i >= 0 ; i--){
|
||||
planList++;
|
||||
BigDecimal rent=new BigDecimal(rentPlans.get(i));
|
||||
@ -481,7 +503,7 @@ public class FundFundPlanExecutor {
|
||||
cb.setDeductionLastPlanDate(planDates.get(i));
|
||||
break;
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}else{
|
||||
cb.setDeductionLastPlanDate(cb.getLastPlanDate());
|
||||
}
|
||||
|
||||
66
calc/com/tenwa/reckon/executor/ManageSubsectionData.java
Normal file
66
calc/com/tenwa/reckon/executor/ManageSubsectionData.java
Normal file
@ -0,0 +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<BizObject> 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";
|
||||
// }
|
||||
//
|
||||
//
|
||||
//
|
||||
//}
|
||||
@ -142,7 +142,7 @@ public class RentCalHelper {
|
||||
// if(payDayAdjust.compareTo(min) >= 0 && payDayAdjust.compareTo(max) <= 0){
|
||||
if(payDayAdjust.compareTo(max) <= 0){
|
||||
//约定终止日不能落在已汇款的租金计划的区间段
|
||||
checkSql = "select max(rp.plan_date) maxdate from LC_RENT_PLAN rp left join lc_rent_income ci on rp.id=ci.plan_id where ci.id is not null and rp.contract_id = ? and rp.payment_number=?";
|
||||
checkSql = "select max(rp.plan_date) maxdate from LC_RENT_PLAN rp left join lc_rent_income ci on rp.id=ci.plan_id where (rp.COLLECT_STATUS <> 'δÊÕ¿î' AND rp.COLLECT_STATUS IS NOT NULL AND LENGTH(rp.COLLECT_STATUS)>0 ) and ci.id is not null and rp.contract_id = ? and rp.payment_number=?";
|
||||
results = conn.executeQuery(checkSql, this.contractId,this.paymentnumber);
|
||||
String maxDate = results.get(0).get("maxdate");
|
||||
if(maxDate != null){
|
||||
|
||||
223
calc/com/tenwa/reckon/executor/SegmentedFinancingExecutor.java
Normal file
223
calc/com/tenwa/reckon/executor/SegmentedFinancingExecutor.java
Normal file
@ -0,0 +1,223 @@
|
||||
package com.tenwa.reckon.executor;
|
||||
|
||||
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 com.tenwa.comm.exception.BusinessException;
|
||||
import com.tenwa.reckon.bean.ConditionBean;
|
||||
import com.tenwa.reckon.bean.FundRentPlanBean;
|
||||
import com.tenwa.reckon.bean.TabCalBean;
|
||||
import com.tenwa.reckon.help.PlanDateServiceImpl;
|
||||
import com.tenwa.reckon.util.IrrTools;
|
||||
import com.tenwa.reckon.util.RentTools;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class SegmentedFinancingExecutor extends FundRentPlanExecutor {
|
||||
|
||||
public SegmentedFinancingExecutor(JBOTransaction tx) {
|
||||
super( tx );
|
||||
}
|
||||
|
||||
@Override
|
||||
public FundRentPlanBean create( TabCalBean tcb, Integer startList ) throws Exception {
|
||||
this.deleteRentPlan( tcb.getRentPlan_tb(), tcb, startList );
|
||||
|
||||
// 年还款次数
|
||||
String flowunid = tcb.getDocId();
|
||||
BigDecimal incomeNumberYear = new BigDecimal( tcb.getCb().getIncomeNumberYear() );
|
||||
BizObjectManager bom = JBOFactory.getBizObjectManager( "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP", tx );
|
||||
BizObjectManager bomLSRPT = JBOFactory.getBizObjectManager( "jbo.app.tenwa.calc.LC_SUBSECTION_RENT_PLAN_TEMP", tx );
|
||||
bomLSRPT.createQuery( "delete from O where flowunid = :flowunid" ).setParameter( "flowunid", flowunid ).executeUpdate();
|
||||
// 遍历分段融表
|
||||
List<BizObject> bos = bom.createQuery( "flowunid = :flowunid order by subsection_number" ).setParameter( "flowunid", flowunid )
|
||||
.getResultList( true );
|
||||
List<String> dates = new ArrayList<>();
|
||||
List<String> interests = new ArrayList<>();
|
||||
List<String> corpuss = new ArrayList<>();
|
||||
List<String> rents = new ArrayList<>();
|
||||
List<String> overCorpuss = new ArrayList<>();
|
||||
PlanDateServiceImpl pdsi = new PlanDateServiceImpl( tx );
|
||||
ConditionBean cb = tcb.getCb();
|
||||
for ( BizObject bo : bos ) {
|
||||
// 分段号
|
||||
String subsectionNumber = bo.getAttribute( "SUBSECTION_NUMBER" ).getString();
|
||||
// 融资金额
|
||||
BigDecimal cleanLeaseMoney = new BigDecimal( bo.getAttribute( "CLEAN_LEASE_MONEY" ).getString() );
|
||||
// 标准利率
|
||||
BigDecimal rate = new BigDecimal( bo.getAttribute( "RATE" ).getString() ).divide( new BigDecimal( 100 ), 20, 4 );
|
||||
// 期利率
|
||||
BigDecimal preRate = rate.divide( incomeNumberYear, 20, 4 );
|
||||
// 期次
|
||||
BigDecimal incomeNumber = new BigDecimal( bo.getAttribute( "INCOME_NUMBER" ).getString() );
|
||||
cb.setIncomeNumber( incomeNumber.intValue() );
|
||||
List<String> planDateList = pdsi.getPlanDateList( cb, null );
|
||||
if ( planDateList.size() > dates.size() ) {
|
||||
dates = planDateList;
|
||||
}
|
||||
// 贴息计算方式
|
||||
String discountCalcMethod = bo.getAttribute( "DISCOUNT_CALC_METHOD" ).getString();
|
||||
// 融资利率
|
||||
BigDecimal financingRate;
|
||||
//获取融资利率是否只读,如果只读每次计算需要更新融资利率
|
||||
String iulma =bo.getAttribute( "IS_UPDATE_LEASE_MONEY_RATIO" ).getString();
|
||||
if ( "1".equals( discountCalcMethod ) ) { // 根据利率计算贴息金额
|
||||
// 贴息后利率
|
||||
BigDecimal discountRate = new BigDecimal( bo.getAttribute( "DISCOUNT_RATE" ).getString() ).divide( new BigDecimal( 100 ), 20, 4 );
|
||||
// 期利率
|
||||
BigDecimal preDiscountRate = discountRate.divide( incomeNumberYear, 20, 4 );
|
||||
// 标准利率计算租金
|
||||
String rent = RentTools.getPMT( preRate.toString(), incomeNumber.toString(), cleanLeaseMoney.negate().toString(), "0", "0" );
|
||||
// 贴息后利率计算租金
|
||||
String afterDiscountRent = RentTools.getPMT( preDiscountRate.toString(), incomeNumber.toString(), cleanLeaseMoney.negate().toString(), "0", "0" );
|
||||
// 计算贴息
|
||||
BigDecimal discount = new BigDecimal( rent ).setScale( 2, 4 ).multiply( incomeNumber ).subtract( new BigDecimal( afterDiscountRent ).setScale( 2, 4 ).multiply( incomeNumber ) );
|
||||
bo.setAttributeValue( "DISCOUNT", discount );
|
||||
|
||||
String fr = bo.getAttribute( "FINANCING_RATE" ).getString();
|
||||
|
||||
if ( StringUtils.isEmpty( fr ) || ( iulma!=null && "Y".equals(iulma) ) ) {
|
||||
financingRate = discountRate.divide( new BigDecimal( 100 ), 20, 4 );
|
||||
bo.setAttributeValue( "FINANCING_RATE", discountRate.toString() );
|
||||
} else {
|
||||
financingRate = new BigDecimal( fr ).divide( new BigDecimal( 100 ), 20, 4 );
|
||||
}
|
||||
bo.setAttributeValue( tcb.getPlanCName(), tcb.getPlanCValue() );
|
||||
bom.saveObject( bo );
|
||||
} else if("2".equals( discountCalcMethod )) { //根据金额算利率
|
||||
// 贴息金额
|
||||
BigDecimal discount = new BigDecimal( bo.getAttribute( "DISCOUNT" ).getString() );
|
||||
// 标准利率计算租金
|
||||
String rent = RentTools.getPMT( preRate.toString(), incomeNumber.toString(), cleanLeaseMoney.negate().toString(), "0", "0" );
|
||||
// 贴息后租金
|
||||
BigDecimal afterDiscountRent = new BigDecimal( rent ).setScale( 2, 4 ).multiply( incomeNumber ).subtract( discount ).divide( incomeNumber, 2, 4 );
|
||||
List<BigDecimal> cashFlow = new ArrayList<>();
|
||||
cashFlow.add( cleanLeaseMoney.negate() );
|
||||
for ( int i = 0; i < incomeNumber.intValue(); i ++ ) {
|
||||
cashFlow.add( afterDiscountRent );
|
||||
}
|
||||
BigDecimal discountRate = getIRR( cashFlow, incomeNumberYear ).setScale( 6, 4 );
|
||||
bo.setAttributeValue( "DISCOUNT_RATE", discountRate.toString() );
|
||||
String fr = bo.getAttribute( "FINANCING_RATE" ).getString();
|
||||
if ( StringUtils.isEmpty( fr ) || ( iulma!=null && "Y".equals(iulma) ) ) {
|
||||
financingRate = discountRate.divide( new BigDecimal( 100 ), 20, 4 );
|
||||
bo.setAttributeValue( "FINANCING_RATE", discountRate.toString() );
|
||||
} else {
|
||||
financingRate = new BigDecimal( fr ).divide( new BigDecimal( 100 ), 20, 4 );
|
||||
}
|
||||
bo.setAttributeValue( tcb.getPlanCName(), tcb.getPlanCValue() );
|
||||
bom.saveObject( bo );
|
||||
}else if("3".equals( discountCalcMethod )) { // 固定值
|
||||
financingRate = new BigDecimal( bo.getAttribute( "FINANCING_RATE" ).getString() ).divide( new BigDecimal( 100 ), 20, 4 );
|
||||
} else {
|
||||
throw new BusinessException( "分段信息没有配置计算规则,无法测算!" );
|
||||
}
|
||||
//校验贴息是否在配置的区间内
|
||||
BigDecimal discountCheck = new BigDecimal( bo.getAttribute( "DISCOUNT" ).getString() );
|
||||
if ( !( discountCheck.compareTo( new BigDecimal( bo.getAttribute( "MAXIMUM_DISCOUNT" ).getString() ) ) <= 0 && discountCheck.compareTo( new BigDecimal( bo.getAttribute( "MINIMUM_DISCOUNT" ).getString() ) ) >= 0 ) ) {
|
||||
throw new BusinessException( "分段融的第"+subsectionNumber+"段的贴息金额不在产品配置的区间内!" );
|
||||
}
|
||||
|
||||
// 融资期利率
|
||||
BigDecimal preFinancingRate = financingRate.divide( incomeNumberYear, 20, 4 );
|
||||
// 实际租金
|
||||
String rent = RentTools.getPMT( preFinancingRate.toString(), incomeNumber.toString(), cleanLeaseMoney.negate().toString(), "0", "0" );
|
||||
BigDecimal r = new BigDecimal( rent ).setScale( 2, 4 );
|
||||
for ( int i = 0; i < incomeNumber.intValue(); i ++ ) {
|
||||
BigDecimal interest;
|
||||
BigDecimal corpus;
|
||||
if ( i == incomeNumber.intValue() - 1 ) {
|
||||
corpus = cleanLeaseMoney;
|
||||
if ( corpus.compareTo( r ) >= 0 ) {
|
||||
r = corpus;
|
||||
interest = BigDecimal.ZERO;
|
||||
} else {
|
||||
interest = r.subtract( corpus );
|
||||
}
|
||||
cleanLeaseMoney = BigDecimal.ZERO;
|
||||
} else {
|
||||
interest = cleanLeaseMoney.multiply( preFinancingRate ).setScale( 2, 4 );
|
||||
corpus = r.subtract( interest );
|
||||
cleanLeaseMoney = cleanLeaseMoney.subtract( corpus );
|
||||
}
|
||||
BizObject boLSRPT = bomLSRPT.newObject();
|
||||
boLSRPT.setAttributeValue( "FLOWUNID", flowunid );
|
||||
boLSRPT.setAttributeValue( tcb.getPlanCName(), tcb.getPlanCValue() );
|
||||
boLSRPT.setAttributeValue( "PLAN_LIST", i + 1 );
|
||||
boLSRPT.setAttributeValue( "PLAN_DATE", planDateList.get( i ) );
|
||||
boLSRPT.setAttributeValue( "INTEREST_DATE", planDateList.get( i ) );
|
||||
boLSRPT.setAttributeValue( "PLAN_STATUS", "未回笼" );
|
||||
boLSRPT.setAttributeValue( "RENT", r.toString() );
|
||||
boLSRPT.setAttributeValue( "CORPUS", corpus.toString() );
|
||||
boLSRPT.setAttributeValue( "INTEREST", interest.toString() );
|
||||
boLSRPT.setAttributeValue( "ALL_REMAIN_CORPUS", cleanLeaseMoney.toString() );
|
||||
boLSRPT.setAttributeValue( "CORPUS_BUSINESS", corpus.toString() );
|
||||
boLSRPT.setAttributeValue( "INTEREST_BUSINESS", interest.toString() );
|
||||
boLSRPT.setAttributeValue( "SUBSECTION_NUMBER", subsectionNumber );
|
||||
bomLSRPT.saveObject( boLSRPT );
|
||||
if ( interests.size() > i ) {
|
||||
interests.set( i, new BigDecimal( interests.get( i ) ).add( interest ).toString() );
|
||||
corpuss.set( i, new BigDecimal( corpuss.get( i ) ).add( corpus ).toString() );
|
||||
overCorpuss.set( i, new BigDecimal( overCorpuss.get( i ) ).add( cleanLeaseMoney ).toString() );
|
||||
rents.set( i, new BigDecimal( rents.get( i ) ).add( r ).toString() );
|
||||
} else {
|
||||
interests.add( interest.toString() );
|
||||
corpuss.add( corpus.toString() );
|
||||
overCorpuss.add( cleanLeaseMoney.toString() );
|
||||
rents.add( r.toString() );
|
||||
}
|
||||
}
|
||||
}
|
||||
FundRentPlanBean fundRentPlanBean = new FundRentPlanBean();
|
||||
fundRentPlanBean.setCorpusOverageBusinessList( overCorpuss );
|
||||
fundRentPlanBean.setCorpusBusinessList( corpuss );
|
||||
fundRentPlanBean.setInterestBusinessList( interests );
|
||||
fundRentPlanBean.setPlanDateList( dates );
|
||||
fundRentPlanBean.setRentList( rents );
|
||||
|
||||
this.addRentPlan( fundRentPlanBean, tcb, startList );
|
||||
return fundRentPlanBean;
|
||||
}
|
||||
|
||||
public static BigDecimal getIRR( List cashFlows, BigDecimal incomeNumberYear ) {
|
||||
List<BigDecimal> cashFlow = new ArrayList<>();
|
||||
for ( int o = 0; o < cashFlows.size(); o ++ ) {
|
||||
Object obj = cashFlows.get( o );
|
||||
if ( obj instanceof BigDecimal ) {
|
||||
cashFlow.add( ( BigDecimal ) obj );
|
||||
} else {
|
||||
cashFlow.add( new BigDecimal( obj.toString() ) );
|
||||
}
|
||||
}
|
||||
BigDecimal up = BigDecimal.ONE;
|
||||
BigDecimal down = BigDecimal.ZERO;
|
||||
BigDecimal two = new BigDecimal( "2" );
|
||||
BigDecimal irr = new BigDecimal( "0.01" );
|
||||
BigDecimal accuracy = new BigDecimal( "0.0000001" );
|
||||
BigDecimal out;
|
||||
|
||||
int i = 0;
|
||||
while ( irr.abs().compareTo( accuracy ) > 0 && i < 200 ) {
|
||||
out = cashFlow.get( 0 );
|
||||
for ( int j = 1; j < cashFlow.size(); j ++ ) {
|
||||
out = out.add( cashFlow.get( j ).divide( new BigDecimal( Math.pow( BigDecimal.ONE.add( irr ).doubleValue(), j ) ), 20, 4 ) );
|
||||
}
|
||||
|
||||
if ( out.compareTo( BigDecimal.ZERO ) > 0 ) {
|
||||
down = irr;
|
||||
irr = irr.add( up ).divide( two, 20, 4 );
|
||||
} else if ( out.compareTo( BigDecimal.ZERO ) < 0 ) {
|
||||
up = irr;
|
||||
irr = irr.add( down ).divide( two, 20, 4 );
|
||||
}
|
||||
i ++;
|
||||
}
|
||||
irr = irr.multiply( incomeNumberYear ).multiply( new BigDecimal( 100 ) );
|
||||
|
||||
return irr;
|
||||
}
|
||||
}
|
||||
@ -4,46 +4,7 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import jbo.app.tenwa.calc.LC_CALC_CONDITION;
|
||||
import jbo.app.tenwa.calc.LC_CALC_CONDITION_HIS;
|
||||
import jbo.app.tenwa.calc.LC_CALC_CONDITION_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_CALC_PERIOD;
|
||||
import jbo.app.tenwa.calc.LC_CALC_PERIOD_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_CALC_RULES;
|
||||
import jbo.app.tenwa.calc.LC_CALC_RULES_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_CALC_SUBSECTION;
|
||||
import jbo.app.tenwa.calc.LC_CALC_SUBSECTION_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_CASH_FLOW;
|
||||
import jbo.app.tenwa.calc.LC_CASH_FLOW_HIS;
|
||||
import jbo.app.tenwa.calc.LC_CASH_FLOW_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_CASH_FLOW;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_CONDITION;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_PERIOD;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_RENT_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_RULES;
|
||||
import jbo.app.tenwa.calc.LC_CONTRACT_SUBSECTION;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_CASH_FLOW;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_CONDITION;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_PERIOD;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_RENT_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_RULES;
|
||||
import jbo.app.tenwa.calc.LC_CUSTOMER_SUBSECTION;
|
||||
import jbo.app.tenwa.calc.LC_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_FUND_PLAN_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_PAY_CASH_FLOW;
|
||||
import jbo.app.tenwa.calc.LC_PAY_RENT_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_CASH_FLOW;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_CONDITION;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_PERIOD;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_RENT_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_RULES;
|
||||
import jbo.app.tenwa.calc.LC_PROJ_SUBSECTION;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN_HIS;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN_TEMP;
|
||||
import jbo.app.tenwa.calc.*;
|
||||
import jbo.com.tenwa.entity.comm.flow.FLOW_BUSSINESS_OBJECT;
|
||||
import jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO_TEMP;
|
||||
import jbo.com.tenwa.lease.comm.LB_PROJECT_INFO;
|
||||
@ -70,14 +31,14 @@ public class CalcConditionCopyService {
|
||||
public void custToTemp(String flowunid,String quotid,String planCName,String planCValue,JBOTransaction tx) throws JBOException, RecordNotFoundException, Exception{
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("quot_id", quotid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
otherProperty.put(planCName, planCValue);
|
||||
|
||||
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put(planCName, planCValue);
|
||||
|
||||
|
||||
//商务条件
|
||||
DataOperatorUtil.copyJBOSet(LC_CUSTOMER_CONDITION.CLASS_NAME, fromCondition,LC_CALC_CONDITION_TEMP.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//测算租金规则
|
||||
@ -93,22 +54,22 @@ public class CalcConditionCopyService {
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CUSTOMER_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//临时表到项目表
|
||||
public void tempToProj(String flowunid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
BizObject flow=JBOFactory.createBizObjectQuery(FLOW_BUSSINESS_OBJECT.CLASS_NAME,"flow_unid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false);
|
||||
|
||||
|
||||
String projid=flow.getAttribute("proj_id").getString();
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("FLOWUNID", flowunid);
|
||||
|
||||
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put("PROJECT_ID", projid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("project_id", projid);
|
||||
//商务条件
|
||||
@ -126,15 +87,19 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_TEMP.CLASS_NAME, fromCondition, LC_PROJ_SUBSECTION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//前提条件
|
||||
DataOperatorUtil.copyJBOSet(LC_CONDITION_TEMP.CLASS_NAME, fromCondition, LC_CONDITION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_PROJ_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_PROJ_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
}
|
||||
|
||||
|
||||
//项目表到临时表
|
||||
public void porjToTemp(String flowunid,String projid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("PROJECT_ID", projid);
|
||||
|
||||
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
//商务条件
|
||||
@ -153,39 +118,42 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//前提条件
|
||||
DataOperatorUtil.copyJBOSet(LC_CONDITION.CLASS_NAME, fromCondition, LC_CONDITION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
}
|
||||
//项目表到合同临时表
|
||||
public void projToContract(String flowunid,String projid,String contractid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
|
||||
|
||||
BizObject proj=JBOFactory.createBizObjectQuery(LB_PROJECT_INFO.CLASS_NAME,"id=:id").setParameter("id", projid).getSingleResult(false);
|
||||
String project_id=proj.getAttribute("project_no").getString();//项目编号
|
||||
|
||||
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("PROJECT_ID", projid);
|
||||
List<BizObject> list=DataOperatorUtil.getSetJBO(LC_PROJ_CONDITION.CLASS_NAME, fromCondition, tx);
|
||||
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
|
||||
|
||||
for(BizObject bo:list){
|
||||
|
||||
|
||||
|
||||
String projPlanNumber=bo.getAttribute("PROJECT_PLAN_NUMBER").getString();
|
||||
|
||||
|
||||
String contractPlanNumber=projPlanNumber.replace(project_id, contractid);
|
||||
|
||||
|
||||
fromCondition.clear();
|
||||
fromCondition.put("PROJECT_ID", projid);
|
||||
fromCondition.put("PROJECT_PLAN_NUMBER", projPlanNumber);
|
||||
|
||||
|
||||
otherProperty.clear();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
otherProperty.put("CONTRACT_PLAN_NUMBER", contractPlanNumber);
|
||||
|
||||
|
||||
//商务条件
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_CONDITION.CLASS_NAME, fromCondition,LC_CALC_CONDITION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//测算租金规则
|
||||
@ -200,28 +168,31 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_PERIOD.CLASS_NAME, fromCondition, LC_CALC_PERIOD_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_PROJ_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
otherProperty.clear();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
otherProperty.put("PLAN_NUMBER", contractPlanNumber);
|
||||
//付款前提
|
||||
DataOperatorUtil.copyJBOSet(LC_PAY_CONDTION.CLASS_NAME, fromCondition, LC_PAY_CONDTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
|
||||
}
|
||||
}
|
||||
//合同层 单次起租 临时 到正式
|
||||
public void tempToContractOne(String flowunid,String contractid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
BizObject contract=JBOFactory.createBizObjectQuery(LB_CONTRACT_INFO_TEMP.CLASS_NAME,"flowunid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false);
|
||||
|
||||
|
||||
String paymentNumber=SerialNumberUtil.getPlannumber(contract.getAttribute("CONTRACT_NO").getString(),"pay_process", tx);
|
||||
|
||||
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("FLOWUNID", flowunid);
|
||||
|
||||
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put("contract_id", contractid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("contract_id", contractid);
|
||||
otherProperty.put("PAYMENT_NUMBER", paymentNumber);
|
||||
@ -239,7 +210,10 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_PERIOD.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
//商务条件
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_CONDITION_TEMP.CLASS_NAME, fromCondition,LC_CALC_CONDITION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
@ -255,22 +229,27 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD_TEMP.CLASS_NAME, fromCondition, LC_CALC_PERIOD.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_TEMP.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
//付款前提
|
||||
LeaseFlowBaseService service=new LeaseFlowBaseServiceImp();
|
||||
service.copyOrLoadPayCondtionInfo(tx, fromCondition,toCondition,otherProperty, ServiceOperatorEnum.TempToFormal,null);
|
||||
|
||||
|
||||
HandlingApportionManager.setSingleHandlingApportion(flowunid,contractid,paymentNumber,tx);
|
||||
}
|
||||
|
||||
|
||||
//合同层 多次起租 临时 到正式
|
||||
public void tempToContractMany(String flowunid,String contractid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("FLOWUNID", flowunid);
|
||||
|
||||
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put("contract_id", contractid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("contract_id", contractid);
|
||||
//商务条件
|
||||
@ -287,17 +266,22 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_PERIOD.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_CONTRACT_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
//付款前提
|
||||
LeaseFlowBaseService service=new LeaseFlowBaseServiceImp();
|
||||
service.copyOrLoadPayCondtionInfo(tx, fromCondition,toCondition,otherProperty, ServiceOperatorEnum.TempToFormal,null);
|
||||
}
|
||||
|
||||
|
||||
//合同正式到临时
|
||||
public void contractTotemp(String flowunid,String contractid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("contract_id", contractid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
//商务条件
|
||||
@ -314,21 +298,26 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CONTRACT_PERIOD.CLASS_NAME, fromCondition, LC_CALC_PERIOD_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CONTRACT_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CONTRACT_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CONTRACT_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
|
||||
}
|
||||
|
||||
|
||||
//临时到投放
|
||||
public void tempToPay(String flowunid,String paymentNumber,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
BizObject flow=JBOFactory.createBizObjectQuery(FLOW_BUSSINESS_OBJECT.CLASS_NAME,"flow_unid=:flowunid").setParameter("flowunid", flowunid).getSingleResult(false);
|
||||
|
||||
|
||||
String contractid=flow.getAttribute("contract_id").getString();
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
fromCondition.put("flowunid", flowunid);
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("contract_id", contractid);
|
||||
//商务条件
|
||||
@ -345,15 +334,19 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD_TEMP.CLASS_NAME, fromCondition, LC_CALC_PERIOD.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_TEMP.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
HandlingApportionManager.setHandlingApportion(flowunid,contractid,paymentNumber,tx);
|
||||
}
|
||||
//投放到临时
|
||||
public void payToTemp(String flowunid,String paymentNumber,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
//商务条件
|
||||
@ -370,21 +363,24 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD.CLASS_NAME, fromCondition, LC_CALC_PERIOD_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
}
|
||||
//临时到起租
|
||||
public void tempToOnhire(String flowunid,String paymentNumber,String contractid,JBOTransaction tx) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("FLOWUNID", flowunid);
|
||||
fromCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
|
||||
|
||||
Map<String,String> toCondition=new HashMap<String, String>();
|
||||
toCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("contract_id", contractid);
|
||||
|
||||
|
||||
CalcRentCompare com=new CalcRentCompare();
|
||||
//商务条件
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_CONDITION_TEMP.CLASS_NAME, fromCondition,LC_CALC_CONDITION.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
@ -394,14 +390,18 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_FUND_PLAN_TEMP.CLASS_NAME, fromCondition,LC_FUND_PLAN.CLASS_NAME, toCondition, otherProperty, com, tx);
|
||||
//现金流
|
||||
DataOperatorUtil.copyJBOSet(LC_CASH_FLOW_TEMP.CLASS_NAME, fromCondition, LC_CASH_FLOW.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN.CLASS_NAME, toCondition, otherProperty, null, tx);
|
||||
|
||||
//HandlingApportionManager.setHandlingApportion(flowunid,contractid,paymentNumber,tx);
|
||||
}
|
||||
//起租到临时
|
||||
public void onhireToTemp(String flowunid,String paymentNumber,JBOTransaction tx) throws Exception{
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("PAYMENT_NUMBER", paymentNumber);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
//商务条件
|
||||
@ -418,13 +418,17 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD.CLASS_NAME, fromCondition, LC_CALC_PERIOD_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
}
|
||||
|
||||
|
||||
//起租到临时
|
||||
public void onhireToTempList(String flowunid,String contractid,JBOTransaction tx) throws Exception{
|
||||
Map<String,String> fromCondition=new HashMap<String, String>();
|
||||
fromCondition.put("contract_id", contractid);
|
||||
|
||||
|
||||
Map<String,String> otherProperty=new HashMap<String, String>();
|
||||
otherProperty.put("FLOWUNID", flowunid);
|
||||
//商务条件
|
||||
@ -450,6 +454,10 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_PERIOD.CLASS_NAME, fromCondition, LC_CALC_PERIOD_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
//分段测算
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_TEMP.CLASS_NAME, null, otherProperty, null, tx);
|
||||
}
|
||||
//租金计划历史
|
||||
public void onhireToHis(String flowunid,String paymentNumber,JBOTransaction tx) throws Exception{
|
||||
@ -463,6 +471,10 @@ public class CalcConditionCopyService {
|
||||
DataOperatorUtil.copyJBOSet(LC_RENT_PLAN.CLASS_NAME, fromCondition,LC_RENT_PLAN_HIS.CLASS_NAME, null, other, null, tx);
|
||||
//现金流
|
||||
DataOperatorUtil.copyJBOSet(LC_CASH_FLOW.CLASS_NAME, fromCondition, LC_CASH_FLOW_HIS.CLASS_NAME, null, other, null, tx);
|
||||
// 分段融导表
|
||||
DataOperatorUtil.copyJBOSet(LC_CALC_SUBSECTION_INFO.CLASS_NAME, fromCondition, LC_CALC_SUBSECTION_INFO_HIS.CLASS_NAME, null, other, null, tx);
|
||||
// 分段租金计划导表
|
||||
DataOperatorUtil.copyJBOSet(LC_SUBSECTION_RENT_PLAN.CLASS_NAME, fromCondition, LC_SUBSECTION_RENT_PLAN_HIS.CLASS_NAME, null, other, null, tx);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -81,7 +81,9 @@ public class ConditionHelper {
|
||||
//更新保证金抵扣
|
||||
params.put("CAUTION_DEDUCTION_MONEY",cb.getCautionDeductionMoney());
|
||||
params.put("CAUTION_MONEY_REMAIN",cb.getCautionMoneyRemain());
|
||||
|
||||
if( "segmented_financing".equals( cb.getSettleMethod() ) ){
|
||||
params.put( "COMPREHENSIVE_RATE",cb.getComprehensiveRate() );
|
||||
}
|
||||
if ( "Y".equals( cb.getFlexible() ) ) {
|
||||
// 灵活产品计算其他项
|
||||
try {
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.tenwa.reckon.product;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Calendar;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
@ -7,6 +8,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 +34,13 @@ public class ProductCondition {
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public String getProductRules(ASObjectModel doTemp,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
public String getProductRules(ASObjectModel doTemp, String productId, Vector<ValidateRule> 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 +52,7 @@ public class ProductCondition {
|
||||
this.getCautionRatio(doTemp, productId);//保证金比例
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
public String getProductRulesBusiness(ASObjectModel doTemp,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
doTemp.setDefaultValue("LEASE_AMT_DATE", DateUtil.getToday());
|
||||
StringBuilder sb=new StringBuilder();
|
||||
@ -68,7 +70,7 @@ public class ProductCondition {
|
||||
this.getCautionRatio(doTemp, productId);//保证金比例
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
public String getProductRulesApp(List<Map<String, Object>> appList,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
ProductBaseLoanTools.addAppList(appList, "LEASE_AMT_DATE", "coldefaultvalue", DateUtil.getToday());
|
||||
StringBuilder sb=new StringBuilder();
|
||||
@ -86,12 +88,12 @@ public class ProductCondition {
|
||||
this.getCautionRatioApp(appList, productId);//保证金比例
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 设置日期
|
||||
* @param doTemp
|
||||
* @param productId
|
||||
* @throws Exception
|
||||
* @throws Exception
|
||||
*/
|
||||
public void setDateRule(ASObjectModel doTemp,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0340");
|
||||
@ -116,7 +118,7 @@ public class ProductCondition {
|
||||
doTemp.setColumnAttribute("PLAN_DATE_HOILDAY", "colvisible", "1");
|
||||
doTemp.setColumnAttribute("PLAN_DATE_HOILDAY", "colrequired", "1");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
if(map.containsKey("InterestDate")){//计息日
|
||||
@ -140,7 +142,7 @@ public class ProductCondition {
|
||||
doTemp.setColumnAttribute("INTEREST_DATE_HOLIDAY", "colvisible", "1");
|
||||
doTemp.setColumnAttribute("INTEREST_DATE_HOLIDAY", "colrequired", "1");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
if(map.containsKey("RateInfo")){
|
||||
@ -148,7 +150,7 @@ public class ProductCondition {
|
||||
doTemp.setDefaultValue("ADDITIONAL_RATE", map.get("RateInfo").get("AdditionalRate"));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void setDateRuleApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0340");
|
||||
Map<String, Object> PLAN_DATE_HOILDAY = new HashMap<String, Object>();
|
||||
@ -195,7 +197,7 @@ public class ProductCondition {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(map.containsKey("InterestDate")){//计息日
|
||||
Map<String,String> plandatemap=map.get("InterestDate");
|
||||
if(plandatemap.containsKey("HolidayAdjust")){
|
||||
@ -208,7 +210,7 @@ public class ProductCondition {
|
||||
if(plandatemap.containsKey("date_proc")){
|
||||
String s=plandatemap.get("date_proc");
|
||||
if(s.indexOf("1")>=0){
|
||||
|
||||
|
||||
FIRST_INTEREST_DATE.put("colvisible", "1");
|
||||
FIRST_INTEREST_DATE.put("colrequired", "1");
|
||||
appList.add(FIRST_INTEREST_DATE);
|
||||
@ -223,7 +225,7 @@ public class ProductCondition {
|
||||
INTEREST_DATE_HOLIDAY.put("colrequired", "1");
|
||||
appList.add(INTEREST_DATE_HOLIDAY);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
if(map.containsKey("RateInfo")){
|
||||
@ -233,7 +235,7 @@ public class ProductCondition {
|
||||
appList.add(ADDITIONAL_RATE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 项目粗利 净融资额 期初付款总计 是否显示
|
||||
* @param doTemp
|
||||
@ -267,12 +269,12 @@ public class ProductCondition {
|
||||
ProductBaseLoanTools.addAppList(appList, "FIRST_PAYMENT_TOTAL", "colvisible", "0");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 设置租金推算方法 下拉选项
|
||||
* @param doTemp
|
||||
* @param productId
|
||||
* @throws Exception
|
||||
* @throws Exception
|
||||
*/
|
||||
public void setRentOrRate(ASObjectModel doTemp,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0310");
|
||||
@ -287,10 +289,10 @@ public class ProductCondition {
|
||||
doTemp.setColumnAttribute("RENT_OR_RATE","coleditsource","jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='rent_or_rate' and itemno in ("+s+") order by sortno");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
public void setRentOrRateApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0310");
|
||||
if(map.containsKey("ROR01")){
|
||||
@ -305,10 +307,10 @@ public class ProductCondition {
|
||||
+ "itemno,itemname,codeno='rent_or_rate' and itemno in ("+s+") order by sortno");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取产品配置的资金项
|
||||
* @param productId
|
||||
@ -338,7 +340,7 @@ public class ProductCondition {
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取产品 资金类型 配置 显示页面
|
||||
* @param doTemp
|
||||
@ -371,7 +373,7 @@ public class ProductCondition {
|
||||
if(!"".equals(cautionMoneymethod)&&cautionMoneymethod!=null){
|
||||
doTemp.setDefaultValue("CAUTION_MONEY_METHOD",cautionMoneymethod);
|
||||
}
|
||||
|
||||
|
||||
if("Y".equals(fina)){
|
||||
fina = "finatype02";
|
||||
}else {
|
||||
@ -420,7 +422,7 @@ public class ProductCondition {
|
||||
sb.append("}");
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public String getProductFundRulesApp(List<Map<String, Object>> appList,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
StringBuilder sb=new StringBuilder();
|
||||
@ -442,7 +444,7 @@ public class ProductCondition {
|
||||
if(!"".equals(cautionMoneymethod)&&cautionMoneymethod!=null){
|
||||
ProductBaseLoanTools.addAppList(appList, "CAUTION_MONEY_METHOD", "coldefaultvalue", cautionMoneymethod);
|
||||
}
|
||||
|
||||
|
||||
if("Y".equals(fina)){
|
||||
fina = "finatype02";
|
||||
}else {
|
||||
@ -459,7 +461,7 @@ public class ProductCondition {
|
||||
ProductBaseLoanTools.addAppList(appList, col+"_FINA", "colvisible", "0");
|
||||
}
|
||||
ProductBaseLoanTools.addAppList(appList, col, "colvisible", "0");
|
||||
|
||||
|
||||
if(fee.getAttribute("itemno").getString().equals("feetype2")){
|
||||
ProductBaseLoanTools.addAppList(appList, "CAUTION_DEDUCTION_MONEY", "colvisible", "0");
|
||||
ProductBaseLoanTools.addAppList(appList, "CAUTION_MONEY_REMAIN", "colvisible", "0");
|
||||
@ -495,7 +497,7 @@ public class ProductCondition {
|
||||
sb.append("}");
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 宽限期最大值
|
||||
* @param doTemp
|
||||
@ -504,7 +506,7 @@ public class ProductCondition {
|
||||
* @throws Exception
|
||||
*/
|
||||
public String getProductGraceRules(ASObjectModel doTemp,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> rule=new HashMap<String, String>();
|
||||
//获取产品其它
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0311");
|
||||
@ -524,9 +526,9 @@ public class ProductCondition {
|
||||
}
|
||||
return FileOperatorUtil.getMapToJsonStr(rule);
|
||||
}
|
||||
|
||||
|
||||
public String getProductGraceRulesApp(List<Map<String, Object>> appList,String productId,Vector<ValidateRule> vali) throws Exception{
|
||||
|
||||
|
||||
Map<String,String> rule=new HashMap<String, String>();
|
||||
//获取产品其它
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0311");
|
||||
@ -549,10 +551,10 @@ public class ProductCondition {
|
||||
* 设置 第一期还款计划 第二期还款计划 期末余值 是否显示
|
||||
* @param doTemp
|
||||
* @param productId
|
||||
* @throws Exception
|
||||
* @throws Exception
|
||||
*/
|
||||
public void getOtherRule(ASObjectModel doTemp,String productId) throws Exception{
|
||||
|
||||
|
||||
String[] param={"EQUIP_END_VALUE"};
|
||||
//获取产品其它
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0311");
|
||||
@ -562,11 +564,11 @@ public class ProductCondition {
|
||||
doTemp.setColumnAttribute(param[i], "colrequired", "1");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
public void getOtherRuleApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
|
||||
|
||||
String[] param={"EQUIP_END_VALUE"};
|
||||
//获取产品其它
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0311");
|
||||
@ -576,7 +578,7 @@ public class ProductCondition {
|
||||
ProductBaseLoanTools.addAppList(appList, param[i], "colrequired", "1");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -606,9 +608,9 @@ public class ProductCondition {
|
||||
if(attribute2!=""&&"car_product".equals(attribute2)){
|
||||
day = (bo==null)?"":bo.getAttribute("ATTR_VALUE").getString();
|
||||
}
|
||||
|
||||
|
||||
doTemp.setDefaultValue("FREE_DEFA_INTER_DAY", day);
|
||||
|
||||
|
||||
if(map.containsKey("PENALTY_RATE_DAY")){//罚息日利率
|
||||
String rate=map.get("PENALTY_RATE_DAY").get("PENALTY_RATE_DAY");
|
||||
if(rate.length()>0){
|
||||
@ -619,7 +621,7 @@ public class ProductCondition {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void getProductPenaRulesApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0308");
|
||||
/*if(map.containsKey("PFD01")){//免罚息天数
|
||||
@ -645,7 +647,7 @@ public class ProductCondition {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 设置调息规则
|
||||
* @param doTemp
|
||||
@ -666,7 +668,7 @@ public class ProductCondition {
|
||||
doTemp.setColumnAttribute("ADJUST_STYLE","coleditsource","jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='adjust_style' and itemno in ("+this.getSqlWhere(rule.get("adjust_style"))+") order by sortno");
|
||||
//调息方式
|
||||
doTemp.setColumnAttribute("ADJUST_TYPE","coleditsource","jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='adjust_type' and itemno in ("+this.getSqlWhere(rule.get("rate_float_type"))+") order by sortno");
|
||||
|
||||
|
||||
}*/
|
||||
if(null != rule.get("rate_float_type") && null != rule.get("adjust_style")) {
|
||||
//调息方式
|
||||
@ -676,7 +678,7 @@ public class ProductCondition {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void getProductAdjustRulesApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0320");
|
||||
if(map.containsKey("ADJUST_INTEREST")){
|
||||
@ -696,21 +698,21 @@ public class ProductCondition {
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public String getProductSettleRules(ASObjectModel doTemp,String productId) throws Exception{
|
||||
public String getProductSettleRules(ASObjectModel doTemp, String productId, String flowunid) throws Exception{
|
||||
|
||||
//租金计算方式
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0301");
|
||||
//分段
|
||||
Map<String,Map<String,String>> submap=ProductParamUtil.getProductComponentType(productId, "PRD0321");
|
||||
String s="";
|
||||
|
||||
|
||||
String sJson="";
|
||||
for(Map.Entry<String,Map<String,String>> entry:map.entrySet()){
|
||||
if(s.length()>0)s+=",";
|
||||
s+="'"+entry.getKey()+"'";
|
||||
if(sJson.length()>0)sJson+=",";
|
||||
sJson+="'"+entry.getKey()+"':"+FileOperatorUtil.getMapToJsonStr(entry.getValue());
|
||||
|
||||
|
||||
if(entry.getKey().equals( doTemp.getColumnAttribute("SETTLE_METHOD", "coldefaultvalue"))){
|
||||
Map<String,String> values=entry.getValue();
|
||||
if(values.containsKey("HolidayAdjust")){
|
||||
@ -746,7 +748,7 @@ public class ProductCondition {
|
||||
if(s.length()>0)s+=",";
|
||||
s+="'even_subsection'";
|
||||
}
|
||||
|
||||
|
||||
/*if(s.indexOf("even_rent") != -1) {
|
||||
s = "'even_rent'";
|
||||
} else if(s.indexOf("even_corpus") != -1) {
|
||||
@ -757,11 +759,70 @@ public class ProductCondition {
|
||||
// doTemp.setReadOnly("SETTLE_METHOD", true);
|
||||
doTemp.setColumnAttribute("SETTLE_METHOD","coleditsource","jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='settle_method' and itemno in ("+s+") order by sortno");
|
||||
doTemp.setDefaultValue("SETTLE_METHOD", s.replaceAll("'", ""));
|
||||
|
||||
|
||||
|
||||
if ( "'segmented_financing'".equals( s ) ) {
|
||||
BizObjectManager bom = JBOFactory.getBizObjectManager( "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP" );
|
||||
List<BizObject> bos = bom.createQuery( "flowunid = :flowunid" ).setParameter( "flowunid", flowunid ).getResultList( false );
|
||||
if ( bos.size() == 0 ) {
|
||||
Map<String, List<Map<String, String>>> configs = ProductParamUtil.getProductComponentDecisionTable( productId, "PRD0301",
|
||||
"Rate", "Discount", "DiscountRate", "DiscountCalcMethod", "IsBalanceLending", "DiscountCollectionPeriod", "MaximumDiscount" ,
|
||||
"isFixedDiscount","isUpdateLeaseMoneyRatio","maxLeaseMoney","MinimumDiscount","MaxincomeNumber","MinincomeNumber","MinLeaseMoney");
|
||||
List<Map<String, String>> sf = configs.get( "segmented_financing" );
|
||||
int i = 1;
|
||||
String discountCalcMethod = null ;
|
||||
for ( Map<String, String> f : sf ) {
|
||||
if(discountCalcMethod == null || discountCalcMethod.isEmpty()){
|
||||
discountCalcMethod = f.get("DiscountCalcMethod");
|
||||
}
|
||||
//String discountCalcMethod = f.get( "DiscountCalcMethod" );
|
||||
BizObject bo = bom.newObject();
|
||||
bo.setAttributeValue( "SUBSECTION_NUMBER", i );
|
||||
bo.setAttributeValue( "RATE", f.get( "Rate" ) );
|
||||
bo.setAttributeValue( "DISCOUNT_CALC_METHOD", discountCalcMethod );
|
||||
if ( "1".equals( discountCalcMethod ) ) {
|
||||
bo.setAttributeValue( "DISCOUNT_RATE", f.get( "DiscountRate" ) );
|
||||
bo.setAttributeValue( "FINANCING_RATE", f.get( "DiscountRate" ) );
|
||||
} else if( "2".equals( discountCalcMethod ) ){
|
||||
bo.setAttributeValue( "DISCOUNT", f.get( "Discount" ) );
|
||||
}else if ( "3".equals( discountCalcMethod ) ){
|
||||
bo.setAttributeValue( "DISCOUNT_RATE", f.get( "DiscountRate" ) );
|
||||
bo.setAttributeValue( "FINANCING_RATE", f.get( "DiscountRate" ) );
|
||||
bo.setAttributeValue( "DISCOUNT", f.get( "Discount" ) );
|
||||
}
|
||||
String isBalanceLending = f.get( "IsBalanceLending" );
|
||||
bo.setAttributeValue( "IS_BALANCE_LENDING", isBalanceLending );
|
||||
if ( "Y".equals( isBalanceLending ) ) {
|
||||
bo.setAttributeValue( "DISCOUNT_COLLECTION_PERIOD", "0" );
|
||||
} else {
|
||||
bo.setAttributeValue( "DISCOUNT_COLLECTION_PERIOD", f.get( "DiscountCollectionPeriod" ) );
|
||||
}
|
||||
bo.setAttributeValue( "MAXIMUM_DISCOUNT", f.get( "MaximumDiscount" ) );
|
||||
bo.setAttributeValue( "FLOWUNID", flowunid );
|
||||
//根据产品配置期次,如果配置赋值给对应的值
|
||||
String MinincomeNumber = f.get( "MinincomeNumber" );
|
||||
String MaxincomeNumber = f.get( "MaxincomeNumber" );
|
||||
if(MinincomeNumber != null && MaxincomeNumber != null && new BigDecimal(MinincomeNumber).compareTo(new BigDecimal(MaxincomeNumber))==0 ){
|
||||
bo.setAttributeValue( "IS_ONLYREAD_INCOME_NUMBER", "Y" );
|
||||
bo.setAttributeValue( "INCOME_NUMBER", MaxincomeNumber );
|
||||
}else{
|
||||
bo.setAttributeValue( "IS_ONLYREAD_INCOME_NUMBER", "N" );
|
||||
}
|
||||
bo.setAttributeValue( "MAX_INCOME_NUMBER", MaxincomeNumber );
|
||||
bo.setAttributeValue( "MIN_INCOME_NUMBER", MinincomeNumber );
|
||||
|
||||
bo.setAttributeValue( "IS_FIXED_DISCOUNT", f.get( "isFixedDiscount" ) );
|
||||
bo.setAttributeValue( "IS_UPDATE_LEASE_MONEY_RATIO", f.get( "isUpdateLeaseMoneyRatio" ) );
|
||||
bo.setAttributeValue( "MAX_LEASE_MONEY", f.get( "maxLeaseMoney" ) );
|
||||
bo.setAttributeValue( "MIN_LEASE_MONEY", f.get( "MinLeaseMoney" ) );
|
||||
bo.setAttributeValue( "MINIMUM_DISCOUNT", f.get( "MinimumDiscount" ) );
|
||||
bom.saveObject( bo );
|
||||
i ++;
|
||||
}
|
||||
}
|
||||
}
|
||||
return "{"+sJson+"}";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 设置计算方式
|
||||
* @param doTemp
|
||||
@ -776,14 +837,14 @@ public class ProductCondition {
|
||||
//分段
|
||||
Map<String,Map<String,String>> submap=ProductParamUtil.getProductComponentType(productId, "PRD0321");
|
||||
String s="";
|
||||
|
||||
|
||||
String sJson="";
|
||||
for(Map.Entry<String,Map<String,String>> entry:map.entrySet()){
|
||||
if(s.length()>0)s+=",";
|
||||
s+="'"+entry.getKey()+"'";
|
||||
if(sJson.length()>0)sJson+=",";
|
||||
sJson+="'"+entry.getKey()+"':"+FileOperatorUtil.getMapToJsonStr(entry.getValue());
|
||||
|
||||
|
||||
if(entry.getKey().equals( doTemp.getColumnAttribute("SETTLE_METHOD", "coldefaultvalue"))){
|
||||
Map<String,String> values=entry.getValue();
|
||||
if(values.containsKey("HolidayAdjust")){
|
||||
@ -807,7 +868,7 @@ public class ProductCondition {
|
||||
if(s.length()>0)s+=",";
|
||||
s+="'even_subsection'";
|
||||
}
|
||||
|
||||
|
||||
/*if(s.indexOf("even_rent") != -1) {
|
||||
s = "'even_rent'";
|
||||
} else if(s.indexOf("even_corpus") != -1) {
|
||||
@ -818,12 +879,12 @@ public class ProductCondition {
|
||||
// doTemp.setReadOnly("SETTLE_METHOD", true);
|
||||
doTemp.setColumnAttribute("SETTLE_METHOD","coleditsource","jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='settle_method' and itemno in ("+s+") order by sortno");
|
||||
doTemp.setDefaultValue("SETTLE_METHOD", s.replaceAll("'", ""));
|
||||
|
||||
|
||||
|
||||
|
||||
return "{"+sJson+"}";
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public String getProductSettleRulesApp(List<Map<String, Object>> appList,String productId) throws Exception{
|
||||
|
||||
//租金计算方式
|
||||
@ -831,7 +892,7 @@ public class ProductCondition {
|
||||
//分段
|
||||
Map<String,Map<String,String>> submap=ProductParamUtil.getProductComponentType(productId, "PRD0321");
|
||||
String s="";
|
||||
|
||||
|
||||
String sJson="";
|
||||
for(Map.Entry<String,Map<String,String>> entry:map.entrySet()){
|
||||
if(s.length()>0)s+=",";
|
||||
@ -884,10 +945,10 @@ public class ProductCondition {
|
||||
ProductBaseLoanTools.addAppList(appList, "SETTLE_METHOD", "colreadonly", "1");
|
||||
ProductBaseLoanTools.addAppList(appList, "SETTLE_METHOD", "coleditsource", "jbo.sys.CODE_LIBRARY,itemno,itemname,codeno='settle_method' and itemno in ("+s+") order by sortno");
|
||||
ProductBaseLoanTools.addAppList(appList, "SETTLE_METHOD", "coldefaultvalue", s.replaceAll("'", ""));
|
||||
|
||||
|
||||
return "{"+sJson+"}";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取产品 资金类型 配置 添加列
|
||||
* @param doTemp
|
||||
@ -901,7 +962,7 @@ public class ProductCondition {
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0315");
|
||||
for(String key:map.keySet()){
|
||||
if(!("EQUIP_AMT".equals(key)||"FIRST_PAYMENT".equals(key))){//设备款和首付款不管
|
||||
if("feetype_test".equals(key)){//测试费用
|
||||
if("feetype_test".equals(key)){//测试费用
|
||||
doTemp.Columns.add(this.prodSer.createFeeCol(key, map.get(key)));
|
||||
doTemp.Columns.add(this.prodSer.createFeeColRatio(key, map.get(key)));
|
||||
}
|
||||
@ -909,7 +970,7 @@ public class ProductCondition {
|
||||
}
|
||||
}
|
||||
/**
|
||||
*
|
||||
*
|
||||
* APP
|
||||
* 获取产品 资金类型 配置 添加列
|
||||
* @param doTemp
|
||||
@ -922,14 +983,14 @@ public class ProductCondition {
|
||||
Map<String,Map<String,String>> map=ProductParamUtil.getProductComponentType(productId, "PRD0315");
|
||||
for(String key:map.keySet()){
|
||||
if(!("EQUIP_AMT".equals(key)||"FIRST_PAYMENT".equals(key))){//设备款和首付款不管
|
||||
if("feetype_test".equals(key)){//测试费用
|
||||
if("feetype_test".equals(key)){//测试费用
|
||||
this.prodSer.createFeeColApp(appList, key, map.get(key));
|
||||
this.prodSer.createFeeColRatioApp(appList, key, map.get(key));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public String getSqlWhere(String condition){
|
||||
String[] conds=condition.split(",");
|
||||
String s="";
|
||||
@ -939,7 +1000,7 @@ public class ProductCondition {
|
||||
}
|
||||
return s;
|
||||
}
|
||||
|
||||
|
||||
public String getIncomeNumber(String productId) throws Exception{
|
||||
StringBuilder sb=new StringBuilder();
|
||||
sb.append("{");
|
||||
@ -951,7 +1012,7 @@ public class ProductCondition {
|
||||
sb.append("}");
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
//获取期数等
|
||||
public void getCautionRatio(ASObjectModel doTemp,String productId) throws Exception{
|
||||
//测算年利率字段
|
||||
@ -965,7 +1026,7 @@ public class ProductCondition {
|
||||
// doTemp.setDefaultValue("INCOME_NUMBER",incomeNumber);
|
||||
/*String periodType = productRate.get("begin_end") == null ? "period_type_0" : productRate.get("begin_end");
|
||||
doTemp.setDefaultValue("PERIOD_TYPE",periodType)*/;
|
||||
|
||||
|
||||
String ProductType = productRate.get("ProductType") == null ? "0" : productRate.get("ProductType");
|
||||
String isReadOnly = productRate.get("ProductRateReadOnly") == null ? "Y" : productRate.get("ProductRateReadOnly");
|
||||
String YEAR_RATE = productRate.get("ProductRate") == null ? "0" : productRate.get("ProductRate");
|
||||
@ -979,7 +1040,7 @@ public class ProductCondition {
|
||||
doTemp.setDefaultValue("YEAR_RATE",YEAR_RATE);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void getCautionRatioApp(List<Map<String, Object>> appList, String productId) throws Exception{
|
||||
//测算年利率字段
|
||||
Map<String, Map<String, String>> productRates = ProductParamUtil.getProductComponentType(productId, "PRD0350");
|
||||
|
||||
@ -17,7 +17,7 @@ import com.tenwa.reckon.constant.Scale;
|
||||
import com.tenwa.reckon.exception.LeasingException;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author SHIHONGFEI
|
||||
* @version 1.0
|
||||
* @copyright (C) TENWA 2011
|
||||
@ -27,9 +27,9 @@ import com.tenwa.reckon.exception.LeasingException;
|
||||
public class IrrTools {
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 根据配置信息构建现金流执行语句,如有其它现金流信息的可在此构建时修改)
|
||||
*
|
||||
*
|
||||
* @param cfgb_list
|
||||
* @param tcb
|
||||
* @return
|
||||
@ -55,9 +55,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 得到去除重复的时间集合,返回一个含有一个时间,对应他的现金集合的下标的键值对 ,如按天则substring(0, 7)需处理)
|
||||
*
|
||||
*
|
||||
* @param ccfbList
|
||||
* @return
|
||||
*/
|
||||
@ -80,9 +80,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 根据时间得到新的现金流集合 )
|
||||
*
|
||||
*
|
||||
* @param ht_date 现金流对应日期
|
||||
* @param cdbList 现金流集合
|
||||
* @return
|
||||
@ -106,10 +106,10 @@ public class IrrTools {
|
||||
String quot_id = "";// 报价编号
|
||||
String contract_id = ""; // 合同号
|
||||
String plan_date = obj[i].toString();// 日期
|
||||
|
||||
|
||||
String fund_in = "0"; // 流入量
|
||||
String fund_in_details = ""; // 流入量清单
|
||||
|
||||
|
||||
String fund_out = "0"; // 流出量
|
||||
String fund_out_details = ""; // 流出量清单
|
||||
|
||||
@ -152,7 +152,7 @@ public class IrrTools {
|
||||
|
||||
/**
|
||||
* 根据租金现金流,偿还间隔,租金间隔,年还款次数测算irr
|
||||
*
|
||||
*
|
||||
* @param l_inflow_pour所有现金流入流出
|
||||
* @param chjg偿还间隔
|
||||
* @param zjjg租金间隔
|
||||
@ -235,7 +235,7 @@ public class IrrTools {
|
||||
/**
|
||||
* XIRR计算公式 参数1 l_inflow_pour 是对于的现金流,参数2l_date 是对于的现金流时间 这个需要一一对于. <br>
|
||||
* 这个算法对于的是EXECL中的XIRR算法.可以用于精确到日的 日IRR计算
|
||||
*
|
||||
*
|
||||
* @param l_inflow_pour
|
||||
* 现金流List
|
||||
* @param l_date
|
||||
@ -277,9 +277,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 得到保证金抵扣现金流明细)
|
||||
*
|
||||
*
|
||||
* @param rent_list
|
||||
* @param caut_money
|
||||
* @return
|
||||
@ -321,9 +321,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* 保证金抵扣金额小于保证金金额 最后要做一笔流出 为保证金金额减去保证金抵扣金额)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
* 现金流
|
||||
* @param caution_money
|
||||
@ -352,9 +352,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 得到预收租金抵扣现金流明细)
|
||||
*
|
||||
*
|
||||
* @param rent_list
|
||||
* @param rentbefore_money
|
||||
* @return
|
||||
@ -400,9 +400,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* 预收租金抵扣金额小于预收租金金额 最后要做一笔流出 为预收租金金额减去预收租金抵扣金额)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
* 现金流
|
||||
* @param Column_8
|
||||
@ -430,9 +430,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 得到可以保证金抵扣的租金下标值)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
* @param caut_money
|
||||
* @param d_total
|
||||
@ -453,10 +453,10 @@ public class IrrTools {
|
||||
int_s = int_s.indexOf(",") > -1 ? int_s.substring(0, int_s.length() - 1) : int_s;// 得到可以抵扣的租金的下标
|
||||
return int_s;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 对最后一项现金流明细进行整理,如有变更的可以重写此方法)
|
||||
* 其他情况
|
||||
* @param cdbList
|
||||
@ -471,10 +471,10 @@ public class IrrTools {
|
||||
String planDate = cdb.getPlanDate(); // 日期 (只有年月)
|
||||
String income_number_year = cb.getIncomeNumberYear();
|
||||
int onhire_id = cdb.getOnhire_id();
|
||||
|
||||
|
||||
//起租类型 注意: 期初 数字 1 字符串 period_type_1 #分割线# 期末 数字0 字符串 period_type_0
|
||||
String periodType = cb.getPeriodType();
|
||||
|
||||
|
||||
// 更新流入,净流量值 期末余值
|
||||
if ( null != equip_end_value && !"".equals(equip_end_value) && Double.parseDouble(equip_end_value) > Double.parseDouble("0.00") ) {// 期末残值大于0时
|
||||
//‘期末余值’期末情况下的统一处理方式:直接加在最后一期现金流数据中
|
||||
@ -484,53 +484,53 @@ public class IrrTools {
|
||||
cdb.setNetFlow(String.valueOf(Double.parseDouble(cdb.getNetFlow()) + Double.parseDouble(equip_end_value)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//期末购买权在月付双月付情况下在下方单独处理
|
||||
if (null != nominal_price && !"".equals(nominal_price) && Double.parseDouble(nominal_price) > Double.parseDouble("0.00") && !"income_1".equals(income_number_year) && !"income_2".equals(income_number_year) && !"6".equals(income_number_year) && !"12".equals(income_number_year) || ( "period_type_0".equals(periodType) || "0".equals(periodType) ) ) {// 期末购买权【原名称:名义货价】大于0时
|
||||
cdb.setFundIn(String.valueOf(Double.parseDouble(cdb.getFundIn()) + Double.parseDouble(nominal_price)));
|
||||
cdb.setFundInDetails(cdb.getFundInDetails() + ";期末购买权:" + NumTools.formatNumberDouble(Double.parseDouble(NumTools.formatNumberDoubleScale(nominal_price, 2))) + ";");
|
||||
cdb.setNetFlow(String.valueOf(Double.parseDouble(cdb.getNetFlow()) + Double.parseDouble(nominal_price)));
|
||||
}
|
||||
|
||||
|
||||
// 重新设置此元素的值
|
||||
cdbList.set(cdbList.size() - 1, cdb);
|
||||
|
||||
|
||||
// 处理特殊的保证金抵扣 保证金抵扣金额小于保证金金额 最后要做一笔流出 为保证金金额减去保证金抵扣金额
|
||||
cdbList = IrrTools.getRentDetailsByDeductOut(cdbList, cb.getCautionMoney(), cb.getCautionDeductionMoney());
|
||||
|
||||
|
||||
List<CashDetailsBean> new_cdbList = new ArrayList<CashDetailsBean>();
|
||||
for (CashDetailsBean obj : cdbList) {
|
||||
new_cdbList.add(obj);
|
||||
}
|
||||
|
||||
|
||||
//TODO:sea 期末购买权在月付情况下:最后一期日期加一月作为单独的一行数据,其它情况下:最后一期的日期
|
||||
|
||||
|
||||
//TODO:sea 期末购买权在月付情况下:最后一期日期加一月作为单独的一行数据,其它情况下:最后一期的日期
|
||||
//2014-06-11 期末余值新的处理逻辑:【符合】‘期末购买权月付/双月付情况’这个前提下, 期初情况的‘期末余值’与‘期末购买权’一致放在新增的一期一起作为最后一期现金流的数据
|
||||
if(null != nominal_price && !"".equals(nominal_price) && Double.parseDouble(nominal_price) > Double.parseDouble("0.00") && !Tools.isNullOrEmpty(planDate) && ( "income_1".equals(income_number_year) || "12".equals(income_number_year) || "income_2".equals(income_number_year) || "6".equals(income_number_year) ) && ("period_type_1".equals(periodType) || "1".equals(periodType)) ){//月付/双月付情况下
|
||||
//重新取一次值
|
||||
CashDetailsBean new_cdb = new CashDetailsBean();//cdbList.get(cdbList.size() - 1);
|
||||
planDate = planDate+"-01";//构建成完整的日期格式
|
||||
//2014-01-01 日期加1个月
|
||||
//2014-01-01 日期加1个月
|
||||
planDate = DateTools.getDateAdd(planDate, 1, "mm");
|
||||
new_cdb.setPlanDate(planDate.substring(0, 7)+"-01");
|
||||
new_cdb.setFundOut("0");
|
||||
new_cdb.setFundOutDetails("");
|
||||
|
||||
|
||||
new_cdb.setFundIn(String.valueOf(Double.parseDouble(nominal_price) + Double.parseDouble(equip_end_value)));
|
||||
new_cdb.setFundInDetails("期末购买权:" + NumTools.formatNumberDouble(Double.parseDouble(NumTools.formatNumberDoubleScale(nominal_price, 2))) + ";期末余值:" + NumTools.formatNumberDouble(Double.parseDouble(NumTools.formatNumberDoubleScale(equip_end_value, 2))));
|
||||
new_cdb.setNetFlow( String.valueOf( Double.parseDouble(nominal_price) + Double.parseDouble(equip_end_value) ) );
|
||||
|
||||
|
||||
new_cdb.setOnhire_id( onhire_id + 1 );//现金流按固定格式补0情况下,所以这里月付情况下,直接最后一次变量加1做为最终的期末购买权排序依据
|
||||
new_cdbList.add(new_cdb);
|
||||
}else{
|
||||
|
||||
|
||||
//TODO:2014-06-11 期末余值新的处理逻辑:【不符合】‘期末购买权月付情况’这个前提下, 期初情况的‘期末余值’与‘期末购买权’一致放在新增的一期一起作为最后一期现金流的数据
|
||||
//TODO:这里存在少处理不是月付情况,例如:季付情况下,‘期末余值’是不是不能直接最后一期加一个月,是加一个租赁间隔,是加一个季度三个月,中间需要补两个0
|
||||
if( !Tools.isNullOrEmpty(planDate) && null != equip_end_value && !"".equals(equip_end_value) && Double.parseDouble(equip_end_value) > Double.parseDouble("0.00") && ("period_type_1".equals(periodType) || "1".equals(periodType)) ){// 期初
|
||||
//重新取一次值
|
||||
CashDetailsBean new_cdb = new CashDetailsBean();//cdbList.get(cdbList.size() - 1);
|
||||
planDate = planDate+"-01";//构建成完整的日期格式
|
||||
//2014-01-01 日期加1个月
|
||||
//2014-01-01 日期加1个月
|
||||
planDate = DateTools.getDateAdd(planDate, 1, "mm");
|
||||
new_cdb.setPlanDate(planDate.substring(0, 7)+"-01");
|
||||
new_cdb.setFundOut("0");
|
||||
@ -541,13 +541,13 @@ public class IrrTools {
|
||||
new_cdb.setOnhire_id( onhire_id + 1 );//现金流按固定格式补0情况下,所以这里月付情况下,直接最后一次变量加1做为最终的期末购买权排序依据
|
||||
new_cdbList.add(new_cdb);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
return new_cdbList;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <p>对最后一项现金流明细进行整理,针对项目类型为‘VP业务’情况下,期末购买权不计算入最后一期现金流中。</p>
|
||||
* @author sea
|
||||
@ -562,31 +562,31 @@ public class IrrTools {
|
||||
// 更新流入,净流量值
|
||||
if (null != equip_end_value && !"".equals(equip_end_value) && Double.parseDouble(equip_end_value) > 0) {// 期末残值大于0时
|
||||
cdb.setFundIn(String.valueOf(Double.parseDouble(cdb.getFundIn()) + Double.parseDouble(equip_end_value)));
|
||||
|
||||
|
||||
cdb.setFundInDetails(cdb.getFundInDetails() + ";期末余值:" + NumTools.formatNumberDouble(Double.parseDouble(NumTools.formatNumberDoubleScale(equip_end_value, 2))));
|
||||
|
||||
|
||||
cdb.setNetFlow(String.valueOf(Double.parseDouble(cdb.getNetFlow()) + Double.parseDouble(equip_end_value)));
|
||||
}
|
||||
|
||||
|
||||
if (null != nominal_price && !"".equals(nominal_price) && Double.parseDouble(nominal_price) > 0) {// 期末购买权【原名称:名义货价】大于0时
|
||||
cdb.setFundIn(String.valueOf(Double.parseDouble(cdb.getFundIn()) + Double.parseDouble(nominal_price)));
|
||||
//项目类型为‘VP业务’情况下,期末购买权不算入流入中
|
||||
cdb.setFundInDetails( cdb.getFundInDetails() );
|
||||
cdb.setNetFlow( cdb.getNetFlow() );
|
||||
}
|
||||
|
||||
|
||||
// 重新设置此元素的值
|
||||
cdbList.set(cdbList.size() - 1, cdb);
|
||||
|
||||
|
||||
// 2011-10-26
|
||||
// 处理特殊的保证金抵扣 保证金抵扣金额小于保证金金额 最后要做一笔流出 为保证金金额减去保证金抵扣金额
|
||||
cdbList = IrrTools.getRentDetailsByDeductOut(cdbList, cb.getCautionMoney(), cb.getCautionDeductionMoney());
|
||||
|
||||
|
||||
return cdbList;
|
||||
|
||||
|
||||
}
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 现金流明细构建)
|
||||
* 按月计算IRR
|
||||
* @param cdbList
|
||||
@ -595,7 +595,7 @@ public class IrrTools {
|
||||
public static String getIrr(List<CashDetailsBean> cdbList) {
|
||||
// 得到租金列表
|
||||
List<String> rent_list = getRentListByCashDetails(cdbList);
|
||||
/*
|
||||
/*
|
||||
* 后三个参数为固定按月计算
|
||||
* @param chjg 固定值1
|
||||
* @param zjjg 固定值1
|
||||
@ -606,7 +606,7 @@ public class IrrTools {
|
||||
|
||||
}
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @Title: getIrr
|
||||
* @author zhangc
|
||||
* @Description: 牛顿分切法计算XIRR
|
||||
@ -624,7 +624,7 @@ public class IrrTools {
|
||||
return IrrTools.getXIRR(rent_list, planDate_list).toString();
|
||||
//return IrrTools.getIRR(rent_list, "1","1","12");
|
||||
}
|
||||
|
||||
|
||||
public static String getIrrNew( List<String> netList,List<String> dateList,String process) throws Exception {
|
||||
// 得到租金列表
|
||||
//List<String> rent_list = getRentListByCashDetails(cashlist,process);
|
||||
@ -634,9 +634,9 @@ public class IrrTools {
|
||||
//return IrrTools.getIRR(rent_list, "1","1","12");
|
||||
}
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 现金流明细构建)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
* @param cb
|
||||
* @return
|
||||
@ -651,9 +651,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 现金流明细构建)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
* @param cb
|
||||
* @return
|
||||
@ -668,9 +668,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 根据现金流明细得到新的租金列表,用于算irr值)
|
||||
*
|
||||
*
|
||||
* @param cdbList
|
||||
*/
|
||||
private static List<String> getRentListByCashDetails(List<CashDetailsBean> cdbList) {
|
||||
@ -680,7 +680,7 @@ public class IrrTools {
|
||||
}
|
||||
return rent_list;
|
||||
}
|
||||
|
||||
|
||||
private static List<String> getRentListByCashDetails(List cdbList,String process) throws Exception {
|
||||
List<String> rent_list = new ArrayList<String>();
|
||||
for (Object cdb : cdbList) {
|
||||
@ -691,12 +691,12 @@ public class IrrTools {
|
||||
}else{
|
||||
rent_list.add(((ContractCashDetailTemp)cdb).getNetFlow().toString());
|
||||
}*/
|
||||
|
||||
|
||||
rent_list.add(((BizObject)cdb).getAttribute("NET_FLOW").getString());
|
||||
}
|
||||
return rent_list;
|
||||
}
|
||||
|
||||
|
||||
private static List<String> getRentListByCashDetailsPlanDate(List cdbList,String process) throws Exception {
|
||||
List<String> rent_list = new ArrayList<String>();
|
||||
for (Object cdb : cdbList) {
|
||||
@ -706,9 +706,9 @@ public class IrrTools {
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* ( 算出均息法下的均息法租金列表的irr,并把其当做年利率传递做第二次正常租金测算)
|
||||
*
|
||||
*
|
||||
* @param cb
|
||||
* 交易结构bean
|
||||
* @param frpb
|
||||
@ -734,7 +734,7 @@ public class IrrTools {
|
||||
} else {
|
||||
l_inflow_pour.add("-" + leasing_money);
|
||||
}
|
||||
|
||||
|
||||
for (int i = grace; i < rent_list.size(); i++) {
|
||||
l_inflow_pour.add(rent_list.get(i).toString());
|
||||
}
|
||||
@ -745,16 +745,16 @@ public class IrrTools {
|
||||
l_inflow_pour.set(l_inflow_pour.size()-1, new BigDecimal(l_inflow_pour.get(l_inflow_pour.size()-1)).add(new BigDecimal(cb.getEquipEndValue())).toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
irr = IrrTools.getIRR(l_inflow_pour, String.valueOf(12 / Integer.parseInt(cb.getIncomeNumberYear())), String.valueOf(12 / Integer.parseInt(cb.getIncomeNumberYear())), cb.getIncomeNumberYear());
|
||||
irr = Double.parseDouble(irr) + "";
|
||||
return irr;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* (根据现金流获得对应的年利率)
|
||||
*
|
||||
*
|
||||
* @param alCash
|
||||
* 现金流 用HashMap key为net_flow 存的每期的值
|
||||
* @param income_number_year
|
||||
@ -770,7 +770,7 @@ public class IrrTools {
|
||||
}
|
||||
return NumTools.formatNumberDoubleScale(Double.parseDouble(getIRR(alirr, "1", "1", income_number_year)) * 100 + "", 6);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <p>根据原始现金流集合按固定模式补0构建成独特格式的现金流。</p>
|
||||
* @author sea
|
||||
@ -784,26 +784,26 @@ public class IrrTools {
|
||||
List<CashDetailsBean> list = new ArrayList<CashDetailsBean>();
|
||||
List<CashDetailsBean> cashList = new ArrayList<CashDetailsBean>();
|
||||
// 期初(期末)支付 注意: 期初 数字 1 字符串 period_type_1 #分割线# 期末 数字0 字符串 period_type_0
|
||||
String periodType = cb.getPeriodType();
|
||||
String periodType = cb.getPeriodType();
|
||||
if (ccfbList != null && ccfbList.size() > 0 && ccfbList.size() > size) {//现金流的长度如果小于2条,该方法不适用,特别是期初情况下,理论上现金流只存在一行数据了
|
||||
|
||||
|
||||
//第0期现金流集合
|
||||
CashDetailsBean objFirst = new CashDetailsBean();
|
||||
objFirst = ccfbList.get(0);//默认第0期的值等于原始现金流的第0期
|
||||
|
||||
double firstIn = 0.00;
|
||||
double firstOut = 0.00;
|
||||
|
||||
double firstIn = 0.00;
|
||||
double firstOut = 0.00;
|
||||
String firstFundInDetails = "";
|
||||
String firstFundOutDetails = "";
|
||||
for (int i = 0; i < size; i++) {
|
||||
CashDetailsBean oneObj = ccfbList.get(i);
|
||||
//第i期流入流出
|
||||
firstIn = firstIn + NumberUtils.parseDouble( NumberUtils.nullToZero( oneObj.getFundIn() ) );
|
||||
firstOut = firstOut + NumberUtils.parseDouble( NumberUtils.nullToZero( oneObj.getFundOut() ) );
|
||||
firstIn = firstIn + NumberUtils.parseDouble( NumberUtils.nullToZero( oneObj.getFundIn() ) );
|
||||
firstOut = firstOut + NumberUtils.parseDouble( NumberUtils.nullToZero( oneObj.getFundOut() ) );
|
||||
firstFundInDetails = firstFundInDetails +oneObj.getFundInDetails();
|
||||
firstFundOutDetails = firstFundOutDetails+oneObj.getFundOutDetails();
|
||||
}
|
||||
|
||||
|
||||
//期初前收情况下:做合并处理
|
||||
if("1".equals(periodType) || "period_type_1".equals(periodType)){
|
||||
//封装新的第0期
|
||||
@ -816,7 +816,7 @@ public class IrrTools {
|
||||
objFirst.setNetFlow(NumberUtils.doubleToString( firstIn + firstRent - firstOut ) );
|
||||
objFirst.setOnhire_id(1000);
|
||||
cashList.add(objFirst);
|
||||
|
||||
|
||||
//封装后续所有现金流
|
||||
int key = 2;
|
||||
int onhire_id = 1000;
|
||||
@ -868,7 +868,7 @@ public class IrrTools {
|
||||
}
|
||||
return cashList;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <p>计算固定格式情况现金流补0个数。</p>
|
||||
* @author sea
|
||||
@ -894,7 +894,7 @@ public class IrrTools {
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <p>生成补0的现金流对象。</p>
|
||||
* @author sea
|
||||
@ -915,14 +915,14 @@ public class IrrTools {
|
||||
newObj.setOnhire_id(onhire_id);
|
||||
return newObj;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 牛顿迭代法求IRR
|
||||
* @param cashList:现金流List
|
||||
* @return IRR
|
||||
*/
|
||||
public BigDecimal getIRR(List<BigDecimal> cashList){
|
||||
public static BigDecimal getIRR(List<BigDecimal> cashList){
|
||||
//long startTime = System.currentTimeMillis();
|
||||
BigDecimal diff = BigDecimal.ONE; //租金现值总和与总本金的差值
|
||||
BigDecimal irr = BigDecimal.ZERO;
|
||||
@ -970,7 +970,7 @@ public class IrrTools {
|
||||
BigDecimal daoRate=BigDecimal.ZERO; // 1/(1+irr)
|
||||
BigDecimal netflowNow; //净流量现值
|
||||
BigDecimal error = new BigDecimal("0.0000000001"); //误差
|
||||
int size = cashList.size(); //现金流大小
|
||||
int size = cashList.size(); //现金流大小
|
||||
int j = 0; //迭代次数
|
||||
double k = 0;
|
||||
String startDate = "";
|
||||
@ -990,7 +990,7 @@ public class IrrTools {
|
||||
}catch(Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
j++;
|
||||
irr = irr.subtract(diff.divide(derivative, 20, BigDecimal.ROUND_HALF_UP)); //迭代关系式
|
||||
|
||||
8
config/cgb.properties
Normal file
8
config/cgb.properties
Normal file
@ -0,0 +1,8 @@
|
||||
#客户号
|
||||
cifMaster=60000002922
|
||||
#操作员
|
||||
entUserId=100001
|
||||
#操作密码
|
||||
password=1q2w3e4r
|
||||
#前置机地址
|
||||
cgbUrl=http://114.242.219.170:63312/CGBClient/BankAction
|
||||
@ -691,7 +691,7 @@ public class FlowAction {
|
||||
sql.setOriginalSql(sql.getOriginalSql().replaceAll("¡÷", ":"));
|
||||
sql.setRunSql(sql.getRunSql().replaceAll("¡÷", ":"));
|
||||
tran.executeSQL(sql);
|
||||
sql = new SqlObject("update user_task_info set task_number = nvl(task_number, 0) + 1 "
|
||||
sql = new SqlObject("update user_task_info set task_number = task_number + 1 "
|
||||
+ " where userid = '" + AssignmentId + "' and roleid = '" + curRole + "'");
|
||||
tran.executeSQL(sql);
|
||||
} else {
|
||||
@ -703,8 +703,8 @@ public class FlowAction {
|
||||
sql.setOriginalSql(sql.getOriginalSql().replaceAll("¡÷", ":"));
|
||||
sql.setRunSql(sql.getRunSql().replaceAll("¡÷", ":"));
|
||||
tran.executeSQL(sql);
|
||||
sql = new SqlObject("update user_task_info set task_number = nvl(task_number, 0) - 1 "
|
||||
+ " where userid = '" + userID + "' and roleid = '" + curRole + "'");
|
||||
sql = new SqlObject("update user_task_info set task_number = task_number - 1 "
|
||||
+ " where userid = '" + userID + "' and roleid = '" + curRole + "' and task_number >=1 ");
|
||||
tran.executeSQL(sql);
|
||||
}
|
||||
}
|
||||
|
||||
@ -19,7 +19,7 @@ import com.amarsoft.are.jbo.JBOTransaction;
|
||||
|
||||
public class AllinpayPaymentDo {
|
||||
private String id;
|
||||
|
||||
|
||||
/**
|
||||
* 批量代收-发送请求
|
||||
* @param tx
|
||||
@ -103,8 +103,7 @@ public class AllinpayPaymentDo {
|
||||
new Thread(run).start();
|
||||
}
|
||||
public void queryCollectResult(){
|
||||
AllinpayPaymentQueryRun run = new AllinpayPaymentQueryRun();
|
||||
new Thread(run).start();
|
||||
new AllinpayPaymentQueryRun().allinpayPaymentQuerySt();
|
||||
}
|
||||
public String getId() {
|
||||
return id;
|
||||
|
||||
@ -1,31 +1,30 @@
|
||||
package com.tenwa.lease.app.allinpay.service.impl;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import org.apache.log4j.Logger;
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
public class AllinpayPaymentQueryJob implements Job{
|
||||
private Logger logger = Logger.getLogger(this.getClass());
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
try {
|
||||
BizObjectManager manager = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_CARD_PAYMENT");
|
||||
BizObject object = manager.createQuery("O.STATUS='正在处理'").getSingleResult(true);
|
||||
if(object==null) {
|
||||
logger.info("没有需要查询的通联卡扣信息");
|
||||
return;
|
||||
}
|
||||
AllinpayPaymentQueryRun run = new AllinpayPaymentQueryRun();
|
||||
run.run();
|
||||
} catch (JBOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
public class AllinpayPaymentQueryJob implements Job {
|
||||
private Logger logger = Logger.getLogger(this.getClass());
|
||||
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
try {
|
||||
BizObjectManager manager = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_CARD_PAYMENT");
|
||||
BizObject object = manager.createQuery("O.STATUS='正在处理'").getSingleResult(true);
|
||||
if (object == null) {
|
||||
logger.info("没有需要查询的通联卡扣信息");
|
||||
return;
|
||||
}
|
||||
new AllinpayPaymentQueryRun().allinpayPaymentQuerySt();
|
||||
} catch (JBOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -1,67 +1,53 @@
|
||||
package com.tenwa.lease.app.allinpay.service.impl;
|
||||
|
||||
import java.io.BufferedWriter;
|
||||
import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.math.BigDecimal;
|
||||
import java.sql.SQLException;
|
||||
import java.text.DecimalFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
import jbo.com.tenwa.lease.comm.LB_BUCKLE_LOG;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import com.allinpay.xml.XmlParser;
|
||||
import com.allinpay.xstruct.common.AipgRsp;
|
||||
import com.allinpay.xstruct.common.InfoRsp;
|
||||
import com.allinpay.xstruct.trans.qry.QTDetail;
|
||||
import com.allinpay.xstruct.trans.qry.QTransRsp;
|
||||
import com.amarsoft.app.lc.util.DateAssistant;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.ctc.wstx.util.DataUtil;
|
||||
import com.tenwa.collectaudit.cache.CollectAuditInfoCache;
|
||||
import com.tenwa.lease.app.allinpay.util.AllinpayProperties;
|
||||
import com.tenwa.lease.app.allinpay.util.ConfigConstant;
|
||||
import com.tenwa.reckon.util.UUIDUtil;
|
||||
import jbo.app.tenwa.calc.LC_RENT_INCOME;
|
||||
import jbo.com.tenwa.lease.comm.LB_BUCKLE_LOG;
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import java.io.BufferedWriter;
|
||||
import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.math.BigDecimal;
|
||||
import java.text.DecimalFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.*;
|
||||
|
||||
|
||||
|
||||
public class AllinpayPaymentQueryRun implements Runnable{
|
||||
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
this.allinpayPaymentQuerySt();
|
||||
}
|
||||
|
||||
private AllinpayProperties allinpay;
|
||||
|
||||
|
||||
private String localFilePath;
|
||||
|
||||
private Logger logger = Logger.getLogger(this.getClass());
|
||||
|
||||
public AllinpayPaymentQueryRun() {
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页处理需要进行查询的扣款数据
|
||||
* @param
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@SuppressWarnings({ "unchecked"})
|
||||
@ -82,16 +68,16 @@ public class AllinpayPaymentQueryRun implements Runnable{
|
||||
while (size > start) {
|
||||
logger.info("开始第" + start + "至" + (start + maxCount) + "次循环");
|
||||
boLOEDs = bomLCP.createQuery("O.STATUS='正在处理' ").setFirstResult(start).setMaxResults(maxCount).getResultList(true);
|
||||
|
||||
|
||||
if (boLOEDs == null || boLOEDs.size() == 0) {
|
||||
logger.error("没有需要查询的通联支付信息>>>>>>>>>>:");
|
||||
break;
|
||||
}
|
||||
for (BizObject boLCP : boLOEDs) {
|
||||
try {
|
||||
|
||||
|
||||
BizObject object = JBOFactory.getBizObjectManager("jbo.com.tenwa.lease.comm.LB_PROJECT_INFO").createQuery("O.id=:id").setParameter("id", boLCP.getAttribute("PROJECT_ID").toString()).getSingleResult(false);
|
||||
|
||||
|
||||
allinpay = new AllinpayProperties(object.getAttribute("subjectid").toString());
|
||||
String quertSn= boLCP.getAttribute("REQ_SN").toString();
|
||||
String num = boLCP.getAttribute("NUM").toString();
|
||||
@ -101,7 +87,7 @@ public class AllinpayPaymentQueryRun implements Runnable{
|
||||
sqlMap.put("NUM", Integer.parseInt(num) + "");
|
||||
mapXml.put("quertSn", quertSn);
|
||||
sqlMap = sendMessageByProxy(mapXml, sqlMap);
|
||||
|
||||
|
||||
if (localFilePath == null) {
|
||||
LocalDateTime ldt = LocalDateTime.now();
|
||||
DateTimeFormatter dtf = DateTimeFormatter.ofPattern("yyyyMMdd");
|
||||
@ -248,7 +234,6 @@ public class AllinpayPaymentQueryRun implements Runnable{
|
||||
|
||||
/**
|
||||
* 修改通联扣款数据汇总表
|
||||
* @param map
|
||||
* @return Exception
|
||||
*/
|
||||
private void updateMessage(BizObjectManager bomLCP, BizObject boLCP, Map<String, String> sqlMap) throws Exception {
|
||||
@ -260,7 +245,7 @@ public class AllinpayPaymentQueryRun implements Runnable{
|
||||
boLCP.setAttributeValue(key, sqlMap.get(key));
|
||||
}
|
||||
bomLCP.saveObject(boLCP);
|
||||
|
||||
|
||||
updateOtherMessage(boLCP);
|
||||
}
|
||||
public void saveBuckle(BizObject bo,JBOTransaction tx,String sn,String rent) throws JBOException{
|
||||
@ -306,11 +291,11 @@ public class AllinpayPaymentQueryRun implements Runnable{
|
||||
if("处理成功".equals(status)&&boLCP.getAttribute("FINISH_AMOUNT")!=null&&!"".equals(boLCP.getAttribute("FINISH_AMOUNT").toString())){
|
||||
insertMessage(boLRP,finishAmount,tx);
|
||||
//租金计划表状态处理
|
||||
BizObjectManager bomVRC = JBOFactory.getBizObjectManager("jbo.loan.VI_RENT_COLLECT",tx);
|
||||
BizObject vrc = bomVRC.createQuery("id=:id").setParameter("id", plan_id).getSingleResult(false);
|
||||
double rentOver = vrc.getAttribute("rent_over").getDouble();
|
||||
double penaltyOver = vrc.getAttribute("penalty_over").getDouble();
|
||||
if(rentOver>0 || penaltyOver>0){
|
||||
BizObjectManager bomIncome = JBOFactory.getBizObjectManager(LC_RENT_INCOME.CLASS_NAME,tx);
|
||||
BizObject boLRI = bomIncome.createQuery("select v.sum(v.ifnull(rent,0)) as v.rent from o where payment_number=:paymentNumber and plan_list=:planList")
|
||||
.setParameter("paymentNumber", boLRP.getAttribute("payment_number").getString())
|
||||
.setParameter("planList", boLRP.getAttribute("plan_list").getString()).getSingleResult(false);
|
||||
if(boLRP.getAttribute("rent").getDouble()>boLRI.getAttribute("rent").getDouble()){
|
||||
batchStatus = "complete";
|
||||
collectStatus = "部分收款";
|
||||
collectMsg = "通联收款";
|
||||
|
||||
32
src_cmb/com/tenwa/cgb/conf/CGBconfProperties.java
Normal file
32
src_cmb/com/tenwa/cgb/conf/CGBconfProperties.java
Normal file
@ -0,0 +1,32 @@
|
||||
package com.tenwa.cgb.conf;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Properties;
|
||||
|
||||
/**
|
||||
* ¹ã·¢ÒøÆóÖ±ÁªÅäÖÃ
|
||||
*
|
||||
* @program: apzl_leasing
|
||||
* @author: yjf
|
||||
* @create: 2021-07-20 08:24
|
||||
**/
|
||||
public class CGBconfProperties {
|
||||
|
||||
public static final String CIFMASTER;
|
||||
public static final String ENTUSERID;
|
||||
public static final String PASSWORD;
|
||||
public static final String CGBURL;
|
||||
|
||||
static {
|
||||
Properties prop = new Properties();
|
||||
try {
|
||||
prop.load(CGBconfProperties.class.getResourceAsStream("/cgb.properties"));
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
CIFMASTER = prop.getProperty("cifMaster");
|
||||
ENTUSERID = prop.getProperty("entUserId");
|
||||
PASSWORD = prop.getProperty("password");
|
||||
CGBURL = prop.getProperty("cgbUrl");
|
||||
}
|
||||
}
|
||||
476
src_cmb/com/tenwa/cgb/controller/OperateOfCGBController.java
Normal file
476
src_cmb/com/tenwa/cgb/controller/OperateOfCGBController.java
Normal file
@ -0,0 +1,476 @@
|
||||
package com.tenwa.cgb.controller;
|
||||
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.amarsoft.dict.als.manage.CodeManager;
|
||||
import com.tenwa.cgb.conf.CGBconfProperties;
|
||||
import com.tenwa.cgb.util.CGBLogAssistant;
|
||||
import com.tenwa.cgb.util.HttpAssistant;
|
||||
import com.tenwa.comm.exception.BusinessException;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import jbo.app.tenwa.calc.LB_ACTUAL_PAYMENT_INFO_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_FUND_INCOME_TEMP;
|
||||
import jbo.com.tenwa.lease.comm.LC_FUND_INCOME_CALLBACK_DETAIL_TEMP;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/**
|
||||
* @program: apzl_leasing
|
||||
* @author: yjf
|
||||
* @create: 2021-07-19 11:39
|
||||
**/
|
||||
public class OperateOfCGBController {
|
||||
|
||||
private static final String XMLDECLARE = "<?xml version=\"1.0\" encoding = \"GBK\"?>";
|
||||
private static Log log = LogFactory.getLog(OperateOfCGBController.class);
|
||||
private String flowUnid;
|
||||
private String userId;
|
||||
private String orgId;
|
||||
private String contractIds;
|
||||
|
||||
public void setFlowUnid(String flowUnid) {
|
||||
this.flowUnid = flowUnid;
|
||||
}
|
||||
|
||||
public void setContractIds(String contractIds) {
|
||||
this.contractIds = contractIds;
|
||||
}
|
||||
|
||||
public void setUserId(String userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public void setOrgId(String orgId) {
|
||||
this.orgId = orgId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量转账
|
||||
*
|
||||
* @param tx
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public String batchPayOfCGB(JBOTransaction tx) throws Exception {
|
||||
String retResult = "success发起付款成功!";
|
||||
contractIds = contractIds.replaceAll("@", "','");
|
||||
String subjectSql = "SELECT subjectId AS subjectuid FROM lb_contract_info WHERE id IN ('" + contractIds + "') GROUP BY subjectId ";
|
||||
List<Map<String, String>> lciList = DataOperatorUtil.getDataBySql(subjectSql);
|
||||
if (lciList.size() > 1) {
|
||||
return "放款合同中有多个主体,请检查!!!";
|
||||
}
|
||||
BizObjectManager actualPaymentMan = JBOFactory.getBizObjectManager(LB_ACTUAL_PAYMENT_INFO_TEMP.CLASS_NAME, tx);
|
||||
BizObject actualBo = actualPaymentMan.createQuery("flowunid=:flowunid").setParameter("flowunid", flowUnid).getSingleResult(false);
|
||||
if (actualBo == null || actualBo.getAttribute("acc_number").getString().length() == 0) {
|
||||
throw new BusinessException("没有匹配的本方账户,请检查!!!");
|
||||
}
|
||||
String payAccountNum = actualBo.getAttribute("acc_number").getString();
|
||||
BizObjectManager incomeMan = JBOFactory.getBizObjectManager(LC_FUND_INCOME_TEMP.CLASS_NAME, tx);
|
||||
BizObject singleResult = incomeMan.createQuery("select v.count(1) as v.allCount from O where FLOWUNID=:FLOWUNID and o.contract_id in ('" + contractIds + "') and o.PAY_TYPE = 'pay_type_out' and o.CMB_PAY_LOG is null ").setParameter("FLOWUNID", flowUnid).getSingleResult(false);
|
||||
if (singleResult != null && singleResult.getAttribute("allCount").getInt() > 0) {
|
||||
int start = 0;
|
||||
int maxCount = 200;
|
||||
while (singleResult.getAttribute("allCount").getInt() > start) {
|
||||
String customerBatchNo = "AP" + System.currentTimeMillis();
|
||||
log.info("CGB FLOWUNID[" + flowUnid + "]---开始第" + start + "至" + (start + maxCount) + "条循环");
|
||||
List<BizObject> income_all_list = incomeMan.createQuery("select o.ID,o.CMB_PAY_NO,o.FACT_MONEY,o.FLOWUNID,o.CONTRACT_ID,contract_info.CONTRACT_NO,contract_info.ZC_CONTRACT_NUMBER,lul.CUSTOMER_NAME,distributor.distributor_id,distributor.acc_number,distributor.open_bank,distributor.account from o join jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO contract_info on o.CONTRACT_ID = contract_info.id join jbo.com.tenwa.lease.comm.LB_UNION_LESSEE lul on contract_info.id = lul.contract_id join jbo.app.tenwa.customer.DISTRIBUTOR_ACCOUNT distributor on contract_info.distributor_id = distributor.distributor_id and distributor.is_main='Y' " +
|
||||
" where o.FLOWUNID=:FLOWUNID and o.contract_id in ('" + contractIds + "') and o.PAY_TYPE = 'pay_type_out' and o.CMB_PAY_LOG is null ")
|
||||
.setParameter("FLOWUNID", flowUnid).setFirstResult(start).setMaxResults(maxCount).getResultList(false);
|
||||
//批量转账报文
|
||||
String batchPayMsgXml = createBatchPayMsg(customerBatchNo, payAccountNum, income_all_list);
|
||||
//保存发起日志
|
||||
CGBLogAssistant.insertCGBlog(flowUnid, "pay", customerBatchNo, null, batchPayMsgXml);
|
||||
HashMap<String, Object> map = new HashMap<>();
|
||||
map.put("cgb_data", batchPayMsgXml);
|
||||
String retMsg = HttpAssistant.post(CGBconfProperties.CGBURL, map);
|
||||
if (retMsg == null) return "连接前置机异常,请联系管理员!";
|
||||
log.info("CGB [" + customerBatchNo + "] BATCHPAY RETURN XML : " + retMsg);
|
||||
//更新返回日志
|
||||
CGBLogAssistant.updateCGBlog(customerBatchNo, null, retMsg);
|
||||
//批量转账报文解析
|
||||
Map<String, String> batchPayResult = getBatchPayResult(retMsg);
|
||||
if (batchPayResult.size() > 0 && "000".equals(batchPayResult.get("retCode"))) {
|
||||
for (BizObject incomeObj : income_all_list) {
|
||||
payBackResultHandle(incomeObj, customerBatchNo, batchPayResult, actualBo);
|
||||
}
|
||||
} else {
|
||||
return "发起付款失败,广发返回错误:[" + CodeManager.getItemName("cgb_describe", batchPayResult.get("retCode")) + "]";
|
||||
}
|
||||
start += 200;
|
||||
}
|
||||
} else {
|
||||
return "选择数据包含付款中数据,请检查!!!";
|
||||
}
|
||||
return retResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量查询
|
||||
*
|
||||
* @param tx
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public String batchQueryOfCGB(JBOTransaction tx) throws Exception {
|
||||
BizObjectManager bm = JBOFactory.getBizObjectManager(LC_FUND_INCOME_CALLBACK_DETAIL_TEMP.CLASS_NAME);
|
||||
List<BizObject> bizObjects = bm.createQuery(" flowunid = :flowunid and cmb_pay_log is not null and ERRTXT='付款中' ")
|
||||
.setParameter("flowunid", flowUnid).getResultList(false);
|
||||
if (bizObjects.isEmpty()) return "待回盘数据为空,请检查";
|
||||
String customerBatchNo = null, customerSalarySeq = null;
|
||||
for (BizObject bizObject : bizObjects) {
|
||||
customerBatchNo = bizObject.getAttribute("cmb_pay_log").getString();
|
||||
customerSalarySeq = bizObject.getAttribute("cmb_pay_no").getString();
|
||||
String batchPayQueryXml = createBatchPayQueryMsg(customerBatchNo, customerSalarySeq);
|
||||
//保存发起日志
|
||||
CGBLogAssistant.insertCGBlog(flowUnid, "query", customerBatchNo, customerSalarySeq, batchPayQueryXml);
|
||||
HashMap<String, Object> map = new HashMap<>();
|
||||
map.put("cgb_data", batchPayQueryXml);
|
||||
String retMsg = HttpAssistant.post(CGBconfProperties.CGBURL, map);
|
||||
if (retMsg == null) return "连接前置机异常,请联系管理员!";
|
||||
log.info("CGB customerBatchNo[" + customerBatchNo + "] customerSalarySeq[" + customerSalarySeq + "] QUERY RETURN XML : " + retMsg);
|
||||
//更新返回日志
|
||||
CGBLogAssistant.updateCGBlog(customerBatchNo, customerSalarySeq, retMsg);
|
||||
Map<String, String> batchQueryResult = getBatchQueryResult(retMsg);
|
||||
JBOTransaction tx1 = null;
|
||||
try {
|
||||
tx1 = JBOFactory.createJBOTransaction();
|
||||
Transaction sqlca = Transaction.createTransaction(tx1);
|
||||
String retCode = batchQueryResult.get("retCode");
|
||||
if ("000".equals(retCode)) {
|
||||
String bankstatus = batchQueryResult.get("bankstatus");
|
||||
String errText = "付款中";
|
||||
String business_status = null, ebankStatus = null;
|
||||
if ("6,B".indexOf(bankstatus) != -1) { //交易成功
|
||||
business_status = "31";
|
||||
ebankStatus = "05";
|
||||
errText = "付款成功";
|
||||
} else if ("4,7,9,C,b".indexOf(bankstatus) != -1) { //交易失败
|
||||
business_status = "32";
|
||||
ebankStatus = "04";
|
||||
errText = "付款失败";
|
||||
}
|
||||
errText = batchQueryResult.get("errorreason") == null ? errText : batchQueryResult.get("errorreason");
|
||||
//更新回调结果状态
|
||||
SqlObject sqlObject = new SqlObject("update LC_FUND_INCOME_CALLBACK_DETAIL_TEMP set ERRCOD=:errCode,ERRTXT=:errText,RTNNAR=:rtnNar where id =:id")
|
||||
.setParameter("errCode", bankstatus)
|
||||
.setParameter("errText", errText)
|
||||
.setParameter("rtnNar", getbankstatusMsg(bankstatus))
|
||||
.setParameter("id", bizObject.getAttribute("id").getString());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
if (business_status != null) {
|
||||
//插入项目进度表
|
||||
sqlObject = new SqlObject("");
|
||||
sqlObject.setOriginalSql("insert into BUSINESS_STATUS select replace(uuid(),'-',''),contract_no,'" + business_status + "','" + userId + "','" + orgId + "','" + DateAssistant.getTodayNow() + "',null,null,null,null from lb_contract_info where id = '" + bizObject.getAttribute("contract_id").getString() + "'");
|
||||
sqlca.executeSQL(sqlObject);
|
||||
//更新资金实收临时表
|
||||
sqlObject = new SqlObject("update LC_FUND_INCOME_TEMP set EBANK_STATUS=:ebankStatus,CMB_PAY_NO=:customerSalarySeq,CMB_PAY_LOG=:customerBatchNo where flowunid=:flowunid and contract_id =:contractId ")
|
||||
.setParameter("ebankStatus", ebankStatus)
|
||||
.setParameter("customerSalarySeq", "04".equals(ebankStatus) ? null : customerSalarySeq)
|
||||
.setParameter("customerBatchNo", "04".equals(ebankStatus) ? null : customerBatchNo)
|
||||
.setParameter("flowunid", flowUnid)
|
||||
.setParameter("contractId", bizObject.getAttribute("contract_id").getString());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
}
|
||||
} else {
|
||||
//更新回调结果状态
|
||||
SqlObject sqlObject = new SqlObject("update LC_FUND_INCOME_CALLBACK_DETAIL_TEMP set ERRCOD=:errCode,ERRTXT=:errText where id =:id")
|
||||
.setParameter("errCode", retCode)
|
||||
.setParameter("errText", CodeManager.getItemName("cgb_describe", retCode))
|
||||
.setParameter("id", bizObject.getAttribute("id").getString());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
}
|
||||
tx1.commit();
|
||||
} catch (Exception e) {
|
||||
log.error("customerBatchNo:[" + customerBatchNo + "] customerSalarySeq:[" + customerSalarySeq + "] 查询结果处理异常:", e);
|
||||
if (tx1 != null) try {
|
||||
tx1.rollback();
|
||||
} catch (JBOException e1) {
|
||||
e1.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
return "success查询付款结果成功";
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量转账报文
|
||||
*
|
||||
* @param tx
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
private String createBatchPayMsg(String customerBatchNo, String accountNo, List<BizObject> payObjs) throws Exception {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append(XMLDECLARE);
|
||||
sb.append("<BEDC>");
|
||||
sb.append("<Message>");
|
||||
sb.append(commonMseeage("0033"));
|
||||
sb.append("<Body>");
|
||||
sb.append("<customerBatchNo>").append(customerBatchNo).append("</customerBatchNo>");//客户批次号 企业内唯一[必输] 长度20
|
||||
sb.append("<accountNo>").append(accountNo).append("</accountNo>");//付款账号 [必输]
|
||||
int allCount = 0;
|
||||
BigDecimal allSalary = new BigDecimal(0);
|
||||
for (BizObject payObj : payObjs) {
|
||||
allSalary = allSalary.add(BigDecimal.valueOf(payObj.getAttribute("fact_money").getDouble()));
|
||||
allCount++;
|
||||
}
|
||||
sb.append("<allCount>").append(allCount).append("</allCount>");//总笔数 [必输]
|
||||
sb.append("<allSalary>").append(allSalary.toString()).append("</allSalary>");//总金额 单位:元[必输]
|
||||
sb.append("<records>");
|
||||
int i = 0;
|
||||
String customerSalarySeq = null, customerName = null, contractNo = null, contractNoZC = null, remark = null;
|
||||
for (BizObject payObj : payObjs) {
|
||||
customerSalarySeq = customerBatchNo + String.format("%04d", ++i);
|
||||
customerName = payObj.getAttribute("CUSTOMER_NAME").getString();
|
||||
contractNo = payObj.getAttribute("contract_no").getString();
|
||||
contractNoZC = payObj.getAttribute("ZC_CONTRACT_NUMBER").getString();
|
||||
remark = "".equals(contractNoZC) ? customerName + "-" + contractNo : customerName + "-" + contractNoZC + "-" + contractNo;
|
||||
sb.append("<record>");
|
||||
sb.append("<customerSalarySeq>").append(customerSalarySeq).append("</customerSalarySeq>");//客户批次子流水号 企业内唯一[必输] 长度20
|
||||
sb.append("<transType>").append(checkCGB(payObj.getAttribute("open_bank").getString()) ? "0" : "1").append("</transType>"); //交易类型 0:行内 1:跨行 [必输]
|
||||
sb.append("<inaccname>").append(payObj.getAttribute("account")).append("</inaccname>"); //收款人 [必输]
|
||||
sb.append("<inacc>").append(payObj.getAttribute("acc_number")).append("</inacc>"); //收款账号 [必输]
|
||||
sb.append("<inaccbank>").append(payObj.getAttribute("open_bank").getString()).append("</inaccbank>"); //收款银行 [必输]
|
||||
sb.append("<inaccadd>").append("").append("</inaccadd>"); //收款银行地址
|
||||
sb.append("<bankCode>").append("").append("</bankCode>"); //联行号 跨行时 [必输] 广发自动根据银行名称匹配--技术回复
|
||||
sb.append("<salary>").append(payObj.getAttribute("fact_money").getString()).append("</salary>"); //金额 单位:元 [必输]
|
||||
sb.append("<remark>").append(remark).append("</remark>"); //备注 客户名+合作方合同号+安鹏合同号
|
||||
sb.append("<comment>").append(payObj.getAttribute("id").getString()).append("</comment>"); //附言 绑定支付对象主键
|
||||
sb.append("</record>");
|
||||
payObj.setAttributeValue("CMB_PAY_NO", customerSalarySeq);
|
||||
}
|
||||
sb.append("</records>");
|
||||
sb.append("</Body>");
|
||||
sb.append("</Message>");
|
||||
sb.append("</BEDC>");
|
||||
log.info("CGB [" + customerBatchNo + "] BATCHPAY SEND XML : " + sb.toString());
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 解析批量转账结果
|
||||
*
|
||||
* @param strXML
|
||||
* @return
|
||||
*/
|
||||
private Map<String, String> getBatchPayResult(String strXML) {
|
||||
Map<String, String> res = new HashMap<String, String>();
|
||||
//获取批次号
|
||||
Pattern pm = Pattern.compile("(?<=<customerBatchNo>)([\\S\\s]*?)(?=</customerBatchNo>)");
|
||||
Matcher mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
res.put("customerBatchNo", mm.group());
|
||||
}
|
||||
pm = Pattern.compile("(?<=<retCode>)([\\S\\s]*?)(?=</retCode>)");
|
||||
mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
res.put("retCode", mm.group());
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量转账查询报文
|
||||
*
|
||||
* @param customerBatchNo
|
||||
* @param customerSalarySeq
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
private String createBatchPayQueryMsg(String customerBatchNo, String customerSalarySeq) throws Exception {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append(XMLDECLARE);
|
||||
sb.append("<BEDC>");
|
||||
sb.append("<Message>");
|
||||
sb.append(commonMseeage("0034"));
|
||||
sb.append("<Body>");
|
||||
sb.append("<customerBatchNo>").append(customerBatchNo).append("</customerBatchNo>"); //客户批次号 [必输]
|
||||
sb.append("<customerSalarySeq>").append(customerSalarySeq == null ? "" : customerSalarySeq).append("</customerSalarySeq>"); //客户批次子流水号
|
||||
sb.append("</Body>");
|
||||
sb.append("</Message>");
|
||||
sb.append("</BEDC>");
|
||||
log.info("CGB customerBatchNo[" + customerBatchNo + "] customerSalarySeq[" + customerSalarySeq + "] QUERY SEND XML : " + sb.toString());
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 解析查询结果
|
||||
*
|
||||
* @param strXML
|
||||
* @return
|
||||
*/
|
||||
private Map<String, String> getBatchQueryResult(String strXML) {
|
||||
Map<String, String> res = new HashMap<String, String>();
|
||||
Pattern pm = Pattern.compile("(?<=<retCode>)([\\S\\s]*?)(?=</retCode>)");
|
||||
Matcher mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
res.put("retCode", mm.group());
|
||||
}
|
||||
//获取批次号
|
||||
pm = Pattern.compile("(?<=<customerSalarySeq>)([\\S\\s]*?)(?=</customerSalarySeq>)");
|
||||
mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
res.put("customerSalarySeq", mm.group());
|
||||
}
|
||||
pm = Pattern.compile("(?<=<bankstatus>)([\\S\\s]*?)(?=</bankstatus>)");
|
||||
mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
res.put("bankstatus", mm.group());
|
||||
}
|
||||
pm = Pattern.compile("(?<=<errorreason>)([\\S\\s]*?)(?=</errorreason>)");
|
||||
mm = pm.matcher(strXML);
|
||||
if (mm.find()) {
|
||||
if (mm.group().length() > 0) res.put("errorreason", mm.group());
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 公共报文头拼接
|
||||
*
|
||||
* @param tranCode 交易码
|
||||
* @return
|
||||
*/
|
||||
private String commonMseeage(String tranCode) throws Exception {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append("<commHead>");
|
||||
sb.append("<tranCode>").append(tranCode).append("</tranCode>");//交易码
|
||||
sb.append("<cifMaster>").append(CGBconfProperties.CIFMASTER).append("</cifMaster>");//客户号
|
||||
sb.append("<entSeqNo>").append("CGB").append(System.currentTimeMillis()).append("</entSeqNo>");//企业财务系统流水号 企业财务系统自己产生的流水号,每天唯一 长度20
|
||||
sb.append("<tranDate>").append(DateAssistant.getFormatDate("yyyyMMdd")).append("</tranDate>");//日期
|
||||
sb.append("<tranTime>").append(DateAssistant.getFormatDate("HHmmss")).append("</tranTime>");//时间
|
||||
sb.append("<retCode></retCode>");//返回码,请求报文是,默认为空
|
||||
sb.append("<entUserId>").append(CGBconfProperties.ENTUSERID).append("</entUserId>");//操作员
|
||||
sb.append("<password> <![CDATA[").append(CGBconfProperties.PASSWORD).append("]]></password>");//操作密码
|
||||
sb.append("</commHead>");
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查是否广发银行账号
|
||||
*
|
||||
* @param str
|
||||
* @return
|
||||
*/
|
||||
private boolean checkCGB(String str) {
|
||||
if (str.indexOf("广发") != -1) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付回调结果处理
|
||||
*/
|
||||
private void payBackResultHandle(BizObject payObj, String customerBatchNo, Map<String, String> retResult, BizObject actualObj) {
|
||||
JBOTransaction tx = null;
|
||||
String serialNum = null;
|
||||
try {
|
||||
serialNum = payObj.getAttribute("CMB_PAY_NO").getString();
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Transaction sqlca = Transaction.createTransaction(tx);
|
||||
//修改上次扣款记录,避免显示多条数据
|
||||
SqlObject sqlObject = new SqlObject("update LC_FUND_INCOME_CALLBACK_DETAIL_TEMP set contract_id = null where flowunid=:flowunid and contract_id =:contractId")
|
||||
.setParameter("flowunid", flowUnid).setParameter("contractId", payObj.getAttribute("contract_id").getString());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
//添加新的扣款记录
|
||||
sqlObject = new SqlObject("insert into LC_FUND_INCOME_CALLBACK_DETAIL_TEMP (id,FLOWUNID,CMB_PAY_LOG,CMB_PAY_NO,ERRTXT,CONTRACT_ID,DISTRIBUTOR_ID,INPUTUSERID,INPUTORGID,INPUTTIME) "
|
||||
+ " values (replace(uuid(),'-',''),:flowunid,:cmbPayLog,:serialNum,'付款中',:contractId,:distributorId,:userId,:orgId,:inputTime)")
|
||||
.setParameter("flowunid", flowUnid)
|
||||
.setParameter("cmbPayLog", customerBatchNo) //批次号
|
||||
.setParameter("serialNum", serialNum) //序号
|
||||
.setParameter("contractId", payObj.getAttribute("contract_id").getString()) //合同id
|
||||
.setParameter("distributorId", payObj.getAttribute("distributor_id").getString())//经销商id
|
||||
.setParameter("userId", userId)
|
||||
.setParameter("orgId", orgId)
|
||||
.setParameter("inputTime", DateAssistant.getTodayNow());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
//更新批次号,序号到支付明细数据
|
||||
sqlObject = new SqlObject("update LC_FUND_INCOME_TEMP set CMB_PAY_LOG=:customerBatchNo,CMB_PAY_NO=:serialNum,bank=:bank,account=:account,acc_number=:accNumber where id = :id ")
|
||||
.setParameter("customerBatchNo", customerBatchNo)
|
||||
.setParameter("serialNum", serialNum)
|
||||
.setParameter("bank", actualObj.getAttribute("bank").getString())//本方银行
|
||||
.setParameter("account", actualObj.getAttribute("account").getString())//本方账户
|
||||
.setParameter("accNumber", actualObj.getAttribute("acc_number").getString())//本方账号
|
||||
.setParameter("id", payObj.getAttribute("id").getString());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
tx.commit();
|
||||
} catch (Exception e) {
|
||||
log.error("customerBatchNo:[" + customerBatchNo + "] customerSalarySeq:[" + serialNum + "] 批量转账结果处理异常!", e);
|
||||
if (tx != null) try {
|
||||
tx.rollback();
|
||||
} catch (JBOException e1) {
|
||||
e1.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 交易处理状态
|
||||
*
|
||||
* @param bankstatus
|
||||
* @return
|
||||
*/
|
||||
private String getbankstatusMsg(String bankstatus) {
|
||||
String msg = null;
|
||||
//行内汇款:6,7,8 跨行汇款:A,B,C,E
|
||||
switch (bankstatus) {
|
||||
case "6":
|
||||
msg = "主机交易成功";
|
||||
break;
|
||||
case "7":
|
||||
msg = "主机交易失败";
|
||||
break;
|
||||
case "8":
|
||||
msg = "状态未知,没有收到后台系统返回的应答";
|
||||
break;
|
||||
case "A":
|
||||
msg = "支付系统正在处理";
|
||||
break;
|
||||
case "B":
|
||||
msg = "处理成功";
|
||||
break;
|
||||
case "C":
|
||||
msg = "处理失败";
|
||||
break;
|
||||
case "E":
|
||||
msg = "大额查证";
|
||||
break;
|
||||
case "9":
|
||||
msg = "查证取消交易";
|
||||
break;
|
||||
default:
|
||||
msg = bankstatus;
|
||||
}
|
||||
return msg;
|
||||
}
|
||||
|
||||
public String vaildate(Transaction sqlCa) throws Exception {
|
||||
ASResultSet as = sqlCa.getASResultSet("select count(1) as nums," +
|
||||
"sum(case when cmb_pay_log is not null or locate(RTNFLG,'F')>0 and length(RTNFLG)>0 then 0 else 1 end ) cmb_succ_num," +
|
||||
"sum(case when cmb_pay_log is null or locate(ERRCOD,'4,7,9,C,b,W')>0 and length(ERRCOD)>0 then 0 else 1 end ) cgb_succ_num" +
|
||||
" from LC_FUND_INCOME_CALLBACK_DETAIL_TEMP where flowunid = '" + flowUnid + "'");
|
||||
if (as.next()) {
|
||||
int nums = as.getInt("nums");
|
||||
int CMBNums = as.getInt("cmb_succ_num"); //招商发起成功数
|
||||
int CGBNums = as.getInt("cgb_succ_num"); //广发发起成功数
|
||||
if (nums > 0 && (CMBNums > 0 || CGBNums > 0)) {
|
||||
return "已发起支付,禁止变更";
|
||||
}
|
||||
}
|
||||
return "succ";
|
||||
}
|
||||
}
|
||||
74
src_cmb/com/tenwa/cgb/util/CGBLogAssistant.java
Normal file
74
src_cmb/com/tenwa/cgb/util/CGBLogAssistant.java
Normal file
@ -0,0 +1,74 @@
|
||||
package com.tenwa.cgb.util;
|
||||
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
|
||||
/**
|
||||
* @program: apzl_leasing
|
||||
* @author: yjf
|
||||
* @create: 2021-07-20 15:15
|
||||
**/
|
||||
public class CGBLogAssistant {
|
||||
|
||||
public static void insertCGBlog(String flowUnid, String type, String batchNo, String serialNum, String reqMsg) {
|
||||
JBOTransaction tx = null;
|
||||
try {
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Transaction sqlca = Transaction.createTransaction(tx);
|
||||
SqlObject sqlObject = new SqlObject("insert into lb_cgb_log (type,flow_unid,batch_no,serial_num,req_msg,req_time) values (:type,:flowUnid,:batchNo,:serialNum,:reqMsg,:reqTime)")
|
||||
.setParameter("type", type)
|
||||
.setParameter("flowUnid", flowUnid)
|
||||
.setParameter("batchNo", batchNo)
|
||||
.setParameter("serialNum", serialNum)
|
||||
.setParameter("reqMsg", reqMsg)
|
||||
.setParameter("reqTime", DateAssistant.getTodayNow());
|
||||
sqlca.executeSQL(sqlObject);
|
||||
tx.commit();
|
||||
} catch (Exception e) {
|
||||
if (tx != null) try {
|
||||
tx.rollback();
|
||||
} catch (JBOException e1) {
|
||||
e1.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static void updateCGBlog(String batchNo, String serialNum, String retMsg) {
|
||||
JBOTransaction tx = null;
|
||||
try {
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Transaction sqlca = Transaction.createTransaction(tx);
|
||||
SqlObject sqlObject = null;
|
||||
StringBuilder sb = new StringBuilder("update lb_cgb_log set ret_msg=:retMsg,ret_time=:retTime where batch_no =:batchNo and");
|
||||
if (serialNum == null) {
|
||||
sb.append(" serial_num is null");
|
||||
sqlObject = new SqlObject(sb.toString())
|
||||
.setParameter("retMsg", retMsg)
|
||||
.setParameter("retTime", DateAssistant.getTodayNow())
|
||||
.setParameter("batchNo", batchNo);
|
||||
} else {
|
||||
sb.append(" serial_num =:serialNum");
|
||||
sqlObject = new SqlObject(sb.toString())
|
||||
.setParameter("retMsg", retMsg)
|
||||
.setParameter("retTime", DateAssistant.getTodayNow())
|
||||
.setParameter("batchNo", batchNo)
|
||||
.setParameter("serialNum", serialNum);
|
||||
}
|
||||
sqlca.executeSQL(sqlObject);
|
||||
tx.commit();
|
||||
} catch (Exception e) {
|
||||
if (tx != null) try {
|
||||
tx.rollback();
|
||||
} catch (JBOException e1) {
|
||||
e1.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
64
src_cmb/com/tenwa/cgb/util/HttpAssistant.java
Normal file
64
src_cmb/com/tenwa/cgb/util/HttpAssistant.java
Normal file
@ -0,0 +1,64 @@
|
||||
package com.tenwa.cgb.util;
|
||||
|
||||
|
||||
import org.apache.commons.httpclient.HttpClient;
|
||||
import org.apache.commons.httpclient.HttpStatus;
|
||||
import org.apache.commons.httpclient.NameValuePair;
|
||||
import org.apache.commons.httpclient.methods.PostMethod;
|
||||
import org.apache.commons.httpclient.params.HttpMethodParams;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @program: apzl_leasing
|
||||
* @author: yjf
|
||||
* @create: 2021-07-20 08:43
|
||||
**/
|
||||
public class HttpAssistant {
|
||||
|
||||
private static Log log = LogFactory.getLog(HttpAssistant.class);
|
||||
private static final HttpClient httpClient = new HttpClient();
|
||||
|
||||
static {
|
||||
httpClient.getHttpConnectionManager().getParams().setConnectionTimeout(10000);
|
||||
httpClient.getParams().setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET, "GBK");
|
||||
}
|
||||
|
||||
public static String post(String reqUrl, Map<String, Object> paramMap) {
|
||||
String result = null;
|
||||
PostMethod postMethod = null;
|
||||
try {
|
||||
postMethod = new PostMethod(reqUrl);
|
||||
// 这个basicNameValue**放在List中
|
||||
List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();
|
||||
// 创建basicNameValue***对象参数
|
||||
if (paramMap != null) {
|
||||
for (Map.Entry<String, Object> entry : paramMap.entrySet()) {
|
||||
nameValuePairs.add(new NameValuePair(entry.getKey(), entry.getValue().toString()));
|
||||
}
|
||||
}
|
||||
// 填入各个表单域的值
|
||||
NameValuePair[] param = nameValuePairs.toArray(new NameValuePair[nameValuePairs.size()]);
|
||||
postMethod.addParameters(param);
|
||||
postMethod.setRequestHeader("Content-type", "application/x-www-form-urlencoded;charset=gbk");
|
||||
postMethod.setRequestHeader("Cache-Control", "no-cache");
|
||||
// 执行postMethod
|
||||
int statusCode = httpClient.executeMethod(postMethod);
|
||||
if (statusCode == HttpStatus.SC_OK) {
|
||||
result = postMethod.getResponseBodyAsString();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
log.error("执行HTTP Post请求" + reqUrl + "时,发生异常:", e);
|
||||
} finally {
|
||||
if (postMethod != null) postMethod.releaseConnection();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,40 +1,24 @@
|
||||
package com.tenwa.sdk.controller;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.BizObjectQuery;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.awe.Configure;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.action.comm.BaseFlowStartAction;
|
||||
import com.tenwa.sdk.VO.SDKDcPayReqxVO;
|
||||
import com.tenwa.sdk.VO.SDKInfoVO;
|
||||
import com.tenwa.sdk.VO.SDKPayCallBackVO;
|
||||
import com.tenwa.sdk.VO.SDKPayCallDetail;
|
||||
import com.tenwa.sdk.VO.SDKPayRqxVO;
|
||||
import com.tenwa.sdk.VO.SDKToPayVO;
|
||||
import com.tenwa.sdk.VO.*;
|
||||
import com.tenwa.sdk.utils.HttpRequest;
|
||||
import com.tenwa.sdk.utils.XMLStream;
|
||||
import com.thoughtworks.xstream.XStream;
|
||||
|
||||
import jbo.app.tenwa.calc.LB_ACTUAL_PAYMENT_INFO_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_FUND_INCOME_TEMP;
|
||||
import jbo.com.tenwa.entity.comm.own.OWN_ACCOUNT;
|
||||
import jbo.com.tenwa.lease.comm.*;
|
||||
import jbo.prd.LB_PRODUCTTOCOMPANY_INFO;
|
||||
import jbo.sys.CODE_LIBRARY;
|
||||
import net.sf.json.JSONObject;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
|
||||
public class CmbToPayController extends BaseFlowStartAction {
|
||||
private String distributor_ids; //获取选择的 经销商ID
|
||||
private String contract_ids; //获取选择的合同ID
|
||||
@ -116,26 +100,14 @@ public class CmbToPayController extends BaseFlowStartAction {
|
||||
/*
|
||||
* 本方放款账户获取######开始
|
||||
*/
|
||||
BizObjectManager accountManager = JBOFactory.getBizObjectManager(OWN_ACCOUNT.CLASS_NAME);
|
||||
List<BizObject> accountBoList = null;
|
||||
if("aa740e4111c111eaaa0000163e0e11e6".equals(subjectId)){
|
||||
accountBoList = accountManager.createQuery("select o.id,o.acc_number,o.acc_bank,o.acc_name,o.branch_code,oi.OWN_NAME from o left join jbo.com.tenwa.entity.comm.own.OWN_INFO oi on o.own_id = oi.OWN_NUMBER where o.money_type='01' and o.state_='0010' and o.acc_type='0010' and o.FbSdk='Y' and (o.account_type='out_account' or o.account_type='inAndOut_account') and oi.OWN_NAME='安鹏国际融资租赁(深圳)有限公司'").getResultList(false);
|
||||
}else if("d989246c11c111eaaa0000163e0e11e6".equals(subjectId)){
|
||||
accountBoList = accountManager.createQuery("select o.id,o.acc_number,o.acc_bank,o.acc_name,o.branch_code,oi.OWN_NAME from o left join jbo.com.tenwa.entity.comm.own.OWN_INFO oi on o.own_id = oi.OWN_NUMBER where o.money_type='01' and o.state_='0010' and o.acc_type='0010' and o.FbSdk='Y' and (o.account_type='out_account' or o.account_type='inAndOut_account') and oi.OWN_NAME='安鹏融资租赁(天津)有限公司'").getResultList(false);
|
||||
}
|
||||
if( accountBoList==null ||accountBoList.size()==0) {
|
||||
map.put("code", "1") ;
|
||||
map.put("msg", "没有匹配的本方账户,请在本方账户中检查!") ;
|
||||
BizObjectManager actualPaymentMan = JBOFactory.getBizObjectManager(LB_ACTUAL_PAYMENT_INFO_TEMP.CLASS_NAME);
|
||||
BizObject accountBo = actualPaymentMan.createQuery("select o.account,o.acc_number,o.bank,oa.id,oa.branch_code from o join jbo.com.tenwa.entity.comm.own.OWN_ACCOUNT oa on o.acc_number = oa.acc_number where flowunid=:flowunid and and (oa.account_type='out_account' or oa.account_type='inAndOut_account')").setParameter("flowunid", FLOWUNID).getSingleResult(false);
|
||||
if (accountBo == null) {
|
||||
map.put("code", "1");
|
||||
map.put("msg", "没有匹配的本方账户,请在本方账户中检查!");
|
||||
JSONObject jsonObj = JSONObject.fromObject(map);
|
||||
return jsonObj.toString();
|
||||
}
|
||||
if( accountBoList!=null && accountBoList.size()>1 ) {
|
||||
map.put("code", "1") ;
|
||||
map.put("msg", "启用的汽车类放款账户只能同时存在一个,请在本方账户中检查!") ;
|
||||
JSONObject jsonObj = JSONObject.fromObject(map);
|
||||
return jsonObj.toString();
|
||||
}
|
||||
BizObject accountBo = accountBoList.get(0);
|
||||
/*
|
||||
* 本方放款账户获取######结束
|
||||
*/
|
||||
@ -490,6 +462,9 @@ public class CmbToPayController extends BaseFlowStartAction {
|
||||
income_boo.setParameter("FLOWUNID",pay_detail_one.getAttribute("FLOWUNID").toString()) ;
|
||||
income_boo.setParameter("CONTRACT_ID",pay_detail_one.getAttribute("CONTRACT_ID").toString()) ;
|
||||
income_boo.setParameter("DISTRIBUTOR_ID",pay_detail_one.getAttribute("DISTRIBUTOR_ID").toString()) ;
|
||||
income_boo.setParameter("bank",accountBo.getAttribute("bank").toString()) ;
|
||||
income_boo.setParameter("account",accountBo.getAttribute("account").toString()) ;
|
||||
income_boo.setParameter("acc_number",accountBo.getAttribute("acc_number").toString()) ;
|
||||
income_boo.executeUpdate();//更新资金收付表
|
||||
pay_detail_bom.saveObject(pay_detail_one); //插入支付详情表
|
||||
}
|
||||
|
||||
@ -38,7 +38,17 @@ public class DateAssistant {
|
||||
DateX date=new DateX();
|
||||
return date.getDateString("HH:mm:ss");
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获得自定义格式日期
|
||||
* @param format
|
||||
* @return
|
||||
*/
|
||||
public final static String getFormatDate(String format){
|
||||
DateX date=new DateX();
|
||||
return date.getDateString(format);
|
||||
}
|
||||
|
||||
public static long getDateSubDays(String sDate1, String sDate2, String sFormat) throws Exception {
|
||||
Calendar calendar1 = Calendar.getInstance();
|
||||
calendar1.setTime(new SimpleDateFormat(sFormat).parse(sDate1));
|
||||
|
||||
@ -617,4 +617,9 @@ public interface LC_CALC_CONDITION{
|
||||
* ÌùÏ¢<br>
|
||||
*/
|
||||
public static final String DISCOUNT_INTEREST = "DISCOUNT_INTEREST";
|
||||
|
||||
/**
|
||||
* 履북적쪽<br>
|
||||
*/
|
||||
public static final String COMPREHENSIVE_RATE = "COMPREHENSIVE_RATE";
|
||||
}
|
||||
@ -617,4 +617,8 @@ public interface LC_CALC_CONDITION_HIS{
|
||||
* ÌùÏ¢<br>
|
||||
*/
|
||||
public static final String DISCOUNT_INTEREST = "DISCOUNT_INTEREST";
|
||||
/**
|
||||
* 履북적쪽<br>
|
||||
*/
|
||||
public static final String COMPREHENSIVE_RATE = "COMPREHENSIVE_RATE";
|
||||
}
|
||||
@ -617,4 +617,8 @@ public interface LC_CALC_CONDITION_TEMP{
|
||||
* ÌùÏ¢<br>
|
||||
*/
|
||||
public static final String DISCOUNT_INTEREST = "DISCOUNT_INTEREST";
|
||||
/**
|
||||
* 履북적쪽<br>
|
||||
*/
|
||||
public static final String COMPREHENSIVE_RATE = "COMPREHENSIVE_RATE";
|
||||
}
|
||||
148
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO.java
Normal file
148
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO.java
Normal file
@ -0,0 +1,148 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_CALC_SUBSECTION_INFO{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 分段号 INT(10)<br>
|
||||
*/
|
||||
public static final String SUBSECTION_NUMBER = "SUBSECTION_NUMBER";
|
||||
/**
|
||||
* 融资额比例 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_RATIO = "CLEAN_LEASE_RATIO";
|
||||
/**
|
||||
* 融资额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_MONEY = "CLEAN_LEASE_MONEY";
|
||||
/**
|
||||
* 标准利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RATE = "RATE";
|
||||
/**
|
||||
* 产品利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_RATE = "DISCOUNT_RATE";
|
||||
/**
|
||||
* 融资利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String FINANCING_RATE = "FINANCING_RATE";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String INCOME_NUMBER = "INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT = "DISCOUNT";
|
||||
/**
|
||||
* 最大贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String MAXIMUM_DISCOUNT = "MAXIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息回款期次 INT(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_COLLECTION_PERIOD = "DISCOUNT_COLLECTION_PERIOD";
|
||||
/**
|
||||
* 贴息计算方式 STRING(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_CALC_METHOD = "DISCOUNT_CALC_METHOD";
|
||||
/**
|
||||
* 是否差额放款 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_BALANCE_LENDING = "IS_BALANCE_LENDING";
|
||||
/**
|
||||
* 录入人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 录入部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 录入时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 期次是否只读 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_ONLYREAD_INCOME_NUMBER = "IS_ONLYREAD_INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额是否固定金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT = "IS_FIXED_DISCOUNT";
|
||||
/**
|
||||
* 融资利率是否可修改 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_UPDATE_LEASE_MONEY_RATIO = "IS_UPDATE_LEASE_MONEY_RATIO";
|
||||
/**
|
||||
* 融资金额最大值 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_LEASE_MONEY = "MAX_LEASE_MONEY";
|
||||
/**
|
||||
* 最小贴息金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String MINIMUM_DISCOUNT = "MINIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息后利率是否固定 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT_RATE = "IS_FIXED_DISCOUNT_RATE";
|
||||
/**
|
||||
* 最大期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_INCOME_NUMBER = "MAX_INCOME_NUMBER";
|
||||
/**
|
||||
* 最小期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MIN_INCOME_NUMBER = "MIN_INCOME_NUMBER";
|
||||
/**
|
||||
* 融资金额最小值 STRING(10)<br>
|
||||
*/
|
||||
public static final String MIN_LEASE_MONEY = "MIN_LEASE_MONEY";
|
||||
}
|
||||
149
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO_HIS.java
Normal file
149
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO_HIS.java
Normal file
@ -0,0 +1,149 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_CALC_SUBSECTION_INFO_HIS{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_HIS";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 分段号 INT(10)<br>
|
||||
*/
|
||||
public static final String SUBSECTION_NUMBER = "SUBSECTION_NUMBER";
|
||||
/**
|
||||
* 融资额比例 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_RATIO = "CLEAN_LEASE_RATIO";
|
||||
/**
|
||||
* 融资额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_MONEY = "CLEAN_LEASE_MONEY";
|
||||
/**
|
||||
* 标准利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RATE = "RATE";
|
||||
/**
|
||||
* 产品利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_RATE = "DISCOUNT_RATE";
|
||||
/**
|
||||
* 融资利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String FINANCING_RATE = "FINANCING_RATE";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String INCOME_NUMBER = "INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT = "DISCOUNT";
|
||||
/**
|
||||
* 最大贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String MAXIMUM_DISCOUNT = "MAXIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息回款期次 INT(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_COLLECTION_PERIOD = "DISCOUNT_COLLECTION_PERIOD";
|
||||
/**
|
||||
* 贴息计算方式 STRING(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_CALC_METHOD = "DISCOUNT_CALC_METHOD";
|
||||
/**
|
||||
* 是否差额放款 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_BALANCE_LENDING = "IS_BALANCE_LENDING";
|
||||
/**
|
||||
* 录入人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 录入部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 录入时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 期次是否只读 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_ONLYREAD_INCOME_NUMBER = "IS_ONLYREAD_INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额是否固定金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT = "IS_FIXED_DISCOUNT";
|
||||
/**
|
||||
* 融资利率是否可修改 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_UPDATE_LEASE_MONEY_RATIO = "IS_UPDATE_LEASE_MONEY_RATIO";
|
||||
/**
|
||||
* 融资金额最大值 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_LEASE_MONEY = "MAX_LEASE_MONEY";
|
||||
/**
|
||||
* 最小贴息金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String MINIMUM_DISCOUNT = "MINIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息后利率是否固定 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT_RATE = "IS_FIXED_DISCOUNT_RATE";
|
||||
|
||||
/**
|
||||
* 最大期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_INCOME_NUMBER = "MAX_INCOME_NUMBER";
|
||||
/**
|
||||
* 最小期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MIN_INCOME_NUMBER = "MIN_INCOME_NUMBER";
|
||||
/**
|
||||
* 融资金额最小值 STRING(32<br>
|
||||
*/
|
||||
public static final String MIN_LEASE_MONEY = "MIN_LEASE_MONEY";
|
||||
}
|
||||
152
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO_TEMP.java
Normal file
152
src_jbo/jbo/app/tenwa/calc/LC_CALC_SUBSECTION_INFO_TEMP.java
Normal file
@ -0,0 +1,152 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_CALC_SUBSECTION_INFO_TEMP{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_CALC_SUBSECTION_INFO_TEMP";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 分段号 INT(10)<br>
|
||||
*/
|
||||
public static final String SUBSECTION_NUMBER = "SUBSECTION_NUMBER";
|
||||
/**
|
||||
* 融资额比例 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_RATIO = "CLEAN_LEASE_RATIO";
|
||||
/**
|
||||
* 融资额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_MONEY = "CLEAN_LEASE_MONEY";
|
||||
/**
|
||||
* 标准利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RATE = "RATE";
|
||||
/**
|
||||
* 产品利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_RATE = "DISCOUNT_RATE";
|
||||
/**
|
||||
* 融资利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String FINANCING_RATE = "FINANCING_RATE";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String INCOME_NUMBER = "INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT = "DISCOUNT";
|
||||
/**
|
||||
* 最大贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String MAXIMUM_DISCOUNT = "MAXIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息回款期次 INT(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_COLLECTION_PERIOD = "DISCOUNT_COLLECTION_PERIOD";
|
||||
/**
|
||||
* 贴息计算方式 STRING(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_CALC_METHOD = "DISCOUNT_CALC_METHOD";
|
||||
/**
|
||||
* 是否差额放款 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_BALANCE_LENDING = "IS_BALANCE_LENDING";
|
||||
/**
|
||||
* 录入人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 录入部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 录入时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 流程标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 期次是否只读 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_ONLYREAD_INCOME_NUMBER = "IS_ONLYREAD_INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额是否固定金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT = "IS_FIXED_DISCOUNT";
|
||||
/**
|
||||
* 融资利率是否可修改 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_UPDATE_LEASE_MONEY_RATIO = "IS_UPDATE_LEASE_MONEY_RATIO";
|
||||
/**
|
||||
* 融资金额最大值 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_LEASE_MONEY = "MAX_LEASE_MONEY";
|
||||
/**
|
||||
* 最小贴息金额 STRING(10)<br>
|
||||
*/
|
||||
public static final String MINIMUM_DISCOUNT = "MINIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息后利率是否固定 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_FIXED_DISCOUNT_RATE = "IS_FIXED_DISCOUNT_RATE";
|
||||
/**
|
||||
* 最大期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MAX_INCOME_NUMBER = "MAX_INCOME_NUMBER";
|
||||
/**
|
||||
* 最小期次 STRING(32)<br>
|
||||
*/
|
||||
public static final String MIN_INCOME_NUMBER = "MIN_INCOME_NUMBER";
|
||||
/**
|
||||
* 融资金额最小值 STRING(32<br>
|
||||
*/
|
||||
public static final String MIN_LEASE_MONEY = "MIN_LEASE_MONEY";
|
||||
}
|
||||
112
src_jbo/jbo/app/tenwa/calc/LC_CONTRACT_SUBSECTION_INFO.java
Normal file
112
src_jbo/jbo/app/tenwa/calc/LC_CONTRACT_SUBSECTION_INFO.java
Normal file
@ -0,0 +1,112 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_CONTRACT_SUBSECTION_INFO{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_CONTRACT_SUBSECTION_INFO";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 分段号 INT(10)<br>
|
||||
*/
|
||||
public static final String SUBSECTION_NUMBER = "SUBSECTION_NUMBER";
|
||||
/**
|
||||
* 融资额比例 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_RATIO = "CLEAN_LEASE_RATIO";
|
||||
/**
|
||||
* 融资额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_MONEY = "CLEAN_LEASE_MONEY";
|
||||
/**
|
||||
* 标准利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RATE = "RATE";
|
||||
/**
|
||||
* 产品利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_RATE = "DISCOUNT_RATE";
|
||||
/**
|
||||
* 融资利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String FINANCING_RATE = "FINANCING_RATE";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String INCOME_NUMBER = "INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT = "DISCOUNT";
|
||||
/**
|
||||
* 最大贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String MAXIMUM_DISCOUNT = "MAXIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息回款期次 INT(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_COLLECTION_PERIOD = "DISCOUNT_COLLECTION_PERIOD";
|
||||
/**
|
||||
* 贴息计算方式 STRING(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_CALC_METHOD = "DISCOUNT_CALC_METHOD";
|
||||
/**
|
||||
* 是否差额放款 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_BALANCE_LENDING = "IS_BALANCE_LENDING";
|
||||
/**
|
||||
* 录入人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 录入部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 录入时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
}
|
||||
144
src_jbo/jbo/app/tenwa/calc/LC_CONTRACT_SUBSECTION_RENT_PLAN.java
Normal file
144
src_jbo/jbo/app/tenwa/calc/LC_CONTRACT_SUBSECTION_RENT_PLAN.java
Normal file
@ -0,0 +1,144 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_CONTRACT_SUBSECTION_RENT_PLAN{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_CONTRACT_SUBSECTION_RENT_PLAN";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 报价编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String QUOT_ID = "QUOT_ID";
|
||||
/**
|
||||
* 客户编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CUST_ID = "CUST_ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String PLAN_LIST = "PLAN_LIST";
|
||||
/**
|
||||
* 计划日期 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_DATE = "PLAN_DATE";
|
||||
/**
|
||||
* 收付状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_STATUS = "PLAN_STATUS";
|
||||
/**
|
||||
* 租金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT = "RENT";
|
||||
/**
|
||||
* 财务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS = "CORPUS";
|
||||
/**
|
||||
* 财务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST = "INTEREST";
|
||||
/**
|
||||
* 应收罚息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String PENALTY = "PENALTY";
|
||||
/**
|
||||
* 业务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_BUSINESS = "CORPUS_BUSINESS";
|
||||
/**
|
||||
* 业务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_BUSINESS = "INTEREST_BUSINESS";
|
||||
/**
|
||||
* 租金调整值 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT_ADJUST = "RENT_ADJUST";
|
||||
/**
|
||||
* 本期后本金余额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String ALL_REMAIN_CORPUS = "ALL_REMAIN_CORPUS";
|
||||
/**
|
||||
* 结算方式 STRING(32)<br>
|
||||
*/
|
||||
public static final String SETTLE_METHOD = "SETTLE_METHOD";
|
||||
/**
|
||||
* 币种 STRING(32)<br>
|
||||
*/
|
||||
public static final String COIN = "COIN";
|
||||
/**
|
||||
* 年利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String YEAR_RATE = "YEAR_RATE";
|
||||
/**
|
||||
* 备注 STRING(100)<br>
|
||||
*/
|
||||
public static final String MEMO = "MEMO";
|
||||
/**
|
||||
* 流程编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 登记人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 登记部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 登记时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 计息日 STRING(32)<br>
|
||||
*/
|
||||
public static final String INTEREST_DATE = "INTEREST_DATE";
|
||||
/**
|
||||
* subsection_number INT(10)<br>
|
||||
*/
|
||||
public static final String subsection_number = "subsection_number";
|
||||
}
|
||||
112
src_jbo/jbo/app/tenwa/calc/LC_PROJ_SUBSECTION_INFO.java
Normal file
112
src_jbo/jbo/app/tenwa/calc/LC_PROJ_SUBSECTION_INFO.java
Normal file
@ -0,0 +1,112 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_PROJ_SUBSECTION_INFO{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_PROJ_SUBSECTION_INFO";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 分段号 INT(10)<br>
|
||||
*/
|
||||
public static final String SUBSECTION_NUMBER = "SUBSECTION_NUMBER";
|
||||
/**
|
||||
* 融资额比例 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_RATIO = "CLEAN_LEASE_RATIO";
|
||||
/**
|
||||
* 融资额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CLEAN_LEASE_MONEY = "CLEAN_LEASE_MONEY";
|
||||
/**
|
||||
* 标准利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RATE = "RATE";
|
||||
/**
|
||||
* 产品利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_RATE = "DISCOUNT_RATE";
|
||||
/**
|
||||
* 融资利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String FINANCING_RATE = "FINANCING_RATE";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String INCOME_NUMBER = "INCOME_NUMBER";
|
||||
/**
|
||||
* 贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String DISCOUNT = "DISCOUNT";
|
||||
/**
|
||||
* 最大贴息金额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String MAXIMUM_DISCOUNT = "MAXIMUM_DISCOUNT";
|
||||
/**
|
||||
* 贴息回款期次 INT(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_COLLECTION_PERIOD = "DISCOUNT_COLLECTION_PERIOD";
|
||||
/**
|
||||
* 贴息计算方式 STRING(10)<br>
|
||||
*/
|
||||
public static final String DISCOUNT_CALC_METHOD = "DISCOUNT_CALC_METHOD";
|
||||
/**
|
||||
* 是否差额放款 STRING(10)<br>
|
||||
*/
|
||||
public static final String IS_BALANCE_LENDING = "IS_BALANCE_LENDING";
|
||||
/**
|
||||
* 录入人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 录入部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 录入时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
}
|
||||
144
src_jbo/jbo/app/tenwa/calc/LC_PROJ_SUBSECTION_RENT_PLAN.java
Normal file
144
src_jbo/jbo/app/tenwa/calc/LC_PROJ_SUBSECTION_RENT_PLAN.java
Normal file
@ -0,0 +1,144 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_PROJ_SUBSECTION_RENT_PLAN{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_PROJ_SUBSECTION_RENT_PLAN";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 报价编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String QUOT_ID = "QUOT_ID";
|
||||
/**
|
||||
* 客户编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CUST_ID = "CUST_ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String PLAN_LIST = "PLAN_LIST";
|
||||
/**
|
||||
* 计划日期 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_DATE = "PLAN_DATE";
|
||||
/**
|
||||
* 收付状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_STATUS = "PLAN_STATUS";
|
||||
/**
|
||||
* 租金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT = "RENT";
|
||||
/**
|
||||
* 财务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS = "CORPUS";
|
||||
/**
|
||||
* 财务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST = "INTEREST";
|
||||
/**
|
||||
* 应收罚息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String PENALTY = "PENALTY";
|
||||
/**
|
||||
* 业务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_BUSINESS = "CORPUS_BUSINESS";
|
||||
/**
|
||||
* 业务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_BUSINESS = "INTEREST_BUSINESS";
|
||||
/**
|
||||
* 租金调整值 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT_ADJUST = "RENT_ADJUST";
|
||||
/**
|
||||
* 本期后本金余额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String ALL_REMAIN_CORPUS = "ALL_REMAIN_CORPUS";
|
||||
/**
|
||||
* 结算方式 STRING(32)<br>
|
||||
*/
|
||||
public static final String SETTLE_METHOD = "SETTLE_METHOD";
|
||||
/**
|
||||
* 币种 STRING(32)<br>
|
||||
*/
|
||||
public static final String COIN = "COIN";
|
||||
/**
|
||||
* 年利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String YEAR_RATE = "YEAR_RATE";
|
||||
/**
|
||||
* 备注 STRING(100)<br>
|
||||
*/
|
||||
public static final String MEMO = "MEMO";
|
||||
/**
|
||||
* 流程编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 登记人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 登记部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 登记时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 计息日 STRING(32)<br>
|
||||
*/
|
||||
public static final String INTEREST_DATE = "INTEREST_DATE";
|
||||
/**
|
||||
* subsection_number INT(10)<br>
|
||||
*/
|
||||
public static final String subsection_number = "subsection_number";
|
||||
}
|
||||
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN.java
Normal file
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN.java
Normal file
@ -0,0 +1,196 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_SUBSECTION_RENT_PLAN{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_SUBSECTION_RENT_PLAN";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 报价编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String QUOT_ID = "QUOT_ID";
|
||||
/**
|
||||
* 客户编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CUST_ID = "CUST_ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String PLAN_LIST = "PLAN_LIST";
|
||||
/**
|
||||
* 计划日期 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_DATE = "PLAN_DATE";
|
||||
/**
|
||||
* 收付状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_STATUS = "PLAN_STATUS";
|
||||
/**
|
||||
* 租金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT = "RENT";
|
||||
/**
|
||||
* 财务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS = "CORPUS";
|
||||
/**
|
||||
* 财务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST = "INTEREST";
|
||||
/**
|
||||
* 应收罚息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String PENALTY = "PENALTY";
|
||||
/**
|
||||
* 业务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_BUSINESS = "CORPUS_BUSINESS";
|
||||
/**
|
||||
* 业务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_BUSINESS = "INTEREST_BUSINESS";
|
||||
/**
|
||||
* 租金调整值 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT_ADJUST = "RENT_ADJUST";
|
||||
/**
|
||||
* 本期后本金余额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String ALL_REMAIN_CORPUS = "ALL_REMAIN_CORPUS";
|
||||
/**
|
||||
* 结算方式 STRING(32)<br>
|
||||
*/
|
||||
public static final String SETTLE_METHOD = "SETTLE_METHOD";
|
||||
/**
|
||||
* 币种 STRING(32)<br>
|
||||
*/
|
||||
public static final String COIN = "COIN";
|
||||
/**
|
||||
* 年利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String YEAR_RATE = "YEAR_RATE";
|
||||
/**
|
||||
* 备注 STRING(100)<br>
|
||||
*/
|
||||
public static final String MEMO = "MEMO";
|
||||
/**
|
||||
* 流程编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 登记人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 登记部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 登记时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 计息日 STRING(32)<br>
|
||||
*/
|
||||
public static final String INTEREST_DATE = "INTEREST_DATE";
|
||||
/**
|
||||
* 代收审计状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String AUDIT_STATE = "AUDIT_STATE";
|
||||
/**
|
||||
* 收款状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String COLLECT_STATUS = "COLLECT_STATUS";
|
||||
/**
|
||||
* 收款描述 STRING(200)<br>
|
||||
*/
|
||||
public static final String COLLECT_MSG = "COLLECT_MSG";
|
||||
/**
|
||||
* 失败时间 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_TIME = "FAILURE_TIME";
|
||||
/**
|
||||
* 失败原因 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_REASON = "FAILURE_REASON";
|
||||
/**
|
||||
* 批量交易流水号,若拆分,以,分割 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_NO = "BATCH_NO";
|
||||
/**
|
||||
* 批量处理状态 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_STATUS = "BATCH_STATUS";
|
||||
/**
|
||||
* batch_sn STRING(200)<br>
|
||||
*/
|
||||
public static final String batch_sn = "batch_sn";
|
||||
/**
|
||||
* SPARE_BATCH_NO STRING(32)<br>
|
||||
*/
|
||||
public static final String SPARE_BATCH_NO = "SPARE_BATCH_NO";
|
||||
/**
|
||||
* CORPUS_SP DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_SP = "CORPUS_SP";
|
||||
/**
|
||||
* INTEREST_sp DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_sp = "INTEREST_sp";
|
||||
/**
|
||||
* splitting_status STRING(2)<br>
|
||||
*/
|
||||
public static final String splitting_status = "splitting_status";
|
||||
/**
|
||||
* charge_way STRING(10)<br>
|
||||
*/
|
||||
public static final String charge_way = "charge_way";
|
||||
/**
|
||||
* subsection_number INT(10)<br>
|
||||
*/
|
||||
public static final String subsection_number = "subsection_number";
|
||||
}
|
||||
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN_HIS.java
Normal file
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN_HIS.java
Normal file
@ -0,0 +1,196 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_SUBSECTION_RENT_PLAN_HIS{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_SUBSECTION_RENT_PLAN_HIS";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 报价编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String QUOT_ID = "QUOT_ID";
|
||||
/**
|
||||
* 客户编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CUST_ID = "CUST_ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String PLAN_LIST = "PLAN_LIST";
|
||||
/**
|
||||
* 计划日期 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_DATE = "PLAN_DATE";
|
||||
/**
|
||||
* 收付状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_STATUS = "PLAN_STATUS";
|
||||
/**
|
||||
* 租金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT = "RENT";
|
||||
/**
|
||||
* 财务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS = "CORPUS";
|
||||
/**
|
||||
* 财务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST = "INTEREST";
|
||||
/**
|
||||
* 应收罚息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String PENALTY = "PENALTY";
|
||||
/**
|
||||
* 业务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_BUSINESS = "CORPUS_BUSINESS";
|
||||
/**
|
||||
* 业务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_BUSINESS = "INTEREST_BUSINESS";
|
||||
/**
|
||||
* 租金调整值 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT_ADJUST = "RENT_ADJUST";
|
||||
/**
|
||||
* 本期后本金余额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String ALL_REMAIN_CORPUS = "ALL_REMAIN_CORPUS";
|
||||
/**
|
||||
* 结算方式 STRING(32)<br>
|
||||
*/
|
||||
public static final String SETTLE_METHOD = "SETTLE_METHOD";
|
||||
/**
|
||||
* 币种 STRING(32)<br>
|
||||
*/
|
||||
public static final String COIN = "COIN";
|
||||
/**
|
||||
* 年利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String YEAR_RATE = "YEAR_RATE";
|
||||
/**
|
||||
* 备注 STRING(100)<br>
|
||||
*/
|
||||
public static final String MEMO = "MEMO";
|
||||
/**
|
||||
* 流程编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 登记人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 登记部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 登记时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 计息日 STRING(32)<br>
|
||||
*/
|
||||
public static final String INTEREST_DATE = "INTEREST_DATE";
|
||||
/**
|
||||
* 代收审计状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String AUDIT_STATE = "AUDIT_STATE";
|
||||
/**
|
||||
* 收款状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String COLLECT_STATUS = "COLLECT_STATUS";
|
||||
/**
|
||||
* 收款描述 STRING(200)<br>
|
||||
*/
|
||||
public static final String COLLECT_MSG = "COLLECT_MSG";
|
||||
/**
|
||||
* 失败时间 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_TIME = "FAILURE_TIME";
|
||||
/**
|
||||
* 失败原因 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_REASON = "FAILURE_REASON";
|
||||
/**
|
||||
* 批量交易流水号,若拆分,以,分割 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_NO = "BATCH_NO";
|
||||
/**
|
||||
* 批量处理状态 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_STATUS = "BATCH_STATUS";
|
||||
/**
|
||||
* 一笔批量交易流水内项数SN STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_SN = "BATCH_SN";
|
||||
/**
|
||||
* SPARE_BATCH_NO STRING(32)<br>
|
||||
*/
|
||||
public static final String SPARE_BATCH_NO = "SPARE_BATCH_NO";
|
||||
/**
|
||||
* CORPUS_SP DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_SP = "CORPUS_SP";
|
||||
/**
|
||||
* INTEREST_sp DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_sp = "INTEREST_sp";
|
||||
/**
|
||||
* splitting_status STRING(2)<br>
|
||||
*/
|
||||
public static final String splitting_status = "splitting_status";
|
||||
/**
|
||||
* charge_way STRING(10)<br>
|
||||
*/
|
||||
public static final String charge_way = "charge_way";
|
||||
/**
|
||||
* subsection_number INT(10)<br>
|
||||
*/
|
||||
public static final String subsection_number = "subsection_number";
|
||||
}
|
||||
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN_TEMP.java
Normal file
196
src_jbo/jbo/app/tenwa/calc/LC_SUBSECTION_RENT_PLAN_TEMP.java
Normal file
@ -0,0 +1,196 @@
|
||||
package jbo.app.tenwa.calc;
|
||||
|
||||
import java.lang.String;
|
||||
|
||||
/**
|
||||
* - JBO命名常量类<br><br>
|
||||
* Note: This file is generated by ADE tools, <em>dont</em> modify it.<br>
|
||||
|
||||
*/
|
||||
public interface LC_SUBSECTION_RENT_PLAN_TEMP{
|
||||
/**
|
||||
* <br><br>
|
||||
* 代表本类映射的BizObjectClass
|
||||
*/
|
||||
public static final String CLASS_NAME = "jbo.app.tenwa.calc.LC_SUBSECTION_RENT_PLAN_TEMP";
|
||||
/**
|
||||
* 标识 STRING(32)<br>
|
||||
*/
|
||||
public static final String ID = "ID";
|
||||
/**
|
||||
* 报价编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String QUOT_ID = "QUOT_ID";
|
||||
/**
|
||||
* 客户编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CUST_ID = "CUST_ID";
|
||||
/**
|
||||
* 项目编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_ID = "PROJECT_ID";
|
||||
/**
|
||||
* 项目方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PROJECT_PLAN_NUMBER = "PROJECT_PLAN_NUMBER";
|
||||
/**
|
||||
* 合同编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_ID = "CONTRACT_ID";
|
||||
/**
|
||||
* 合同方案编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String CONTRACT_PLAN_NUMBER = "CONTRACT_PLAN_NUMBER";
|
||||
/**
|
||||
* 投放编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String PAYMENT_NUMBER = "PAYMENT_NUMBER";
|
||||
/**
|
||||
* 期次 INT(10)<br>
|
||||
*/
|
||||
public static final String PLAN_LIST = "PLAN_LIST";
|
||||
/**
|
||||
* 计划日期 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_DATE = "PLAN_DATE";
|
||||
/**
|
||||
* 收付状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String PLAN_STATUS = "PLAN_STATUS";
|
||||
/**
|
||||
* 租金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT = "RENT";
|
||||
/**
|
||||
* 财务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS = "CORPUS";
|
||||
/**
|
||||
* 财务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST = "INTEREST";
|
||||
/**
|
||||
* 应收罚息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String PENALTY = "PENALTY";
|
||||
/**
|
||||
* 业务本金 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_BUSINESS = "CORPUS_BUSINESS";
|
||||
/**
|
||||
* 业务租息 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_BUSINESS = "INTEREST_BUSINESS";
|
||||
/**
|
||||
* 租金调整值 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String RENT_ADJUST = "RENT_ADJUST";
|
||||
/**
|
||||
* 本期后本金余额 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String ALL_REMAIN_CORPUS = "ALL_REMAIN_CORPUS";
|
||||
/**
|
||||
* 结算方式 STRING(32)<br>
|
||||
*/
|
||||
public static final String SETTLE_METHOD = "SETTLE_METHOD";
|
||||
/**
|
||||
* 币种 STRING(32)<br>
|
||||
*/
|
||||
public static final String COIN = "COIN";
|
||||
/**
|
||||
* 年利率 DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String YEAR_RATE = "YEAR_RATE";
|
||||
/**
|
||||
* 备注 STRING(100)<br>
|
||||
*/
|
||||
public static final String MEMO = "MEMO";
|
||||
/**
|
||||
* 流程编号 STRING(32)<br>
|
||||
*/
|
||||
public static final String FLOWUNID = "FLOWUNID";
|
||||
/**
|
||||
* 登记人 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTUSERID = "INPUTUSERID";
|
||||
/**
|
||||
* 登记部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTORGID = "INPUTORGID";
|
||||
/**
|
||||
* 登记时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String INPUTTIME = "INPUTTIME";
|
||||
/**
|
||||
* 更新人 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEUSERID = "UPDATEUSERID";
|
||||
/**
|
||||
* 更新部门 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATEORGID = "UPDATEORGID";
|
||||
/**
|
||||
* 更新时间 STRING(32)<br>
|
||||
*/
|
||||
public static final String UPDATETIME = "UPDATETIME";
|
||||
/**
|
||||
* 计息日 STRING(32)<br>
|
||||
*/
|
||||
public static final String INTEREST_DATE = "INTEREST_DATE";
|
||||
/**
|
||||
* 代收审计状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String AUDIT_STATE = "AUDIT_STATE";
|
||||
/**
|
||||
* 收款状态 STRING(32)<br>
|
||||
*/
|
||||
public static final String COLLECT_STATUS = "COLLECT_STATUS";
|
||||
/**
|
||||
* 收款描述 STRING(200)<br>
|
||||
*/
|
||||
public static final String COLLECT_MSG = "COLLECT_MSG";
|
||||
/**
|
||||
* 失败时间 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_TIME = "FAILURE_TIME";
|
||||
/**
|
||||
* 失败原因 STRING(200)<br>
|
||||
*/
|
||||
public static final String FAILURE_REASON = "FAILURE_REASON";
|
||||
/**
|
||||
* 交易流水号,若拆分,以,分割 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_NO = "BATCH_NO";
|
||||
/**
|
||||
* 批量处理状态 STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_STATUS = "BATCH_STATUS";
|
||||
/**
|
||||
* 一笔批量交易流水内项数SN STRING(200)<br>
|
||||
*/
|
||||
public static final String BATCH_SN = "BATCH_SN";
|
||||
/**
|
||||
* SPARE_BATCH_NO STRING(32)<br>
|
||||
*/
|
||||
public static final String SPARE_BATCH_NO = "SPARE_BATCH_NO";
|
||||
/**
|
||||
* CORPUS_SP DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String CORPUS_SP = "CORPUS_SP";
|
||||
/**
|
||||
* INTEREST_sp DOUBLE(18)<br>
|
||||
*/
|
||||
public static final String INTEREST_sp = "INTEREST_sp";
|
||||
/**
|
||||
* splitting_status STRING(2)<br>
|
||||
*/
|
||||
public static final String splitting_status = "splitting_status";
|
||||
/**
|
||||
* charge_way STRING(10)<br>
|
||||
*/
|
||||
public static final String charge_way = "charge_way";
|
||||
/**
|
||||
* subsection_number INT(10)<br>
|
||||
*/
|
||||
public static final String subsection_number = "subsection_number";
|
||||
}
|
||||
@ -125,4 +125,9 @@ public interface VI_LC_RENT_PLAN{
|
||||
* »ØÁý״̬ STRING(20)<br>
|
||||
*/
|
||||
public static final String planstatus = "planstatus";
|
||||
|
||||
/**
|
||||
* ÏîÄ¿id STRING(20)<br>
|
||||
*/
|
||||
public static final String project_id = "project_id";
|
||||
}
|
||||
96
src_sql/预投SQL/v20210831/maliang20210831.sql
Normal file
96
src_sql/预投SQL/v20210831/maliang20210831.sql
Normal file
@ -0,0 +1,96 @@
|
||||
一合同多车发票相关调整
|
||||
1)LB_INVOICE_INFO_TEMP 添加字段equipment_id
|
||||
2)新增两个对应form表单配置
|
||||
SELECT * FROM `apzl`.`awe_do_catalog` WHERE dono='LbInvoiceTemp';
|
||||
SELECT * FROM `apzl`.`awe_do_library` WHERE dono='LbInvoiceTemp';
|
||||
|
||||
SELECT * FROM `apzl`.`awe_do_catalog` WHERE dono='LBInvoiceList';
|
||||
SELECT * FROM `apzl`.`awe_do_library` WHERE dono='LBInvoiceList';
|
||||
|
||||
|
||||
ALTER TABLE `apzl`.`lb_invoice_info_temp` ADD COLUMN `equipment_id` varchar(32) CHARACTER SET gbk COLLATE gbk_chinese_ci NULL DEFAULT NULL COMMENT '车辆信息id' AFTER `Invoice_money_total`;
|
||||
ALTER TABLE `apzl`.`lb_invoice_info` ADD COLUMN `equipment_id` varchar(32) CHARACTER SET gbk COLLATE gbk_chinese_ci NULL DEFAULT NULL COMMENT '车辆信息id' AFTER `Invoice_money_total`;
|
||||
|
||||
INSERT INTO `apzl`.`awe_do_catalog`(`dono`, `doname`, `dodescribe`, `dotype`, `doclass`, `isinuse`, `colcount`, `modeid`, `jboclass`, `jbofrom`, `jbowhere`, `jbogroup`, `jboorder`, `businessprocess`, `exportflag`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `remark`, `isvalidate`, `parent`) VALUES ('LbInvoiceTemp', '发票信息临时表2', NULL, '30', NULL, '1', '2', 'default', 'jbo.com.tenwa.entity.comm.invoice.LB_INVOICE_INFO_TEMP', 'O left join jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR lec on O.contract_id=lec.contract_id and lec.id=O.equipment_id', 'O.contract_id=:id and O.equipment_id=:equipment_id', '', '', 'com.amarsoft.awe.dw.handler.impl.CommonHandler', '', 'SYS_Designer', '2020/03/16 11:42:16', 'SYS_Designer', '2020/03/16 18:07:11', '', '1', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1000', '1000', '1', 'O', 'id', 'id', 'String', '', '唯一标识', '', '1', 'Text', '1', '1', '', '', '', '32', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1005', '1005', '1', 'lec', 'FRAME_NUMBER', 'FRAME_NUMBER', 'String', '', '车架号', '', '1', 'Text', '1', '1', '', '', '', '100', '1', '1', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1006', '1006', '1', 'lec', 'ENGINE_NUMBER', 'ENGINE_NUMBER', 'String', '', '发动机号', '', '1', 'Text', '1', '1', '', '', '', '100', '1', '1', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1010', '1010', '1', 'O', 'project_id', 'project_id', 'String', '', '项目id', '', '1', 'Text', '1', '1', '', '', '', '32', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1020', '1020', '1', 'O', 'contract_id', 'contract_id', 'String', '', '合同id', '', '1', 'Text', '1', '1', '', '', '', '32', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1025', '1025', '1', 'O', 'equipment_id', 'equipment_id', 'String', '', '车辆信息id', '', '1', 'Text', '1', '1', '', '', '', '32', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1030', '1030', '1', 'O', 'Invoice_code', 'Invoice_code', 'String', '', '发票代码', '', '1', 'Text', '1', '1', '', '', '', '32', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1040', '1040', '1', 'O', 'Invoice_number', 'Invoice_number', 'String', '', '发票号码', '', '1', 'Text', '1', '1', '', '', '', '32', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1050', '1050', '1', 'O', 'Invoice_date', 'Invoice_date', 'String', '', '开票日期', '', '1', 'Date', '3', '2', '', '', '', '100', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1060', '1060', '1', 'O', 'Invoice_money', 'Invoice_money', 'String', '', '开票金额', '', '1', 'Text', '2', '1', '', '', '', '20', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1065', '1065', '1', 'O', 'tax_rate', 'tax_rate', 'Number', '13', '税率', '', '1', 'Text', '2', '1', '', '', '', '20', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1070', '1070', '1', 'O', 'tax_due', 'tax_due', 'String', '', '税金', '', '1', 'Text', '2', '1', '', '', '', '20', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1080', '1080', '1', 'O', 'flow_unid', 'flow_unid', 'String', '', '流程id', '', '1', 'Text', '1', '1', '', '', '', '32', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1110', '1110', '1', 'O', 'inputuserid', 'inputuserid', 'String', '', '登记人', '', '1', 'Text', '1', '1', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1120', '1120', '1', 'O', 'inputorgid', 'inputorgid', 'String', '', '登记部门', '', '1', 'Text', '1', '1', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1130', '1130', '1', 'O', 'inputtime', 'inputtime', 'String', '', '登记时间', '', '1', 'Date', '3', '2', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1140', '1140', '1', 'O', 'updateuserid', 'updateuserid', 'String', '', '更新人', '', '1', 'Text', '1', '1', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1150', '1150', '1', 'O', 'updateorgid', 'updateorgid', 'String', '', '更新部门', '', '1', 'Text', '1', '1', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LbInvoiceTemp', '1160', '1160', '1', 'O', 'updatetime', 'updatetime', 'String', '', '更新时间', '', '1', 'Date', '3', '2', '', '', '', '100', '0', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', '8009011U00000032', '2021/06/23 13:49:13', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_catalog`(`dono`, `doname`, `dodescribe`, `dotype`, `doclass`, `isinuse`, `colcount`, `modeid`, `jboclass`, `jbofrom`, `jbowhere`, `jbogroup`, `jboorder`, `businessprocess`, `exportflag`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `remark`, `isvalidate`, `parent`) VALUES ('LBInvoiceList', '发票信息列表', NULL, '30', NULL, '1', '1', 'default', 'jbo.com.tenwa.lease.comm.LB_EQUIPMENT_CAR', 'O left join jbo.com.tenwa.entity.comm.invoice.LB_INVOICE_INFO_TEMP lec on O.contract_id=lec.contract_id and O.id=lec.equipment_id', 'O.contract_id=:contractId ', '', 'inputtime', '', '', 'SYS_Designer', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '1', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1040', '1040', '1', '', '\'\'', 'opinion', 'String', '', '操作', '', '1', 'Text', '1', '1', '', '', '', '32', '1', '0', '0', '1', '0', 0, '', '', '', 'SYS_Designer', '2019/07/15 17:05:47', 'SYS_Designer', '2021/06/15 11:08:12', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1050', '1050', '1', 'O', 'BRAND', 'BRAND', 'String', '', '品牌', '', '1', 'Text', '1', '1', '', '', '', '30', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1055', '1055', '1', 'O', 'car_series', 'car_series', 'String', '', '车系', '', '1', 'Text', '1', '1', '', '', '', '80', '1', '0', '0', '1', '0', 0, '', '', '', 'SYS_Designer', '2020/09/11 10:37:42', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1060', '1060', '1', 'O', 'MODEL', 'MODEL', 'String', '', '型号及配置', '', '1', 'Text', '1', '1', '', '', '', '200', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1065', '1065', '1', 'O', 'FRAME_NUMBER', 'FRAME_NUMBER', 'String', '', '车架号', '', '1', 'Text', '1', '1', '', '', '', '100', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1070', '1070', '1', 'O', 'ENGINE_NUMBER', 'ENGINE_NUMBER', 'String', '', '发动机号', '', '1', 'Text', '1', '1', '', '', '', '100', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1071', '1071', '1', 'O', 'EQUIP_PRICE', 'EQUIP_PRICE', 'String', '', '车辆交易价格', '', '1', 'Text', '1', '1', '', '', '', '100', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1075', '1075', '1', 'lec', 'Invoice_code', 'Invoice_code', 'String', '', '发票代码', '', '1', 'Text', '1', '1', '', '', '', '32', '1', '0', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', 'SYS_Designer', '2021/06/15 11:08:12', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1080', '1080', '1', 'lec', 'INVOICE_MONEY', 'INVOICE_MONEY', 'Number', '', '开票金额', '', '2', 'Text', '2', '3', '', '', '', '20', '1', '0', '0', '1', '1', 0, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', 'SYS_Designer', '2021/06/15 15:21:57', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1085', '1085', '1', 'lec', 'tax_due', 'tax_due', 'Number', '', '税金', '', '2', 'Text', '2', '3', '', '', '', NULL, '1', '1', '0', '1', '0', 0, '', '', '', 'SYS_Designer', '2018/08/15 14:15:59', 'SYS_Designer', '2021/06/15 11:08:12', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1090', '1090', '1', 'lec', 'equipment_id', 'equipment_id', 'String', '', '车辆信息id', '', '1', 'Text', '1', '1', '', '', '', '20', '0', '1', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/03/16 11:42:17', 'SYS_Designer', '2021/06/15 11:08:12', '0', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1110', '1110', '1', 'O', 'id', 'id', 'String', '', '车辆信息id', '', '1', 'Text', '1', '1', '', '', '', '30', '0', '1', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:08:12', '', '', '1', '', '', '', '');
|
||||
INSERT INTO `apzl`.`awe_do_library`(`dono`, `colindex`, `sortno`, `isinuse`, `coltablename`, `colactualname`, `colname`, `coltype`, `coldefaultvalue`, `colheader`, `colunit`, `colcolumntype`, `coleditstyle`, `colcheckformat`, `colalign`, `coleditsourcetype`, `coleditsource`, `colhtmlstyle`, `collimit`, `colvisible`, `colreadonly`, `colrequired`, `colsortable`, `isfilter`, `colspan`, `isautocomplete`, `groupid`, `colfilterrefid`, `inputuser`, `inputtime`, `updateuser`, `updatetime`, `isaudit`, `colfilterattrs`, `isupdate`, `parentcolindex`, `tips`, `colinnerbtevent`, `colfilteroptions`) VALUES ('LBInvoiceList', '1130', '1130', '1', 'O', 'contract_id', 'contract_id', 'String', '', '发票信息id', '', '1', 'Text', '1', '1', '', '', '', '30', '0', '1', '0', '1', '1', 1, '0', '', '', 'SYS_DESIGNER', '2020/09/11 10:00:58', 'SYS_Designer', '2021/06/15 11:24:09', '0', '', '1', '', '', '', '');
|
||||
|
||||
|
||||
2.一合同多车合同模板调整
|
||||
|
||||
select * from BF_LABLECONFIG where tagname like '%zc_%';
|
||||
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3005', 'zc005', 'zc_carinfo1', '中车车辆信息序号1', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 0,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3006', 'zc006', 'zc_carinfo2', '中车车辆信息序号2', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 1,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3007', 'zc007', 'zc_carinfo3', '中车车辆信息序号3', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 2,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3008', 'zc008', 'zc_carinfo4', '中车车辆信息序号4', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 3,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3009', 'zc009', 'zc_carinfo5', '中车车辆信息序号5', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 4,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3010', 'zc010', 'zc_carinfo6', '中车车辆信息序号6', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 5,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3011', 'zc011', 'zc_carinfo7', '中车车辆信息序号7', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 6,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3012', 'zc012', 'zc_carinfo8', '中车车辆信息序号8', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 7,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3013', 'zc013', 'zc_carinfo9', '中车车辆信息序号9', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 8,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3014', 'zc014', 'zc_carinfo10', '中车车辆信息序号10', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 9,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3015', 'zc015', 'zc_carinfo11', '中车车辆信息序号11', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 10,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3016', 'zc016', 'zc_carinfo12', '中车车辆信息序号12', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 11,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3017', 'zc017', 'zc_carinfo13', '中车车辆信息序号13', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 12,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3018', 'zc018', 'zc_carinfo14', '中车车辆信息序号14', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 13,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3019', 'zc019', 'zc_carinfo15', '中车车辆信息序号15', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 14,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3020', 'zc020', 'zc_carinfo16', '中车车辆信息序号16', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 15,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3021', 'zc021', 'zc_carinfo17', '中车车辆信息序号17', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 16,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3022', 'zc022', 'zc_carinfo18', '中车车辆信息序号18', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 17,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3023', 'zc023', 'zc_carinfo19', '中车车辆信息序号19', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 18,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
INSERT INTO `apzl`.`bf_lableconfig`(`ID`, `TAGNUMBER`, `TAGNAME`, `TITLE`, `TAGTYPE`, `VALUETYPE`, `VALUEFIELD`, `VALUEMETHOD`, `THOUSANDSFIELD`, `ISSHOEINDEX`, `REMARK`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`, `OPERATORCLASS`) VALUES ('6466f88f96b6e93442587d3024', 'zc024', 'zc_carinfo20', '中车车辆信息序号20', 'tag_type2', 'value_type3', 'MODEL,FRAME_NUMBER,EQUIP_PRICE,DEVICE_TYPE2,MODEL2,PLATE_NUMBER2,FRAME_NUMBER2', 'SELECT \r\n MODEL,\r\n FRAME_NUMBER,\r\n EQUIP_PRICE,\r\n \r\n DEVICE_TYPE DEVICE_TYPE2,\r\n MODEL MODEL2,\r\n LICENSE_PLATE_NUMBER PLATE_NUMBER2,\r\n FRAME_NUMBER FRAME_NUMBER2\r\nFROM\r\n LB_EQUIPMENT_CAR_TEMP lec\r\nWHERE lec.FlowUnid =:{FLOW_UNID} limit 19,1', '', 'N', '', '', '', '', '', '', '', 'word_default_class');
|
||||
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('1f876eec2d5341d494065fabc3fc456e', '6466f88f96b6e93442587d3005', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('9c0f29bee1a7442d93bda25d003579f6', '6466f88f96b6e93442587d3006', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('21128a024d824d2fac7aa6af5555e120', '6466f88f96b6e93442587d3007', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('423451ab76e04afbaf1eda7e3caefdab', '6466f88f96b6e93442587d3008', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('5f785f593ddb4091b996fe2c9498e754', '6466f88f96b6e93442587d3009', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('eb62e3afd76f4e379c60bdd56b118029', '6466f88f96b6e93442587d3010', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('209d60c0fb1b43b8a0a16dc6383b33cd', '6466f88f96b6e93442587d3011', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('40f93a4d187f4431a90c4d5abf131839', '6466f88f96b6e93442587d3012', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('123ce3b6aea44a24ae77dc83cc1fb4b7', '6466f88f96b6e93442587d3013', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('996d23d8fe21413abed181154ab6db02', '6466f88f96b6e93442587d3014', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('09eea7aa47424b978ef2e1abf7dd6830', '6466f88f96b6e93442587d3015', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('fa1985f7d08940fcaa8be408e37edae2', '6466f88f96b6e93442587d3016', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('643f45aa39cc410cbe8c72aaaa615339', '6466f88f96b6e93442587d3017', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('1d76e8aef07f4a32b13d188e13f88d1e', '6466f88f96b6e93442587d3018', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('80c41dd4488a44438fe2746d57843e67', '6466f88f96b6e93442587d3019', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('78ce98a4bd114e34a6250a529af30b6c', '6466f88f96b6e93442587d3020', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('2d84d577e216405f820f57e92ab167f8', '6466f88f96b6e93442587d3021', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('647d987a44c945638d9cf8e1c9b43358', '6466f88f96b6e93442587d3022', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('d791b1564fb94b3e9010f3d21a352c8b', '6466f88f96b6e93442587d3023', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
INSERT INTO `apzl`.`bf_templatelable`(`ID`, `LABLEID`, `TEMPLATEID`, `INPUTUSERID`, `INPUTORGID`, `UPDATEUSERID`, `UPDATEORGID`, `INPUTTIME`, `UPDATETIME`) VALUES ('79fbf1ffbb5b4955806da4c24fe41048', '6466f88f96b6e93442587d3024', 'a37a3bc1919c4ba39d8ba6348fb1962e', NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
|
||||
|
||||
65
src_sql/预投SQL/v20210831/yjf20210831.sql
Normal file
65
src_sql/预投SQL/v20210831/yjf20210831.sql
Normal file
@ -0,0 +1,65 @@
|
||||
|
||||
-- 添加字段
|
||||
alter table LB_ACTUAL_PAYMENT_INFO_TEMP add column pay_mode VARCHAR(10) DEFAULT 'cgb' comment '付款方式' ;
|
||||
alter table LB_ACTUAL_PAYMENT_INFO_TEMP add bank varchar(200) comment '本方银行';
|
||||
alter table LB_ACTUAL_PAYMENT_INFO_TEMP add account varchar(200) comment '本方账户';
|
||||
alter table LB_ACTUAL_PAYMENT_INFO_TEMP add acc_number varchar(200) comment '本方帐号';
|
||||
|
||||
alter table LB_ACTUAL_PAYMENT_INFO add column pay_mode VARCHAR(10) comment '付款方式' ;
|
||||
alter table LB_ACTUAL_PAYMENT_INFO add bank varchar(200) comment '本方银行';
|
||||
alter table LB_ACTUAL_PAYMENT_INFO add account varchar(200) comment '本方账户';
|
||||
alter table LB_ACTUAL_PAYMENT_INFO add acc_number varchar(200) comment '本方帐号';
|
||||
|
||||
-- 修改字段长度
|
||||
alter table lc_fund_income_callback_detail_temp modify column SQRNBR varchar(50);
|
||||
alter table lc_fund_income_callback_detail modify column SQRNBR varchar(50);
|
||||
|
||||
-- 本次付款明细过滤条件修改
|
||||
update awe_do_library set isfilter = '0' where dono = 'ActualPaymentCarTempList';
|
||||
update awe_do_library set isfilter = '1',colfilteroptions ='Like' where dono = 'ActualPaymentCarTempList' and colactualname in ('CUSTOMER_NAME','CONTRACT_NUMBER','REQSTS','ERRTXT');
|
||||
-- 付款计划
|
||||
update awe_do_library set isfilter ='0' where dono='VIActualFundPlan';
|
||||
update awe_do_library set isfilter ='1',colfilteroptions ='Like' where dono='VIActualFundPlan' and colname in ('contract_number','customer_name');
|
||||
|
||||
-- 添加状态码字典
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '104', '操作员错误', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '106', '操作员密码错误', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '199', '网银其它错误', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '218', '重复的流水号', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '242', '无符合条件的交易记录', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '407', '取证书故障', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '419', '签名数据出错', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '616', '存在重复的客户批次子流水号', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '888', '没有收到主机返回数据', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', '889', '交易失败', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A01', '企业客户号不能为空', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A02', '企业财务系统流水号不能为空,且长度不能大于20', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A03', '上送账号格式不正确', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A04', '被查询或转出账号未加挂银企直联', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A05', '操作员不能为空,且长度不能大于大于12', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'A06', '操作员密码不能为空', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'C99', '主机业务处理异常', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'D46', '没有使用该接口的权限', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'E01', '证书有效期已过', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'E02', '该用户没有绑定相关证书', '1', 'system', '2021/07/26 17:20:31');
|
||||
INSERT INTO `apzl`.`code_library` (`codeno`, `itemno`, `itemname`, `isinuse`, `inputuser`, `inputtime`) VALUES ('cgb_describe', 'E03', '验签失败', '1', 'system', '2021/07/26 17:20:31');
|
||||
|
||||
-- 添加选择框
|
||||
INSERT INTO `apzl`.`select_catalog` (`selname`, `seltype`, `seldescribe`, `seltablename`, `selprimarykey`, `selbrowsemode`, `selargs`, `selhidefield`, `selcode`, `selfieldname`, `selfielddisp`, `selreturnvalue`, `selfilterfield`, `isinuse`, `mutilorsingle`, `attribute1`, `attribute2`, `attribute3`, `attribute4`, `attribute5`, `inputuser`, `inputorg`, `inputtime`, `updateuser`, `updatetime`, `remark`) VALUES ('SelectOwnAccountPay', 'Sql', '查询本方账户', '', '', 'Grid', 'String accName', '', 'SELECT acc_number,acc_bank,acc_name FROM own_account WHERE state_=\'0010\' AND acc_type=\'0010\' AND (account_type=\'out_account\' OR account_type=\'inAndOut_account\') and acc_name = \'#accName\'', '开户帐号,开户银行,开户户名', 'acc_number@style={width:200px;}@acc_name@style={width:400px;}', 'acc_number@acc_bank@acc_name', '', '1', 'Single', '', '', '', '', '', 'SYS_Designer', '', '2021/07/23 09:38:25', 'SYS_Designer', '2021/07/23 09:42:57', '');
|
||||
|
||||
|
||||
-- 添加广发银企日志
|
||||
CREATE TABLE `lb_cgb_log` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`type` varchar(10) DEFAULT NULL COMMENT '类型 pay:转账,query:查询',
|
||||
`flow_unid` varchar(50) DEFAULT NULL COMMENT '流程id',
|
||||
`batch_no` varchar(50) DEFAULT NULL COMMENT '批次号',
|
||||
`req_msg` mediumtext,
|
||||
`ret_msg` text,
|
||||
`req_time` varchar(50) DEFAULT NULL COMMENT '发起时间',
|
||||
`ret_time` varchar(50) DEFAULT NULL COMMENT '返回时间',
|
||||
`serial_num` varchar(50) DEFAULT NULL COMMENT '序号',
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `idx_no_num` (`batch_no`,`serial_num`)
|
||||
);
|
||||
|
||||
@ -1,5 +1,36 @@
|
||||
package com.tenwa.collectaudit.cache;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.amarsoft.app.awe.config.InitCollectConfig;
|
||||
import com.amarsoft.app.util.StringUtil;
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.gnete.security.crypt.Crypt;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.lease.app.allinpay.service.impl.AllinpayPaymentDo;
|
||||
import com.tenwa.quartz.DateUtil;
|
||||
import jbo.app.tenwa.calc.LC_COLLECT_MANUAL_INFO;
|
||||
import jbo.app.tenwa.calc.LC_RENT_INCOME;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN;
|
||||
import jbo.app.tenwa.customer.CUSTOMER_ACCOUNT;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITCHARGE_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO;
|
||||
import jbo.com.tenwa.lease.comm.*;
|
||||
import jbo.sys.CODE_LIBRARY;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.Scheduler;
|
||||
import org.quartz.SchedulerException;
|
||||
import org.quartz.impl.StdSchedulerFactory;
|
||||
|
||||
import java.io.File;
|
||||
import java.math.BigDecimal;
|
||||
import java.sql.SQLException;
|
||||
@ -10,47 +41,9 @@ import java.util.Map;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.Scheduler;
|
||||
import org.quartz.SchedulerException;
|
||||
import org.quartz.impl.StdSchedulerFactory;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.amarsoft.app.awe.config.InitCollectConfig;
|
||||
import com.amarsoft.app.util.StringUtil;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.gnete.security.crypt.Crypt;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.lease.app.allinpay.service.impl.AllinpayPaymentDo;
|
||||
import com.tenwa.quartz.DateUtil;
|
||||
|
||||
import jbo.app.tenwa.calc.LC_COLLECT_MANUAL_INFO;
|
||||
import jbo.app.tenwa.calc.LC_RENT_INCOME;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN;
|
||||
import jbo.app.tenwa.customer.CUSTOMER_ACCOUNT;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITCHARGE_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO;
|
||||
import jbo.com.tenwa.lease.comm.LB_BUCKLE_LOG;
|
||||
import jbo.com.tenwa.lease.comm.LB_CLEAR_FILE_RECORD;
|
||||
import jbo.com.tenwa.lease.comm.LB_INTFACE_FILE_RECORD;
|
||||
import jbo.com.tenwa.lease.comm.VI_BOND_COMPENSATORY;
|
||||
import jbo.com.tenwa.lease.comm.VI_LC_AUDIT_RENT_PLAN;
|
||||
import jbo.loan.VI_RENT_COLLECT;
|
||||
import jbo.sys.CODE_LIBRARY;
|
||||
|
||||
public class CollectAuditInfoCache {
|
||||
|
||||
private static Log log = LogFactory.getLog(CollectAuditInfoCache.class);
|
||||
|
||||
private String id;
|
||||
private String fileSavePath = "d:/tmp/als/InterFace";
|
||||
@ -812,13 +805,12 @@ public class CollectAuditInfoCache {
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量代收-发送请求
|
||||
* 批量代收-发送请求(定时任务--银联卡扣)
|
||||
* @param tx
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public String batchCollectManage(JBOTransaction tx) throws Exception{
|
||||
int i = 0,j = 0;
|
||||
String[] ids = id.split("@");
|
||||
StringBuffer parms = new StringBuffer();
|
||||
for (String str : ids) {
|
||||
@ -829,10 +821,9 @@ public class CollectAuditInfoCache {
|
||||
}
|
||||
}
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(VI_LC_AUDIT_RENT_PLAN.CLASS_NAME);
|
||||
BizObjectManager bc = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
//这里对天津与深圳的数据进行拆分
|
||||
List<BizObject> bolist = bm.createQuery("select distinct O.contract_id,O.plan_date,O.id,ca.ACC_NUMBER,ca.ACCOUNT,ca.BANK_NAME,O.rent from O , jbo.app.tenwa.customer.CUSTOMER_ACCOUNT ca where O.contract_id=ca.contract_id and ca.acc_type = 'Debit' and O.id in ("+parms.toString()+")").getResultList(false);
|
||||
if (bolist.size() != 0) {
|
||||
List<BizObject> bolist = bm.createQuery("select distinct O.contract_id,O.plan_date,O.id,ca.ACC_NUMBER,ca.ACCOUNT,ca.BANK_NAME,O.rent from O , jbo.app.tenwa.customer.CUSTOMER_ACCOUNT ca where O.contract_id=ca.contract_id and ca.acc_type = 'Debit' and O.id in (" + parms.toString() + ")").getResultList(false);
|
||||
if (bolist.size() > 0) {
|
||||
singleBatchCollectMoeny(tx, bolist);
|
||||
}
|
||||
return "系统正在处理中,请稍后";
|
||||
@ -1008,8 +999,11 @@ public class CollectAuditInfoCache {
|
||||
}
|
||||
|
||||
for (int i = 1; i <= snArray.length; i++) {
|
||||
|
||||
log.warn("ShenZhen counteroffer batch_no:"+query_sn+" batch_sn:"+snArray[(i-1)]+" rentid:"+bo.getAttribute("id").toString());
|
||||
Map<String, String> map = querySingleBatchCollect(tx, bo, query_sn, snArray[(i-1)]);
|
||||
if(map == null ) {
|
||||
continue;
|
||||
}
|
||||
if (snArray.length == 1) {
|
||||
if (map.containsKey("RET_CODE") && "0000".equals(map.get("RET_CODE"))) {
|
||||
//核销
|
||||
@ -1222,6 +1216,9 @@ public class CollectAuditInfoCache {
|
||||
// queryBatchXML(req_sn, query_sn, sn);
|
||||
//响应报文
|
||||
String strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
if(strResp==null || strResp.isEmpty()) {
|
||||
return null;
|
||||
}
|
||||
Map<String, String> map = getRetAndCode(strResp);
|
||||
//生成存盘、回盘文件
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
@ -1331,7 +1328,7 @@ public class CollectAuditInfoCache {
|
||||
return strbuff;
|
||||
}
|
||||
/**
|
||||
* 批量代收-发送请求
|
||||
* 批量代收-发送请求(报文组装,调用银联100001接口,更新租金计划batch_status状态)
|
||||
* @param tx
|
||||
* @param bc
|
||||
* @param bo
|
||||
@ -1346,37 +1343,46 @@ public class CollectAuditInfoCache {
|
||||
String currentYear = currentDateTime.substring(0,4);
|
||||
String month = currentDateTime.substring(5,7);
|
||||
String day = currentDateTime.substring(8,10);
|
||||
String merchantNumber = InitCollectConfig.MERCHANTID;
|
||||
String flag = InitCollectConfig.FLAG;
|
||||
String version = InitCollectConfig.C_VERSION;
|
||||
String merchantNumber = InitCollectConfig.MERCHANTID;//银联商户号
|
||||
String flag = InitCollectConfig.FLAG;//银联接口--代收标识
|
||||
String version = InitCollectConfig.C_VERSION;//接口版本号
|
||||
String date = currentYear+month+day;//提交日期
|
||||
String batch_title = "";
|
||||
int i = 0,j = 0;
|
||||
//创建文件路径
|
||||
String rootDir = this.fileSavePath;
|
||||
File file = new File(rootDir + File.separator + currentYear
|
||||
+ File.separator + month + File.separator
|
||||
//创建卡扣文件路径
|
||||
File file = new File( this.fileSavePath+ File.separator + currentYear + File.separator + month + File.separator
|
||||
+ day);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
String req_sn = System.currentTimeMillis()+"";//当日批次号
|
||||
batch_title = merchantNumber+"_"+flag+version+date+"_"+req_sn;
|
||||
//目录不存在则直接创建
|
||||
if(!file.exists()) file.mkdirs();
|
||||
|
||||
String req_sn = System.currentTimeMillis()+"";//卡扣批次号 REQ_SN
|
||||
//卡扣文件名称
|
||||
String batch_title = merchantNumber+"_"+flag+version+date+"_"+req_sn;
|
||||
//卡扣报文
|
||||
StringBuffer strbuff = collectBatch(req_sn,list);
|
||||
//响应报文
|
||||
String strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
for (BizObject bo : list) {
|
||||
//生成存盘、回盘文件
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
//接口调用,返回响应报文
|
||||
String strResp = "";
|
||||
try {
|
||||
strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
}catch (Exception e){
|
||||
JBOTransaction jboTransaction = null;
|
||||
try {
|
||||
String rentIds = getRentIds(list);
|
||||
jboTransaction = JBOFactory.createJBOTransaction();
|
||||
Transaction.createTransaction(jboTransaction).executeSQL("update lc_rent_plan set batch_sn=null where id in ('" + rentIds + "')");
|
||||
jboTransaction.commit();
|
||||
}catch (Exception e1){
|
||||
if (jboTransaction != null) jboTransaction.rollback();
|
||||
e1.printStackTrace();
|
||||
}
|
||||
throw new RuntimeException("深圳银联接口调用异常:", e);
|
||||
}
|
||||
//生成存盘、回盘文件(批量卡扣,日志表LB_INTFACE_FILE_RECORD.RELA_ID 存储卡扣批次号)
|
||||
BizObject bo = new BizObject("jbo.app.tenwa.calc.LC_RENT_PLAN");
|
||||
bo.setAttributeValue("id",req_sn);
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
//解析银联响应报文
|
||||
Map<String, String> map = getRetAndCodeByBatch(strResp);
|
||||
if (map.containsKey("RET_CODE")) {//清空批量代收状态
|
||||
StringBuilder updateIds = new StringBuilder();
|
||||
for (BizObject biz : list) {
|
||||
updateIds.append(biz.getAttribute("id").toString()).append("','");
|
||||
}
|
||||
String updateIdsStr = updateIds.delete(updateIds.length() - 3, updateIds.length()).toString();
|
||||
String updateIdsStr = getRentIds(list);
|
||||
//清空批量处理状态
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
bm.createQuery("update O set O.BATCH_STATUS=null,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=null where O.id in ('" + updateIdsStr + "')")
|
||||
@ -1392,31 +1398,37 @@ public class CollectAuditInfoCache {
|
||||
JBOTransaction trans = null;
|
||||
try {
|
||||
trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME, trans);
|
||||
BizObject bo0 = bm.createQuery("O.BATCH_NO=:BATCH_NO and O.BATCH_SN like '%" + map.get("SN" + k) + "%'").setParameter("BATCH_NO", map.get("REQ_SN")).getSingleResult(true);
|
||||
if (bo0 != null && "process".equals(bo0.getAttribute("BATCH_STATUS").getString())) {
|
||||
continue;
|
||||
}
|
||||
//响应成功
|
||||
if (map.containsKey("REQ_SN") && map.containsKey("RET_CODE" + k) && "0000".equals(map.get("RET_CODE" + k))) {
|
||||
bo0.setAttributeValue("BATCH_STATUS", "process");
|
||||
} else {//响应异常
|
||||
bo0.setAttributeValue("BATCH_STATUS", null);
|
||||
bo0.setAttributeValue("BATCH_NO", null);
|
||||
bo0.setAttributeValue("BATCH_SN", null);
|
||||
}
|
||||
bm.saveObject(bo0);
|
||||
Transaction sqlCa = Transaction.createTransaction(trans);
|
||||
SqlObject sqlObject = new SqlObject("update lc_rent_plan lrp join lb_union_middle lum on lrp.id = lum.rent_id set lrp.batch_status = 'process' " +
|
||||
" where lum.batch_no =:batchNo and lum.batch_sn =:batchSn")
|
||||
.setParameter("batchNo",map.get("REQ_SN")).setParameter("batchSn", map.get("SN" + k));
|
||||
sqlCa.executeSQL(sqlObject);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
log.error("ShenZhenBuckle process status update exception ",e);
|
||||
if (trans != null) trans.rollback();
|
||||
} finally {
|
||||
log.warn("ShenZhenBuckle process status update -- batch_no:"+map.get("REQ_SN")+" batch_sn:"+map.get("SN" + k));
|
||||
if (trans != null) trans.commit();
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取租金计划ids
|
||||
* @param list
|
||||
* @return
|
||||
* @throws JBOException
|
||||
*/
|
||||
private String getRentIds(List<BizObject> list) throws JBOException {
|
||||
StringBuilder updateIds = new StringBuilder();
|
||||
for (BizObject biz : list) {
|
||||
updateIds.append(biz.getAttribute("id").toString()).append("','");
|
||||
}
|
||||
return updateIds.delete(updateIds.length() - 3, updateIds.length()).toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量代收--报文拼接
|
||||
* @param rent
|
||||
@ -1428,7 +1440,6 @@ public class CollectAuditInfoCache {
|
||||
*/
|
||||
public StringBuffer collectBatch(String req_sn,List<BizObject> list) throws JBOException{
|
||||
//拼接XML报文
|
||||
//String req = System.currentTimeMillis()+"";
|
||||
StringBuffer strbuff = new StringBuffer();
|
||||
strbuff.append("<?xml version=\"1.0\" encoding=\"GBK\"?>");
|
||||
strbuff.append("<GZELINK>");
|
||||
@ -1446,32 +1457,32 @@ public class CollectAuditInfoCache {
|
||||
strbuff.append("</INFO>");
|
||||
strbuff.append("<BODY>");
|
||||
strbuff.append("<TRANS_SUM>");
|
||||
BigDecimal mutly = new BigDecimal("0");
|
||||
BigDecimal mutly = new BigDecimal("0");//卡扣总金额
|
||||
int i = 0;
|
||||
//查询银行限额 itemname<银行名称> itemdescribe<限额设置>
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'bankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
//计算卡扣总金额,卡扣总数量
|
||||
for (BizObject bo : list) {
|
||||
String single = bo.getAttribute("rent").toString();
|
||||
BigDecimal m = new BigDecimal(single);
|
||||
mutly = mutly.add(m);
|
||||
String bank_name = bo.getAttribute("BANK_NAME").toString();
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'bankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
//数据字典中的itemdescribe字段代表银行单笔限
|
||||
double itemdescribe = 0;
|
||||
|
||||
BigDecimal itemdescribe = new BigDecimal("0");
|
||||
boolean flag = false;
|
||||
for (BizObject code : codelist) {
|
||||
String itemnameTmp = code.getAttribute("itemname").toString().trim();
|
||||
double itemdescribeTmp = code.getAttribute("itemdescribe").getDouble();
|
||||
String itemdescribeTmp1 = code.getAttribute("itemdescribe").toString();
|
||||
if (bank_name.indexOf(itemnameTmp) != -1 && itemdescribeTmp1 != null && !"".equals(itemdescribeTmp1)) {
|
||||
itemdescribe = new BigDecimal(itemdescribeTmp).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue();
|
||||
itemdescribe = new BigDecimal(itemdescribeTmp1).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (flag == true && Double.parseDouble(bo.getAttribute("rent").toString()) > itemdescribe) {
|
||||
if (flag == true && m.compareTo(itemdescribe) == 1) {
|
||||
BigDecimal mi = new BigDecimal(bo.getAttribute("rent").toString());
|
||||
int singlerent = mi.multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = new BigDecimal(itemdescribe).multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = itemdescribe.multiply(new BigDecimal(100)).intValue();
|
||||
int k = (int) Math.floor(singlerent/singleitem);
|
||||
int l = (int) Math.ceil(singlerent%singleitem);
|
||||
for (int j = 0; j < k; j++) {
|
||||
@ -1483,8 +1494,8 @@ public class CollectAuditInfoCache {
|
||||
}else{
|
||||
i++;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
String totalSum = String.valueOf(mutly.multiply(new BigDecimal(100)).longValue());
|
||||
String totalItem = String.valueOf(i);
|
||||
Trans_Sum trans_sum = new Trans_Sum();
|
||||
@ -1504,27 +1515,23 @@ public class CollectAuditInfoCache {
|
||||
String account = biz.getAttribute("account").toString();
|
||||
String bank_name = biz.getAttribute("BANK_NAME").toString();
|
||||
String planId = biz.getAttribute("id").toString();
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'bankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
double itemdescribe = 0;
|
||||
BigDecimal itemdescribe = new BigDecimal("0");
|
||||
boolean flag = false;
|
||||
for (BizObject code : codelist) {
|
||||
String itemnameTmp = code.getAttribute("itemname").toString().trim();
|
||||
double itemdescribeTmp = code.getAttribute("itemdescribe").getDouble();
|
||||
String itemdescribeTmp1 = code.getAttribute("itemdescribe").toString();
|
||||
if (bank_name.indexOf(itemnameTmp) != -1 && itemdescribeTmp1 != null && !"".equals(itemdescribeTmp1)) {
|
||||
itemdescribe = new BigDecimal(itemdescribeTmp).setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue();
|
||||
itemdescribe = new BigDecimal(itemdescribeTmp1).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (flag == true && Double.parseDouble(biz.getAttribute("rent").toString()) > itemdescribe) {
|
||||
if (flag == true && m.compareTo(itemdescribe) == 1) {
|
||||
BigDecimal mi = new BigDecimal(biz.getAttribute("rent").toString());
|
||||
int singlerent = mi.multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = new BigDecimal(itemdescribe).multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = itemdescribe.multiply(new BigDecimal(100)).intValue();
|
||||
int k = (int) Math.floor(singlerent/singleitem);
|
||||
int l = (int) Math.ceil(singlerent%singleitem);
|
||||
|
||||
for (int k2 = 1; k2 <= k; k2++) {
|
||||
Trans_Detail trans_detail = new Trans_Detail();
|
||||
String sn = "";
|
||||
@ -1535,48 +1542,7 @@ public class CollectAuditInfoCache {
|
||||
}else{
|
||||
sn = "0000"+ (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", planId).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
//手动的添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
JBOTransaction transj = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,transj);
|
||||
if(k2==1){
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",itemsn0);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
transj.commit();
|
||||
}else{
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
transj.commit();
|
||||
}
|
||||
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,k2,String.valueOf(singleitem));//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1588,8 +1554,7 @@ public class CollectAuditInfoCache {
|
||||
strbuff.append(EntityTransform.toXmlByBatchCollect(trans_detail));
|
||||
}
|
||||
if (l != 0) {
|
||||
String surprent = String.format("%.2f", biz.getAttribute("rent").getDouble() - k*itemdescribe);
|
||||
BigDecimal mj = new BigDecimal(surprent);
|
||||
BigDecimal mj = mi.subtract(itemdescribe.multiply(new BigDecimal(k))).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
String singlerent0 = String.valueOf(mj.multiply(new BigDecimal(100)).longValue());
|
||||
Trans_Detail trans_detail = new Trans_Detail();
|
||||
String sn = "";
|
||||
@ -1600,35 +1565,7 @@ public class CollectAuditInfoCache {
|
||||
}else{
|
||||
sn = "0000"+ (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,trans);
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,trans);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", planId).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
//添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
JBOTransaction transj = JBOFactory.createJBOTransaction();
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
transj.commit();
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,99,singlerent0);//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1650,27 +1587,7 @@ public class CollectAuditInfoCache {
|
||||
}else{
|
||||
sn = "0000"+ (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,trans);
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
//手动的添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,trans);
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",sn);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,1,rent);//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1687,9 +1604,72 @@ public class CollectAuditInfoCache {
|
||||
strbuff.append("</BODY>");
|
||||
strbuff.append("</GZELINK>");
|
||||
collectStyle=null;
|
||||
|
||||
return strbuff;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 更新租金计划表 batch_no batch_sn ,手工卡扣的,添加手工卡扣记录
|
||||
* @param planId 租金计划id
|
||||
* @param req_sn 批次号
|
||||
* @param sn 序号
|
||||
* @param biz
|
||||
* @param k2 k2==1 手工卡扣插入新数据,其余更新手工卡扣表数据
|
||||
* @throws Exception
|
||||
*/
|
||||
private void rentPlanHandle(String planId,String req_sn,String sn,BizObject biz,int k2,String amount) throws JBOException{
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = null;
|
||||
try{
|
||||
trans = JBOFactory.createJBOTransaction();
|
||||
Transaction transaction = Transaction.createTransaction(trans);
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", planId).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
//更新租金批次号 序号
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
//记录中间表 lb_union_middle
|
||||
SqlObject sqlObject = new SqlObject("insert into lb_union_middle (id,batch_no,batch_sn,rent_id,amount,input_time) values (replace(uuid(),'-',''),:batchNo,:batchSn,:rentId,:amount,SYSDATE()) ")
|
||||
.setParameter("batchNo", req_sn).setParameter("batchSn", sn)
|
||||
.setParameter("rentId", planId).setParameter("amount",amount);
|
||||
transaction.executeSQL(sqlObject);
|
||||
//手动卡扣添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,trans);
|
||||
if(k2==1){
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",itemsn0);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
}else{
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
}
|
||||
}
|
||||
trans.commit();
|
||||
}catch (Exception e){
|
||||
if (trans != null) trans.rollback();
|
||||
throw new JBOException(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存存盘、回盘文件
|
||||
@ -1706,13 +1686,9 @@ public class CollectAuditInfoCache {
|
||||
String day = currentDateTime.substring(8,10);
|
||||
//创建文件路径
|
||||
String rootDir = this.fileSavePath;
|
||||
File file = new File(rootDir + File.separator + currentYear
|
||||
+ File.separator + month + File.separator
|
||||
+ day);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
File file = new File(rootDir + File.separator + currentYear + File.separator + month + File.separator + day);
|
||||
//目录不存在则直接创建
|
||||
if(!file.exists())file.mkdirs();
|
||||
//保存存盘文件
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LB_INTFACE_FILE_RECORD.CLASS_NAME);
|
||||
BizObject send = bm.newObject();
|
||||
@ -1725,9 +1701,9 @@ public class CollectAuditInfoCache {
|
||||
send.setAttributeValue("inputorgid", this.inputorgid);
|
||||
send.setAttributeValue("inputtime", currentDateTime);
|
||||
bm.saveObject(send);
|
||||
|
||||
//筛选响应信息
|
||||
Map<String, String> map = getRetAndCode(strResp);
|
||||
//getMsgAndCode(strResp);
|
||||
|
||||
//保存回盘文件
|
||||
BizObject reply = bm.newObject();
|
||||
@ -1789,7 +1765,6 @@ public class CollectAuditInfoCache {
|
||||
public Map<String, String> getRetAndCodeByBatch(String strXML){
|
||||
Map<String, String> map = new HashMap<String, String>();
|
||||
Map<String, String> res = new HashMap<String, String>();
|
||||
System.out.println(1);
|
||||
int iStart = strXML.indexOf("<ERR_MSG>");
|
||||
if (iStart != -1) {
|
||||
int end = strXML.indexOf("</ERR_MSG>");
|
||||
|
||||
@ -1,5 +1,34 @@
|
||||
package com.tenwa.collectaudit.cache;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.amarsoft.app.awe.config.InitCollectConfigTj;
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.lease.app.allinpay.service.impl.AllinpayPaymentDo;
|
||||
import com.tenwa.quartz.DateUtil;
|
||||
import jbo.app.tenwa.calc.LC_COLLECT_MANUAL_INFO;
|
||||
import jbo.app.tenwa.calc.LC_RENT_INCOME;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITCHARGE_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO;
|
||||
import jbo.com.tenwa.lease.comm.LB_BUCKLE_LOG;
|
||||
import jbo.com.tenwa.lease.comm.LB_INTFACE_FILE_RECORD;
|
||||
import jbo.com.tenwa.lease.comm.VI_LC_AUDIT_RENT_PLAN;
|
||||
import jbo.sys.CODE_LIBRARY;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.Scheduler;
|
||||
import org.quartz.SchedulerException;
|
||||
import org.quartz.impl.StdSchedulerFactory;
|
||||
|
||||
import java.io.File;
|
||||
import java.math.BigDecimal;
|
||||
import java.sql.SQLException;
|
||||
@ -10,46 +39,10 @@ import java.util.Map;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.Scheduler;
|
||||
import org.quartz.SchedulerException;
|
||||
import org.quartz.impl.StdSchedulerFactory;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.amarsoft.app.awe.config.InitCollectConfigTj;
|
||||
import com.amarsoft.app.util.StringUtil;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.gnete.security.crypt.Crypt;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.lease.app.allinpay.service.impl.AllinpayPaymentDo;
|
||||
import com.tenwa.quartz.DateUtil;
|
||||
|
||||
import jbo.app.tenwa.calc.LC_COLLECT_MANUAL_INFO;
|
||||
import jbo.app.tenwa.calc.LC_RENT_INCOME;
|
||||
import jbo.app.tenwa.calc.LC_RENT_PLAN;
|
||||
import jbo.app.tenwa.customer.CUSTOMER_ACCOUNT;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITCHARGE_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO;
|
||||
import jbo.com.tenwa.lease.comm.LB_BUCKLE_LOG;
|
||||
import jbo.com.tenwa.lease.comm.LB_CLEAR_FILE_RECORD;
|
||||
import jbo.com.tenwa.lease.comm.LB_INTFACE_FILE_RECORD;
|
||||
import jbo.com.tenwa.lease.comm.VI_LC_AUDIT_RENT_PLAN;
|
||||
import jbo.sys.CODE_LIBRARY;
|
||||
|
||||
public class CollectAuditInfoCacheTj {
|
||||
|
||||
|
||||
private static Log log = LogFactory.getLog(CollectAuditInfoCacheTj.class);
|
||||
|
||||
private String id;
|
||||
private String fileSavePath = "d:/tmp/als/InterFace";
|
||||
private String inputuserid;
|
||||
@ -1006,8 +999,11 @@ public class CollectAuditInfoCacheTj {
|
||||
}
|
||||
|
||||
for (int i = 1; i <= snArray.length; i++) {
|
||||
|
||||
log.warn("TianJin counteroffer batch_no:"+query_sn+" batch_sn:"+snArray[(i-1)]+" rentid:"+bo.getAttribute("id").toString());
|
||||
Map<String, String> map = querySingleBatchCollect(tx, bo, query_sn, snArray[(i-1)]);
|
||||
if(map == null ) {
|
||||
continue;
|
||||
}
|
||||
if (snArray.length == 1) {
|
||||
if (map.containsKey("RET_CODE") && "0000".equals(map.get("RET_CODE"))) {
|
||||
//核销
|
||||
@ -1220,6 +1216,9 @@ public class CollectAuditInfoCacheTj {
|
||||
// queryBatchXML(req_sn, query_sn, sn);
|
||||
//响应报文
|
||||
String strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
if(strResp==null || strResp.isEmpty()) {
|
||||
return null;
|
||||
}
|
||||
Map<String, String> map = getRetAndCode(strResp);
|
||||
//生成存盘、回盘文件
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
@ -1344,39 +1343,45 @@ public class CollectAuditInfoCacheTj {
|
||||
String currentYear = currentDateTime.substring(0,4);
|
||||
String month = currentDateTime.substring(5,7);
|
||||
String day = currentDateTime.substring(8,10);
|
||||
String merchantNumber = InitCollectConfigTj.MERCHANTID;
|
||||
String flag = InitCollectConfigTj.FLAG;
|
||||
String version = InitCollectConfigTj.C_VERSION;
|
||||
String merchantNumber = InitCollectConfigTj.MERCHANTID;//银联商户号
|
||||
String flag = InitCollectConfigTj.FLAG;//银联接口--代收标识
|
||||
String version = InitCollectConfigTj.C_VERSION;//接口版本号
|
||||
String date = currentYear+month+day;//提交日期
|
||||
String batch_title = "";
|
||||
int i = 0,j = 0;
|
||||
//创建文件路径
|
||||
String rootDir = this.fileSavePath;
|
||||
File file = new File(rootDir + File.separator + currentYear
|
||||
+ File.separator + month + File.separator
|
||||
+ day);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
String req_sn = System.currentTimeMillis()+"";//当日批次号
|
||||
batch_title = merchantNumber+"_"+flag+version+date+"_"+req_sn;
|
||||
//请求报文(限额处理)
|
||||
File file = new File(this.fileSavePath + File.separator + currentYear + File.separator + month + File.separator + day);
|
||||
//目录不存在则直接创建
|
||||
if (!file.exists()) file.mkdirs();
|
||||
String req_sn = System.currentTimeMillis()+""; //卡扣批次号 REQ_SN
|
||||
//卡扣文件名称
|
||||
String batch_title = merchantNumber+"_"+flag+version+date+"_"+req_sn;
|
||||
//卡扣报文
|
||||
StringBuffer strbuff = collectBatch(req_sn,list);
|
||||
//响应报文
|
||||
String strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
for (BizObject bo : list) {
|
||||
//生成存盘、回盘文件
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
//接口调用,返回响应报文
|
||||
String strResp = "";
|
||||
try {
|
||||
strResp = cp.CollectAuditPayReq(strbuff,file.getAbsolutePath(), batch_title);
|
||||
}catch (Exception e){
|
||||
JBOTransaction jboTransaction = null;
|
||||
try {
|
||||
String rentIds = getRentIds(list);
|
||||
jboTransaction = JBOFactory.createJBOTransaction();
|
||||
Transaction.createTransaction(jboTransaction).executeSQL("update lc_rent_plan set batch_sn=null where id in ('" + rentIds + "')");
|
||||
jboTransaction.commit();
|
||||
}catch (Exception e1){
|
||||
if (jboTransaction != null) jboTransaction.rollback();
|
||||
e1.printStackTrace();
|
||||
}
|
||||
throw new RuntimeException("天津银联接口调用异常:", e);
|
||||
}
|
||||
//生成存盘、回盘文件(批量卡扣,日志表LB_INTFACE_FILE_RECORD.RELA_ID 存储卡扣批次号)
|
||||
BizObject bo = new BizObject("jbo.app.tenwa.calc.LC_RENT_PLAN");
|
||||
bo.setAttributeValue("id",req_sn);
|
||||
savaFile(tx, strResp,batch_title,bo);
|
||||
//解析银联响应报文
|
||||
Map<String, String> map = getRetAndCodeByBatch(strResp);
|
||||
//包含RET_CODE说明响应没有成功
|
||||
if (map.containsKey("RET_CODE")) {//清空批量代收状态
|
||||
StringBuilder updateIds = new StringBuilder();
|
||||
for (BizObject biz : list) {
|
||||
updateIds.append(biz.getAttribute("id").toString()).append("','");
|
||||
}
|
||||
String updateIdsStr = updateIds.delete(updateIds.length() - 3, updateIds.length()).toString();
|
||||
String updateIdsStr = getRentIds(list);
|
||||
//清空批量处理状态
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
bm.createQuery("update O set O.BATCH_STATUS=null,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=null where O.id in ('" + updateIdsStr + "')")
|
||||
@ -1389,34 +1394,40 @@ public class CollectAuditInfoCacheTj {
|
||||
m++;
|
||||
}
|
||||
}
|
||||
for (int k = 1; k <= m; k++) {
|
||||
JBOTransaction trans = null;
|
||||
try {
|
||||
trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME, trans);
|
||||
BizObject bo0 = bm.createQuery("O.BATCH_NO=:BATCH_NO and O.BATCH_SN like '%" + map.get("SN" + k) + "%'").setParameter("BATCH_NO", map.get("REQ_SN")).getSingleResult(true);
|
||||
if (bo0 != null && "process".equals(bo0.getAttribute("BATCH_STATUS").getString())) {
|
||||
continue;
|
||||
}
|
||||
//响应成功
|
||||
if (map.containsKey("REQ_SN") && map.containsKey("RET_CODE" + k) && "0000".equals(map.get("RET_CODE" + k))) {
|
||||
bo0.setAttributeValue("BATCH_STATUS", "process");
|
||||
} else {//响应异常
|
||||
bo0.setAttributeValue("BATCH_STATUS", null);
|
||||
bo0.setAttributeValue("BATCH_NO", null);
|
||||
bo0.setAttributeValue("BATCH_SN", null);
|
||||
}
|
||||
bm.saveObject(bo0);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
if (trans != null) trans.rollback();
|
||||
} finally {
|
||||
if (trans != null) trans.commit();
|
||||
}
|
||||
}
|
||||
for (int k = 1; k <= m; k++) {
|
||||
JBOTransaction trans = null;
|
||||
try {
|
||||
trans = JBOFactory.createJBOTransaction();
|
||||
Transaction sqlCa = Transaction.createTransaction(trans);
|
||||
SqlObject sqlObject = new SqlObject("update lc_rent_plan lrp join lb_union_middle lum on lrp.id = lum.rent_id set lrp.batch_status = 'process' " +
|
||||
" where lum.batch_no =:batchNo and lum.batch_sn =:batchSn")
|
||||
.setParameter("batchNo", map.get("REQ_SN")).setParameter("batchSn", map.get("SN" + k));
|
||||
sqlCa.executeSQL(sqlObject);
|
||||
} catch (Exception e) {
|
||||
log.error("TianjinBuckle process status update exception ", e);
|
||||
if (trans != null) trans.rollback();
|
||||
} finally {
|
||||
log.warn("TianjinBuckle process status update -- batch_no:" + map.get("REQ_SN") + " batch_sn:" + map.get("SN" + k));
|
||||
if (trans != null) trans.commit();
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租金计划ids
|
||||
* @param list
|
||||
* @return
|
||||
* @throws JBOException
|
||||
*/
|
||||
private String getRentIds(List<BizObject> list) throws JBOException {
|
||||
StringBuilder updateIds = new StringBuilder();
|
||||
for (BizObject biz : list) {
|
||||
updateIds.append(biz.getAttribute("id").toString()).append("','");
|
||||
}
|
||||
return updateIds.delete(updateIds.length() - 3, updateIds.length()).toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量代收--报文拼接
|
||||
@ -1429,7 +1440,6 @@ public class CollectAuditInfoCacheTj {
|
||||
*/
|
||||
public StringBuffer collectBatch(String req_sn,List<BizObject> list) throws JBOException{
|
||||
//拼接XML报文
|
||||
//String req = System.currentTimeMillis()+"";
|
||||
StringBuffer strbuff = new StringBuffer();
|
||||
strbuff.append("<?xml version=\"1.0\" encoding=\"GBK\"?>");
|
||||
strbuff.append("<GZELINK>");
|
||||
@ -1447,17 +1457,17 @@ public class CollectAuditInfoCacheTj {
|
||||
strbuff.append("</INFO>");
|
||||
strbuff.append("<BODY>");
|
||||
strbuff.append("<TRANS_SUM>");
|
||||
//总金额
|
||||
BigDecimal mutly = new BigDecimal("0");
|
||||
//总条数
|
||||
int i = 0;
|
||||
BigDecimal mutly = new BigDecimal("0");//卡扣总金额
|
||||
int i = 0;//总条数
|
||||
//查询银行限额 itemname<银行名称> itemdescribe<限额设置>
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'TjbankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
//计算卡扣总金额,卡扣总数量
|
||||
for (BizObject bo : list) {
|
||||
String single_s = bo.getAttribute("rent").toString();
|
||||
BigDecimal m_s = new BigDecimal(single_s);
|
||||
mutly = mutly.add(m_s);
|
||||
String bank_name = bo.getAttribute("BANK_NAME").toString();
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'TjbankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
//数据字典中的itemdescribe字段代表银行单笔限
|
||||
//数据字典中的itemdescribe字段代表银行单笔限
|
||||
BigDecimal itemdescribe = new BigDecimal("0");
|
||||
boolean flag = false;
|
||||
for (BizObject code : codelist) {
|
||||
@ -1469,9 +1479,8 @@ public class CollectAuditInfoCacheTj {
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (flag == true && m_s.compareTo(itemdescribe)==1) {
|
||||
BigDecimal mi_s = m_s;
|
||||
int singlerent = mi_s.multiply(new BigDecimal(100)).intValue();
|
||||
if (flag == true && m_s.compareTo(itemdescribe) == 1) {
|
||||
int singlerent = m_s.multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = itemdescribe.multiply(new BigDecimal(100)).intValue();
|
||||
int k = singlerent/singleitem;
|
||||
int l = singlerent%singleitem;
|
||||
@ -1484,7 +1493,6 @@ public class CollectAuditInfoCacheTj {
|
||||
}else{
|
||||
i++;
|
||||
}
|
||||
|
||||
}
|
||||
String totalSum = String.valueOf(mutly.multiply(new BigDecimal(100)).longValue());
|
||||
String totalItem = String.valueOf(i);
|
||||
@ -1505,7 +1513,6 @@ public class CollectAuditInfoCacheTj {
|
||||
String account = biz.getAttribute("account").toString();
|
||||
String bank_name = biz.getAttribute("BANK_NAME").toString();
|
||||
String planId = biz.getAttribute("id").toString();
|
||||
List<BizObject> codelist = JBOFactory.getFactory().getBizObjectManager(CODE_LIBRARY.CLASS_NAME).createQuery("O.codeno = 'TjbankType' and O.itemdescribe is not null ").getResultList(false);
|
||||
BigDecimal itemdescribe = new BigDecimal("0");
|
||||
boolean flag = false;
|
||||
for (BizObject code : codelist) {
|
||||
@ -1518,8 +1525,7 @@ public class CollectAuditInfoCacheTj {
|
||||
}
|
||||
}
|
||||
if (flag == true && m.compareTo(itemdescribe)==1) {
|
||||
BigDecimal mi = m;
|
||||
int singlerent = mi.multiply(new BigDecimal(100)).intValue();
|
||||
int singlerent = m.multiply(new BigDecimal(100)).intValue();
|
||||
int singleitem = itemdescribe.multiply(new BigDecimal(100)).intValue();
|
||||
int k = singlerent/singleitem;
|
||||
int l = singlerent%singleitem;
|
||||
@ -1537,48 +1543,7 @@ public class CollectAuditInfoCacheTj {
|
||||
}else{
|
||||
sn = "" + (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,trans);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", biz.getAttribute("id").toString()).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", biz.getAttribute("id").toString()).executeUpdate();
|
||||
//手动的添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
JBOTransaction transj = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,transj);
|
||||
if(k2==1){
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",itemsn0);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
transj.commit();
|
||||
}else{
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
transj.commit();
|
||||
}
|
||||
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,k2,String.valueOf(singleitem));//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1590,7 +1555,7 @@ public class CollectAuditInfoCacheTj {
|
||||
strbuff.append(EntityTransform.toXmlByBatchCollect(trans_detail));
|
||||
}
|
||||
if (l != 0) {
|
||||
BigDecimal mj = mi.subtract(itemdescribe.multiply(new BigDecimal(k))).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
BigDecimal mj = m.subtract(itemdescribe.multiply(new BigDecimal(k))).setScale(2, BigDecimal.ROUND_HALF_UP);
|
||||
String singlerent0 = String.valueOf(mj.multiply(new BigDecimal(100)).longValue());
|
||||
Trans_Detail trans_detail = new Trans_Detail();
|
||||
String sn = "";
|
||||
@ -1605,35 +1570,7 @@ public class CollectAuditInfoCacheTj {
|
||||
}else{
|
||||
sn = "" + (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,trans);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", biz.getAttribute("id").toString()).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", biz.getAttribute("id").toString()).executeUpdate();
|
||||
//手动的添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
JBOTransaction transj = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,transj);
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
transj.commit();
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,99,singlerent0);//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1658,27 +1595,7 @@ public class CollectAuditInfoCacheTj {
|
||||
}else{
|
||||
sn = "" + (++item);
|
||||
}
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = JBOFactory.createJBOTransaction();
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME,trans);
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", sn)
|
||||
.setParameter("id", biz.getAttribute("id").toString()).executeUpdate();
|
||||
//手动的添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,trans);
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",sn);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
}
|
||||
trans.commit();
|
||||
rentPlanHandle(planId,req_sn,sn,biz,1,rent);//追加批量处理状态
|
||||
trans_detail.setSN(sn);
|
||||
trans_detail.setACCOUNT_TYPE("");
|
||||
trans_detail.setACCOUNT_NO(acc_number);
|
||||
@ -1698,7 +1615,70 @@ public class CollectAuditInfoCacheTj {
|
||||
|
||||
return strbuff;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 更新租金计划表 batch_no batch_sn ,手工卡扣的,添加手工卡扣记录
|
||||
* @param planId 租金计划id
|
||||
* @param req_sn 批次号
|
||||
* @param sn 序号
|
||||
* @param biz
|
||||
* @param k2 k2==1 手工卡扣插入新数据,其余更新手工卡扣表数据
|
||||
* @throws Exception
|
||||
*/
|
||||
private void rentPlanHandle(String planId,String req_sn,String sn,BizObject biz,int k2,String amount) throws JBOException{
|
||||
//追加批量处理状态
|
||||
JBOTransaction trans = null;
|
||||
try{
|
||||
trans = JBOFactory.createJBOTransaction();
|
||||
Transaction transaction = Transaction.createTransaction(trans);
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LC_RENT_PLAN.CLASS_NAME);
|
||||
BizObject bo = bm.createQuery("O.id=:id").setParameter("id", planId).getSingleResult(false);
|
||||
String itemsn0 = "";
|
||||
if (bo !=null) {
|
||||
String itemsn = bo.getAttribute("batch_sn").toString();
|
||||
if (itemsn.length() == 0) {
|
||||
itemsn0 += sn;
|
||||
}else{
|
||||
itemsn0 += itemsn+","+sn;
|
||||
}
|
||||
}
|
||||
//更新租金批次号 序号
|
||||
bm.createQuery("update O set O.BATCH_STATUS=:BATCH_STATUS,O.BATCH_NO=:BATCH_NO,O.BATCH_SN=:BATCH_SN where O.id=:id")
|
||||
.setParameter("BATCH_STATUS", "")//处理状态-为空
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
//记录中间表 lb_union_middle
|
||||
SqlObject sqlObject = new SqlObject("insert into lb_union_middle (id,batch_no,batch_sn,rent_id,amount,input_time) values (replace(uuid(),'-',''),:batchNo,:batchSn,:rentId,:amount,SYSDATE()) ")
|
||||
.setParameter("batchNo", req_sn).setParameter("batchSn", sn)
|
||||
.setParameter("rentId", planId).setParameter("amount",amount);
|
||||
transaction.executeSQL(sqlObject);
|
||||
//手动卡扣添加到手动表
|
||||
if("manual".equals(collectStyle)){
|
||||
BizObjectManager bmlcmi = JBOFactory.getFactory().getManager(LC_COLLECT_MANUAL_INFO.CLASS_NAME,trans);
|
||||
if(k2==1){
|
||||
BizObject bolmci = bmlcmi.newObject();
|
||||
bolmci.setAttributeValue("contract_id",biz.getAttribute("contract_id").toString());
|
||||
bolmci.setAttributeValue("plan_id",planId);
|
||||
bolmci.setAttributeValue("BATCH_NO",req_sn);
|
||||
bolmci.setAttributeValue("BATCH_SN",itemsn0);
|
||||
bolmci.setAttributeValue("money",biz.getAttribute("rent").toString());
|
||||
bolmci.setAttributeValue("hire_date",DateUtil.getSystemTimeByFormat("yyyy/MM/dd"));
|
||||
bmlcmi.saveObject(bolmci);
|
||||
}else{
|
||||
bmlcmi.createQuery("update O set O.BATCH_SN=:BATCH_SN where O.plan_id=:id and O.BATCH_NO=:BATCH_NO")
|
||||
.setParameter("BATCH_SN", itemsn0)
|
||||
.setParameter("BATCH_NO", req_sn)
|
||||
.setParameter("id", planId).executeUpdate();
|
||||
}
|
||||
}
|
||||
trans.commit();
|
||||
}catch (Exception e){
|
||||
if (trans != null) trans.rollback();
|
||||
throw new JBOException(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存存盘、回盘文件
|
||||
* @param tx
|
||||
@ -1714,13 +1694,10 @@ public class CollectAuditInfoCacheTj {
|
||||
String day = currentDateTime.substring(8,10);
|
||||
//创建文件路径
|
||||
String rootDir = this.fileSavePath;
|
||||
File file = new File(rootDir + File.separator + currentYear
|
||||
+ File.separator + month + File.separator
|
||||
File file = new File(rootDir + File.separator + currentYear + File.separator + month + File.separator
|
||||
+ day);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
if (!file.exists()) file.mkdirs();//目录不存在则直接创建
|
||||
|
||||
//保存存盘文件
|
||||
BizObjectManager bm = JBOFactory.getFactory().getManager(LB_INTFACE_FILE_RECORD.CLASS_NAME);
|
||||
BizObject send = bm.newObject();
|
||||
@ -1735,7 +1712,6 @@ public class CollectAuditInfoCacheTj {
|
||||
bm.saveObject(send);
|
||||
//筛选响应信息
|
||||
Map<String, String> map = getRetAndCode(strResp);
|
||||
//getMsgAndCode(strResp);
|
||||
|
||||
//保存回盘文件
|
||||
BizObject reply = bm.newObject();
|
||||
@ -1797,7 +1773,6 @@ public class CollectAuditInfoCacheTj {
|
||||
public Map<String, String> getRetAndCodeByBatch(String strXML){
|
||||
Map<String, String> map = new HashMap<String, String>();
|
||||
Map<String, String> res = new HashMap<String, String>();
|
||||
System.out.println(1);
|
||||
int iStart = strXML.indexOf("<ERR_MSG>");
|
||||
if (iStart != -1) {
|
||||
int end = strXML.indexOf("</ERR_MSG>");
|
||||
|
||||
@ -1,18 +1,19 @@
|
||||
package com.tenwa.collectaudit.cache;
|
||||
import java.io.IOException;
|
||||
|
||||
import com.amarsoft.app.awe.config.InitCollectConfig;
|
||||
import com.gnete.security.crypt.Crypt;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import org.apache.commons.httpclient.HttpClient;
|
||||
import org.apache.commons.httpclient.HttpException;
|
||||
import org.apache.commons.httpclient.HttpStatus;
|
||||
import org.apache.commons.httpclient.methods.PostMethod;
|
||||
import org.apache.commons.httpclient.params.HttpMethodParams;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.apache.commons.httpclient.protocol.Protocol;
|
||||
import org.apache.commons.httpclient.protocol.ProtocolSocketFactory;
|
||||
import com.amarsoft.app.awe.config.InitCollectConfig;
|
||||
import com.gnete.security.crypt.Crypt;
|
||||
import com.gnete.security.crypt.CryptException;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
|
||||
/**
|
||||
@ -94,8 +95,7 @@ public class CollectAuditProcess {
|
||||
protected String CollectAuditPayReq(StringBuffer sendXml,String fileSavePath,String fileName) throws CryptException {
|
||||
String strSendData = sendXml.toString();
|
||||
HttpClient httpClient = new HttpClient( );
|
||||
PostMethod postMethod =
|
||||
new PostMethod(InitCollectConfig.C_SERVERURL);
|
||||
PostMethod postMethod = new PostMethod(InitCollectConfig.C_SERVERURL);
|
||||
//设置编码
|
||||
httpClient.getParams().setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET,"GBK");
|
||||
|
||||
@ -105,19 +105,17 @@ public class CollectAuditProcess {
|
||||
Protocol.registerProtocol("https", new Protocol("https", fcty, 443));
|
||||
|
||||
strSendData = this.signMsg(strSendData);
|
||||
log.info(strSendData);
|
||||
System.out.println("·¢Ëͱ¨ÎÄ£º"+strSendData);
|
||||
log.info("·¢Ëͱ¨ÎÄ£º"+strSendData);
|
||||
InterFaceFileCreate.sendDiscFileCreate(strSendData, fileSavePath, fileName);
|
||||
postMethod.setRequestBody(strSendData);
|
||||
try {
|
||||
long start = System.currentTimeMillis();
|
||||
//执行getMethod
|
||||
int statusCode = httpClient.executeMethod(postMethod);
|
||||
System.out.println("cost:"+(System.currentTimeMillis()-start));
|
||||
System.out.println("ShenZhen interface ["+fileName+"] call cost time:" + (System.currentTimeMillis() - start));
|
||||
//失败
|
||||
if (statusCode != HttpStatus.SC_OK) {
|
||||
log.error(
|
||||
"Method failed: " + postMethod.getStatusLine());
|
||||
log.error("Method failed: " + postMethod.getStatusLine());
|
||||
//读取内容
|
||||
byte[] responseBody = postMethod.getResponseBody();
|
||||
//处理内容
|
||||
@ -131,7 +129,6 @@ public class CollectAuditProcess {
|
||||
String strResp = new String(responseBody, "GBK");
|
||||
log.info("服务器返回:" + strResp);
|
||||
InterFaceFileCreate.replyDiscFileCreate(strResp, fileSavePath, fileName);
|
||||
System.out.println("·þÎñÆ÷·µ»Ø:" + strResp);
|
||||
//验签
|
||||
if (this.verifySign(strResp)) {
|
||||
log.info("验签正确,处理服务器返回的报文");
|
||||
|
||||
@ -106,19 +106,17 @@ public class CollectAuditProcessTj {
|
||||
Protocol.registerProtocol("https", new Protocol("https", fcty, 443));
|
||||
|
||||
strSendData = this.signMsg(strSendData);
|
||||
log.info(strSendData);
|
||||
System.out.println("发送报文:"+strSendData);
|
||||
log.info("发送报文:"+strSendData);
|
||||
InterFaceFileCreate.sendDiscFileCreate(strSendData, fileSavePath, fileName);
|
||||
postMethod.setRequestBody(strSendData);
|
||||
try {
|
||||
long start = System.currentTimeMillis();
|
||||
//执行getMethod
|
||||
int statusCode = httpClient.executeMethod(postMethod);
|
||||
System.out.println("cost:"+(System.currentTimeMillis()-start));
|
||||
System.out.println("TianJin interface ["+fileName+"] call cost time:" + (System.currentTimeMillis() - start));
|
||||
//失败
|
||||
if (statusCode != HttpStatus.SC_OK) {
|
||||
log.error(
|
||||
"Method failed: " + postMethod.getStatusLine());
|
||||
log.error("Method failed: " + postMethod.getStatusLine());
|
||||
//读取内容
|
||||
byte[] responseBody = postMethod.getResponseBody();
|
||||
//处理内容
|
||||
@ -132,7 +130,6 @@ public class CollectAuditProcessTj {
|
||||
String strResp = new String(responseBody, "GBK");
|
||||
log.info("服务器返回:" + strResp);
|
||||
InterFaceFileCreate.replyDiscFileCreate(strResp, fileSavePath, fileName);
|
||||
System.out.println("服务器返回:" + strResp);
|
||||
//验签
|
||||
if (this.verifySign(strResp)) {
|
||||
log.info("验签正确,处理服务器返回的报文");
|
||||
|
||||
@ -1,80 +1,58 @@
|
||||
package com.tenwa.collectaudit.cache;
|
||||
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.File;
|
||||
import java.io.FileReader;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.Scanner;
|
||||
|
||||
|
||||
public class InterFaceFileCreate {
|
||||
|
||||
/**
|
||||
* 生成送盘文件
|
||||
* @param sendData
|
||||
* @param fileSavePath
|
||||
* @param fileName
|
||||
*/
|
||||
public static void sendDiscFileCreate(String sendData,String fileSavePath,String fileName) {
|
||||
try {
|
||||
File file = new File(fileSavePath);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
String filePath = file.getAbsolutePath();
|
||||
FileWriter fileWriter = new FileWriter(filePath+"/"+fileName+".txt");
|
||||
|
||||
/**
|
||||
* 生成送盘文件
|
||||
*
|
||||
* @param sendData
|
||||
* @param fileSavePath
|
||||
* @param fileName
|
||||
*/
|
||||
public static void sendDiscFileCreate(String sendData, String fileSavePath, String fileName) {
|
||||
try {
|
||||
File file = new File(fileSavePath);
|
||||
if (!file.exists()) {//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
String filePath = file.getAbsolutePath();
|
||||
FileWriter fileWriter = new FileWriter(filePath + "/" + fileName + ".txt");
|
||||
String ss = sendData;
|
||||
fileWriter.write(ss);
|
||||
fileWriter.write(ss);
|
||||
fileWriter.flush();
|
||||
fileWriter.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
FileReader fileReader = new FileReader(filePath+"/"+fileName+".txt");
|
||||
BufferedReader br = new BufferedReader(fileReader);
|
||||
String s;
|
||||
while ((s = br.readLine()) != null) {
|
||||
System.out.println(s);
|
||||
/**
|
||||
* 生成回盘文件
|
||||
*
|
||||
* @param replyData
|
||||
* @param fileSavePath
|
||||
* @param fileName
|
||||
*/
|
||||
public static void replyDiscFileCreate(String replyData, String fileSavePath, String fileName) {
|
||||
try {
|
||||
File file = new File(fileSavePath);
|
||||
if (!file.exists()) {//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
fileReader.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 生成回盘文件
|
||||
* @param replyData
|
||||
* @param fileSavePath
|
||||
* @param fileName
|
||||
*/
|
||||
public static void replyDiscFileCreate(String replyData,String fileSavePath,String fileName) {
|
||||
try {
|
||||
File file = new File(fileSavePath);
|
||||
System.out.println(file.getAbsolutePath());
|
||||
if(!file.exists()){//目录不存在则直接创建
|
||||
file.mkdirs();
|
||||
}
|
||||
String filePath = file.getAbsolutePath();
|
||||
FileWriter fileWriter = new FileWriter(filePath+"/"+fileName+".rnt");
|
||||
String ss = replyData;
|
||||
fileWriter.write(ss);
|
||||
fileWriter.flush();
|
||||
fileWriter.close();
|
||||
|
||||
FileReader fileReader = new FileReader(filePath+"/"+fileName+".rnt");
|
||||
BufferedReader br = new BufferedReader(fileReader);
|
||||
String s;
|
||||
while ((s = br.readLine()) != null) {
|
||||
System.out.println(s);
|
||||
}
|
||||
fileReader.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
String filePath = file.getAbsolutePath();
|
||||
FileWriter fileWriter = new FileWriter(filePath + "/" + fileName + ".rnt");
|
||||
String ss = replyData;
|
||||
fileWriter.write(ss);
|
||||
fileWriter.flush();
|
||||
fileWriter.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.tenwa.flow.comm.handler;
|
||||
|
||||
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 com.amarsoft.awe.dw.handler.impl.CommonHandler;
|
||||
import jbo.com.tenwa.lease.carbrand.LB_CARDATA_MODEL;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
public class CommercialVehicleHandler extends CommonHandler {
|
||||
@Override
|
||||
protected void beforeUpdate(JBOTransaction tx, BizObject bo) throws Exception {
|
||||
BizObjectManager lcmManage= JBOFactory.getBizObjectManager(LB_CARDATA_MODEL.CLASS_NAME, tx);
|
||||
BizObject lcm = lcmManage.createQuery("brandname=:brandname AND seriesname=:seriesname AND modelname=:modelname ")
|
||||
.setParameter("brandname", bo.getAttribute("BRAND").toString())
|
||||
.setParameter("seriesname", bo.getAttribute("CARS").toString())
|
||||
.setParameter("modelname", bo.getAttribute("MODELS").toString()).getSingleResult(true);
|
||||
if(lcm != null){
|
||||
lcm.setAttributeValue("price" , new BigDecimal( bo.getAttribute("THE_GUIDED").toString()).divide(new BigDecimal("10000")));
|
||||
lcmManage.saveObject(lcm);
|
||||
}
|
||||
super.beforeUpdate(tx, bo);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.tenwa.flow.comm.handler;
|
||||
|
||||
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 com.amarsoft.awe.dw.handler.impl.CommonHandler;
|
||||
import jbo.app.tenwa.customer.LB_CARDATA_COMMERCIAL_MODEL;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
public class PassengerCarHandler extends CommonHandler {
|
||||
@Override
|
||||
protected void beforeUpdate(JBOTransaction tx, BizObject bo) throws Exception {
|
||||
BizObjectManager lccmManage= JBOFactory.getBizObjectManager(LB_CARDATA_COMMERCIAL_MODEL.CLASS_NAME, tx);
|
||||
BizObject lccm = lccmManage.createQuery(" brand_name=:brand_name AND series_name=:series_name AND model_name=:model_name ")
|
||||
.setParameter("brand_name", bo.getAttribute("BRAND").toString())
|
||||
.setParameter("series_name", bo.getAttribute("CARS").toString())
|
||||
.setParameter("model_name", bo.getAttribute("MODELS").toString()).getSingleResult(true);
|
||||
if(lccm != null){
|
||||
lccm.setAttributeValue("price" , new BigDecimal( bo.getAttribute("THE_GUIDED").toString()).divide(new BigDecimal("10000")));
|
||||
lccmManage.saveObject(lccm);
|
||||
}
|
||||
super.beforeUpdate(tx, bo);
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,18 @@
|
||||
package com.tenwa.flow.fund.fundcollection;
|
||||
|
||||
import com.amarsoft.are.jbo.*;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.bussinessapprove.BussinessStatusAndDetailAction;
|
||||
import com.tenwa.util.MultiSubjectUtil;
|
||||
import jbo.app.tenwa.calc.*;
|
||||
import jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO;
|
||||
import net.sf.json.JSONArray;
|
||||
import net.sf.json.JSONObject;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.sql.SQLException;
|
||||
import java.util.HashMap;
|
||||
@ -7,31 +20,6 @@ import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.amarsoft.app.base.businessobject.BusinessObject;
|
||||
import net.sf.json.*;
|
||||
import jbo.app.tenwa.calc.LB_PAYMENTRETURN_LOG;
|
||||
import jbo.app.tenwa.calc.LC_EBANK_PROCESS;
|
||||
import jbo.app.tenwa.calc.LC_EBANK_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_FUND_INCOME;
|
||||
import jbo.app.tenwa.calc.LC_FUND_INCOME_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.VI_LC_FUND_PLAN;
|
||||
import jbo.com.tenwa.entity.comm.own.OWN_ACCOUNT;
|
||||
import jbo.com.tenwa.lease.comm.LB_CONTRACT_INFO;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.bussinessapprove.BussinessStatusAndDetailAction;
|
||||
import com.tenwa.reckon.util.Conn;
|
||||
|
||||
public class FundIncomeMethod {
|
||||
|
||||
private String planIDs;
|
||||
@ -453,12 +441,6 @@ public String getContactId(JBOTransaction tx) throws SQLException, Exception{
|
||||
}
|
||||
public String createActualPayment(JBOTransaction tx) throws JBOException{
|
||||
try{
|
||||
//获取深圳本方账户
|
||||
BizObject boOAS = JBOFactory.getBizObjectManager(OWN_ACCOUNT.CLASS_NAME,tx)
|
||||
.createQuery("account_purpose='default' and state_='0010' and FbSdk='Y' and own_id='807001002001' ").getSingleResult(false);
|
||||
//获取天津本方账户
|
||||
BizObject boOAT = JBOFactory.getBizObjectManager(OWN_ACCOUNT.CLASS_NAME,tx)
|
||||
.createQuery("account_purpose='default' and state_='0010' and FbSdk='Y' and own_id='807001003' ").getSingleResult(false);
|
||||
for(String contractId : contractIds.split("@")){
|
||||
@SuppressWarnings("unchecked")
|
||||
List<BizObject> bos = JBOFactory.getBizObjectManager(LC_FUND_INCOME.CLASS_NAME)
|
||||
@ -479,17 +461,6 @@ public String getContactId(JBOTransaction tx) throws SQLException, Exception{
|
||||
otherProperty.put("FlowUnid", flowunid);
|
||||
otherProperty.put("IS_FLOWING", "0");
|
||||
otherProperty.put("ACCOUNTING_DATE", StringFunction.getTodayNow().split(" ")[0]);
|
||||
if("aa740e4111c111eaaa0000163e0e11e6".equals(lci.getAttribute("SUBJECTID").toString())){
|
||||
otherProperty.put("BANK", boOAS.getAttribute("ACC_BANK").getString());
|
||||
otherProperty.put("ACCOUNT", boOAS.getAttribute("ACC_NAME").getString());
|
||||
otherProperty.put("ACC_NUMBER", boOAS.getAttribute("ACC_NUMBER").getString());
|
||||
}else if("d989246c11c111eaaa0000163e0e11e6".equals(lci.getAttribute("SUBJECTID").toString())){
|
||||
otherProperty.put("BANK", boOAT.getAttribute("ACC_BANK").getString());
|
||||
otherProperty.put("ACCOUNT", boOAT.getAttribute("ACC_NAME").getString());
|
||||
otherProperty.put("ACC_NUMBER", boOAT.getAttribute("ACC_NUMBER").getString());
|
||||
}else{
|
||||
throw new RuntimeException("未查询到对应的主体信息!");
|
||||
}
|
||||
otherProperty.put("INCOME_ID", bo.getAttribute("ID").getString());
|
||||
otherProperty.put(LC_FUND_INCOME.EBANK_STATUS, "03");
|
||||
if("0020".equals(payType)||"0030".equals(payType)){
|
||||
@ -634,6 +605,24 @@ public String getContactId(JBOTransaction tx) throws SQLException, Exception{
|
||||
}else{
|
||||
meaage="已生成的本次付款明细中和已选合同主体不符!!!";
|
||||
}
|
||||
//付款基本信息默认本方账户
|
||||
if ("true".equals(meaage)) {
|
||||
String subjectName = "";
|
||||
if (MultiSubjectUtil.SZSUBJECTID.equals(subjectuid)) {
|
||||
subjectName = MultiSubjectUtil.SZSUBJECTNAME;
|
||||
} else if (MultiSubjectUtil.TJSUBJECTID.equals(subjectuid)) {
|
||||
subjectName = MultiSubjectUtil.TJSUBJECTNAME;
|
||||
}
|
||||
BizObjectManager bm_own = JBOFactory.getBizObjectManager("jbo.com.tenwa.entity.comm.own.OWN_ACCOUNT", tx);
|
||||
BizObject bo_own = bm_own.createQuery("acc_name =:accName and account_purpose = 'default' and account_type = 'out_account' and state_ = '0010'")
|
||||
.setParameter("accName", subjectName).getSingleResult(false);
|
||||
JBOFactory.createBizObjectQuery("jbo.app.tenwa.calc.LB_ACTUAL_PAYMENT_INFO_TEMP","update o set bank=:bank,account=:account,acc_number=:acc_number where flowunid = :flowunid ")
|
||||
.setParameter("bank",bo_own.getAttribute("acc_bank").getString())
|
||||
.setParameter("account",bo_own.getAttribute("acc_name").getString())
|
||||
.setParameter("acc_number",bo_own.getAttribute("acc_number").getString())
|
||||
.setParameter("flowunid",flowunid)
|
||||
.executeUpdate();
|
||||
}
|
||||
}else{
|
||||
meaage="所选合同涉及多个主体,请检查!";
|
||||
}
|
||||
|
||||
@ -1,15 +1,6 @@
|
||||
package com.tenwa.lease.app.quartzmession;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import jbo.com.tenwa.lease.comm.VI_LC_AUDIT_RENT_PLAN;
|
||||
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.awe.Configure;
|
||||
@ -21,65 +12,80 @@ import com.tenwa.collectaudit.cache.CollectAuditInfoCache;
|
||||
import com.tenwa.collectaudit.cache.CollectAuditInfoCacheTj;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.lease.app.allinpay.service.impl.AllinpayPaymentQueryRun;
|
||||
import jbo.com.tenwa.lease.comm.VI_LC_AUDIT_RENT_PLAN;
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
public class AutoRefresh implements Job{
|
||||
import java.util.List;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
import java.util.concurrent.locks.ReentrantLock;
|
||||
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
CollectAuditInfoCache ca = new CollectAuditInfoCache();
|
||||
JBOTransaction tx = null;
|
||||
String plan_date = DateAssistant.getToday();
|
||||
Object userId = arg0.getTrigger().getJobDataMap().get("CurUserId");
|
||||
String curUserId = userId == null? "system" : userId.toString();
|
||||
try {
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Transaction Sqlca = Transaction.createTransaction(tx);
|
||||
String sSql = "SELECT STATUS FROM lb_card_buckle_status WHERE STATUS='Y' ";
|
||||
SqlObject asql = new SqlObject(sSql);
|
||||
ASResultSet rs = Sqlca.getASResultSet(asql);
|
||||
if(rs.next()) {
|
||||
return ;
|
||||
}
|
||||
List<BizObject> bos = JBOFactory.getBizObjectManager(VI_LC_AUDIT_RENT_PLAN.CLASS_NAME, tx).createQuery("O.COLLECT_STATUS IN ('未收款', '部分收款','代偿') and O.SUBJECTID='aa740e4111c111eaaa0000163e0e11e6' and O.collect_type='YLcollect' and O.BATCH_STATUS='process' and O.PLAN_DATE <= '"+plan_date+"'").getResultList(true);
|
||||
StringBuffer ids = new StringBuffer();
|
||||
if(bos!=null && bos.size()>0){
|
||||
for (BizObject bo : bos) {
|
||||
ids.append(bo.getAttribute("id").getString()+"@");
|
||||
}
|
||||
ca.setId(ids.toString().substring(0, ids.toString().length()-1));
|
||||
Configure CurConfig = Configure.getInstance();
|
||||
ca.setFileSavePath(CurConfig.getConfigure("InterfaceFileSavePath"));
|
||||
ca.setInputuserid("system");
|
||||
ca.setInputorgid("system");
|
||||
ca.queryBatchCollectStatus(tx);
|
||||
}
|
||||
//天津自动回盘
|
||||
CollectAuditInfoCacheTj caTj = new CollectAuditInfoCacheTj();
|
||||
List<BizObject> bosTj = JBOFactory.getBizObjectManager(VI_LC_AUDIT_RENT_PLAN.CLASS_NAME, tx).createQuery("O.COLLECT_STATUS IN ('未收款', '部分收款','代偿') and O.SUBJECTID='d989246c11c111eaaa0000163e0e11e6' and O.collect_type='YLcollect' and O.BATCH_STATUS='process' and O.PLAN_DATE <= '"+plan_date+"'").getResultList(true);
|
||||
StringBuffer idsTj = new StringBuffer();
|
||||
if(bosTj!=null && bosTj.size()>0){
|
||||
for (BizObject bo : bosTj) {
|
||||
idsTj.append(bo.getAttribute("id").getString()+"@");
|
||||
}
|
||||
caTj.setId(idsTj.toString().substring(0, idsTj.toString().length()-1));
|
||||
Configure CurConfig = Configure.getInstance();
|
||||
caTj.setFileSavePath(CurConfig.getConfigure("InterfaceFileSavePath"));
|
||||
caTj.setInputuserid("system");
|
||||
caTj.setInputorgid("system");
|
||||
caTj.queryBatchCollectStatus(tx);
|
||||
}
|
||||
QuartzUtil.insertLog(plan_date,"com.tenwa.lease.app.quartzmession.AutoRefresh", "success", "成功",curUserId);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
QuartzUtil.insertLog(plan_date,"com.tenwa.lease.app.quartzmession.AutoRefresh", "error", "失败",curUserId);
|
||||
}finally{
|
||||
try {
|
||||
tx.commit();
|
||||
} catch (JBOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
AllinpayPaymentQueryRun run = new AllinpayPaymentQueryRun();
|
||||
new Thread(run).start();
|
||||
}
|
||||
public class AutoRefresh implements Job {
|
||||
|
||||
private static final Lock lock = new ReentrantLock();
|
||||
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
String plan_date = DateAssistant.getToday();
|
||||
Object userId = arg0.getTrigger().getJobDataMap().get("CurUserId");
|
||||
String curUserId = userId == null ? "system" : userId.toString();
|
||||
boolean lockHoldStatus = lock.tryLock();
|
||||
try {
|
||||
if (lockHoldStatus) {
|
||||
CollectAuditInfoCache ca = new CollectAuditInfoCache();
|
||||
JBOTransaction tx = null;
|
||||
try {
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Transaction Sqlca = Transaction.createTransaction(tx);
|
||||
String sSql = "SELECT STATUS FROM lb_card_buckle_status WHERE STATUS='Y' ";
|
||||
SqlObject asql = new SqlObject(sSql);
|
||||
ASResultSet rs = Sqlca.getASResultSet(asql);
|
||||
if (rs.next()) {
|
||||
return;
|
||||
}
|
||||
List<BizObject> bos = JBOFactory.getBizObjectManager(VI_LC_AUDIT_RENT_PLAN.CLASS_NAME, tx).createQuery("O.COLLECT_STATUS IN ('未收款', '部分收款','代偿') and O.SUBJECTID='aa740e4111c111eaaa0000163e0e11e6' and O.collect_type='YLcollect' and O.BATCH_STATUS='process' and O.PLAN_DATE <= '" + plan_date + "'").getResultList(true);
|
||||
StringBuilder ids = new StringBuilder();
|
||||
if (bos != null && bos.size() > 0) {
|
||||
for (BizObject bo : bos) {
|
||||
ids.append(bo.getAttribute("id").getString()).append("@");
|
||||
}
|
||||
ca.setId(ids.toString().substring(0, ids.toString().length() - 1));
|
||||
ca.setFileSavePath(Configure.getInstance().getConfigure("InterfaceFileSavePath"));
|
||||
ca.setInputuserid("system");
|
||||
ca.setInputorgid("system");
|
||||
ca.queryBatchCollectStatus(tx);
|
||||
}
|
||||
//天津自动回盘
|
||||
CollectAuditInfoCacheTj caTj = new CollectAuditInfoCacheTj();
|
||||
List<BizObject> bosTj = JBOFactory.getBizObjectManager(VI_LC_AUDIT_RENT_PLAN.CLASS_NAME, tx).createQuery("O.COLLECT_STATUS IN ('未收款', '部分收款','代偿') and O.SUBJECTID='d989246c11c111eaaa0000163e0e11e6' and O.collect_type='YLcollect' and O.BATCH_STATUS='process' and O.PLAN_DATE <= '" + plan_date + "'").getResultList(true);
|
||||
StringBuilder idsTj = new StringBuilder();
|
||||
if (bosTj != null && bosTj.size() > 0) {
|
||||
for (BizObject bo : bosTj) {
|
||||
idsTj.append(bo.getAttribute("id").getString()).append("@");
|
||||
}
|
||||
caTj.setId(idsTj.toString().substring(0, idsTj.toString().length() - 1));
|
||||
caTj.setFileSavePath(Configure.getInstance().getConfigure("InterfaceFileSavePath"));
|
||||
caTj.setInputuserid("system");
|
||||
caTj.setInputorgid("system");
|
||||
caTj.queryBatchCollectStatus(tx);
|
||||
}
|
||||
tx.commit();
|
||||
//通联卡扣回盘
|
||||
new AllinpayPaymentQueryRun().allinpayPaymentQuerySt();
|
||||
QuartzUtil.insertLog(plan_date, "com.tenwa.lease.app.quartzmession.AutoRefresh", "success", "成功", curUserId);
|
||||
} catch (Exception e) {
|
||||
if (tx != null) tx.rollback();
|
||||
e.printStackTrace();
|
||||
QuartzUtil.insertLog(plan_date, "com.tenwa.lease.app.quartzmession.AutoRefresh", "error", "失败", curUserId);
|
||||
}
|
||||
} else {
|
||||
QuartzUtil.insertLog(plan_date, "com.tenwa.lease.app.quartzmession.AutoRefresh", "lockerror", "获取锁失败", curUserId);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
if (lockHoldStatus) lock.unlock();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
174
src_tenwa/com/tenwa/lease/app/quartzmession/MarginDeduction.java
Normal file
174
src_tenwa/com/tenwa/lease/app/quartzmession/MarginDeduction.java
Normal file
@ -0,0 +1,174 @@
|
||||
package com.tenwa.lease.app.quartzmession;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
import com.base.util.DateUtil;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
|
||||
/**保证金抵扣租金*/
|
||||
public class MarginDeduction implements Job{
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException{
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
|
||||
String startime = StringFunction.getTodayNow();
|
||||
Object userId = arg0.getTrigger().getJobDataMap().get("CurUserId");
|
||||
JBOTransaction tx = null;
|
||||
Transaction Sqlca = null;
|
||||
try {
|
||||
tx = JBOFactory.createJBOTransaction();
|
||||
Sqlca = Transaction.createTransaction(tx);
|
||||
BizObjectManager lrpBm = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_RENT_PLAN",Sqlca);
|
||||
BizObjectManager lriBm = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_RENT_INCOME",Sqlca);
|
||||
BizObjectManager lfiBm = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_FUND_INCOME",Sqlca);
|
||||
BizObjectManager lfpBm = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.LC_FUND_PLAN",Sqlca);
|
||||
BizObjectManager vlrpBm = JBOFactory.getBizObjectManager("jbo.app.tenwa.calc.VI_LC_RENT_PLAN",Sqlca);
|
||||
List<Map<String,String>> listData = DataOperatorUtil.getDataBySql("select cast(lfp.PLAN_MONEY as decimal(18,2))-cast(ifnull(lfit.fact_money,'0') as decimal(18,2))-cast(IfNULL(lfi.fact_money,'0') as decimal(18,2)) as fact_money,lci.id as contractId " +
|
||||
"from lc_fund_plan lfp left join lb_contract_info lci on lci.id=lfp.CONTRACT_ID " +
|
||||
" left join (select sum(fact_money) fact_money,PAYMENT_NUMBER from lc_fund_income_temp where FEE_TYPE='feetype16' and is_flowing='0' and ROLL_BACK='0' group by PAYMENT_NUMBER) lfit on lfp.PAYMENT_NUMBER=lfit.PAYMENT_NUMBER " +
|
||||
" LEFT JOIN (SELECT SUM(fact_money) fact_money,PAYMENT_NUMBER FROM lc_fund_income WHERE FEE_TYPE='feetype16' AND ROLL_BACK='0' group by PAYMENT_NUMBER) lfi on lfp.PAYMENT_NUMBER=lfi.PAYMENT_NUMBER " +
|
||||
"where lci.BUSINESSTYPE='1' and lci.CONTRACT_STATUS='31' and lfp.FEE_TYPE='feetype16' and lfp.SETTLE_METHOD is not null ");
|
||||
if(listData!=null && listData.size() > 0 ){
|
||||
for (int i = 0; i < listData.size(); i++) {
|
||||
String contractId = listData.get(i).get("contractId");
|
||||
BigDecimal fact_money = new BigDecimal( listData.get(i).get("fact_money").toString() );
|
||||
BigDecimal money = new BigDecimal( listData.get(i).get("fact_money").toString() );
|
||||
BizObject vlrpBo = null ;
|
||||
List<BizObject> vlrpBoList = vlrpBm.createQuery("rent_over>0 and contract_id =:contract_id order by plan_list desc ").setParameter("contract_id",contractId).getResultList(false);
|
||||
if( vlrpBoList!=null && vlrpBoList.size() > 0){
|
||||
BigDecimal rent = BigDecimal.ZERO ;
|
||||
int j = 0 ;
|
||||
for ( ; j < vlrpBoList.size() ; j++ ) {
|
||||
BigDecimal plistRent = new BigDecimal( vlrpBoList.get(j).getAttribute("rent_over").toString() );
|
||||
rent = rent.add( plistRent ) ;
|
||||
if(rent.compareTo(fact_money) > -1 || (vlrpBoList.size()-1) == j ){
|
||||
vlrpBo = vlrpBoList.get(j);
|
||||
break;
|
||||
}
|
||||
money = money.subtract(plistRent);
|
||||
}
|
||||
if(j == vlrpBoList.size()-1 ){//循环的数据等于集合的值,说明抵扣前的金额已经还完
|
||||
String plan_date = vlrpBo.getAttribute("plan_date").toString();
|
||||
String nowDate = DateUtil.getSystemTimeByFormat("yyyy/MM/dd");
|
||||
if(nowDate.compareTo(plan_date)>-1){
|
||||
BizObject lriBo = lriBm.newObject();
|
||||
BigDecimal interestOver = new BigDecimal(vlrpBo.getAttribute("interest_over").toString());
|
||||
if(interestOver.compareTo(money)>-1) {
|
||||
lriBo.setAttributeValue("INTEREST",money);
|
||||
money=BigDecimal.ZERO;
|
||||
}else {
|
||||
lriBo.setAttributeValue("INTEREST",interestOver);
|
||||
money=money.subtract(interestOver);
|
||||
}
|
||||
|
||||
BigDecimal corpusOver = new BigDecimal(vlrpBo.getAttribute("corpus_over").toString());
|
||||
if(corpusOver.compareTo(money)>-1) {
|
||||
lriBo.setAttributeValue("CORPUS",money);
|
||||
money=BigDecimal.ZERO;
|
||||
}else {
|
||||
lriBo.setAttributeValue("CORPUS",corpusOver);
|
||||
money=money.subtract(corpusOver);
|
||||
}
|
||||
BizObject lrp = lrpBm.createQuery(" id=:id ").setParameter("id",vlrpBo.getAttribute("ID").toString()).getSingleResult(true);
|
||||
BigDecimal drent = new BigDecimal(lriBo.getAttribute("CORPUS").toString()).add( new BigDecimal( lriBo.getAttribute("INTEREST").toString() ) );
|
||||
BigDecimal rentOver = new BigDecimal(vlrpBo.getAttribute("rent_over").toString());
|
||||
|
||||
String fundIncomeId = UUID.randomUUID().toString().replaceAll("-","");
|
||||
lriBo.setAttributeValue("PROJECT_ID",vlrpBo.getAttribute("PROJECT_ID"));
|
||||
lriBo.setAttributeValue("PROJECT_PLAN_NUMBER",lrp.getAttribute("PROJECT_PLAN_NUMBER"));
|
||||
lriBo.setAttributeValue("CONTRACT_ID",vlrpBo.getAttribute("CONTRACT_ID"));
|
||||
lriBo.setAttributeValue("CONTRACT_PLAN_NUMBER",lrp.getAttribute("CONTRACT_PLAN_NUMBER"));
|
||||
lriBo.setAttributeValue("PAYMENT_NUMBER",vlrpBo.getAttribute("PAYMENT_NUMBER"));
|
||||
lriBo.setAttributeValue("PLAN_ID",vlrpBo.getAttribute("ID"));
|
||||
lriBo.setAttributeValue("PLAN_LIST",vlrpBo.getAttribute("PLAN_LIST"));
|
||||
double hireList = Sqlca.getDouble("select max(HIRE_LIST) from lc_rent_income where PAYMENT_NUMBER='"+vlrpBo.getAttribute("PAYMENT_NUMBER")+"' and PLAN_LIST='"+vlrpBo.getAttribute("PLAN_LIST")+"'");
|
||||
lriBo.setAttributeValue("HIRE_LIST",hireList+1);
|
||||
lriBo.setAttributeValue("HIRE_DATE",vlrpBo.getAttribute("PLAN_DATE"));
|
||||
lriBo.setAttributeValue("RENT",drent);
|
||||
lriBo.setAttributeValue("PENALTY","0.00");
|
||||
lriBo.setAttributeValue("CORPUS_ADJUST","0.00");
|
||||
lriBo.setAttributeValue("INTEREST_ADJUST","0.00");
|
||||
lriBo.setAttributeValue("PENALTY_ADJUST","0.00");
|
||||
lriBo.setAttributeValue("SETTLE_METHOD","settlemethod7");
|
||||
lriBo.setAttributeValue("DEDUCTION_ID",fundIncomeId);
|
||||
lriBo.setAttributeValue("ACCOUNTING_DATE",vlrpBo.getAttribute("PLAN_DATE"));
|
||||
lriBo.setAttributeValue("MEMO","保证金抵扣定时任务");
|
||||
lriBo.setAttributeValue("ROLL_BACK","0");
|
||||
lriBo.setAttributeValue("INPUTTIME",sdf.format(new Date()));
|
||||
lriBm.saveObject(lriBo);
|
||||
|
||||
BizObject lfpBo = lfpBm.createQuery("PAYMENT_NUMBER='"+vlrpBo.getAttribute("PAYMENT_NUMBER")+"'").getSingleResult(false);
|
||||
BizObject lfiBo = lfiBm.newObject();
|
||||
lfiBo.setAttributeValue("ID", fundIncomeId);
|
||||
//lfiBo.setAttributeValue("RELATIVE_ID", lfpBo.getAttribute("RELATIVE_ID"));
|
||||
lfiBo.setAttributeValue("PROJECT_ID", lfpBo.getAttribute("PROJECT_ID"));
|
||||
lfiBo.setAttributeValue("PROJECT_PLAN_NUMBER", lfpBo.getAttribute("PROJECT_PLAN_NUMBER"));
|
||||
lfiBo.setAttributeValue("CONTRACT_ID", lfpBo.getAttribute("CONTRACT_ID"));
|
||||
lfiBo.setAttributeValue("CONTRACT_PLAN_NUMBER", lfpBo.getAttribute("CONTRACT_PLAN_NUMBER"));
|
||||
lfiBo.setAttributeValue("PAYMENT_NUMBER", lfpBo.getAttribute("PAYMENT_NUMBER"));
|
||||
lfiBo.setAttributeValue("PLAN_ID", vlrpBo.getAttribute("ID"));
|
||||
lfiBo.setAttributeValue("PLAN_LIST", lfpBo.getAttribute("PLAN_LIST"));
|
||||
lfiBo.setAttributeValue("PAY_TYPE", lfpBo.getAttribute("PAY_TYPE"));
|
||||
lfiBo.setAttributeValue("FEE_TYPE", lfpBo.getAttribute("FEE_TYPE"));
|
||||
lfiBo.setAttributeValue("SETTLE_METHOD","settlemethod7");
|
||||
double chargeList = Sqlca.getDouble("select max(CHARGE_LIST) from lc_fund_income where PAYMENT_NUMBER='"+lfpBo.getAttribute("PAYMENT_NUMBER")+"' and PLAN_LIST='"+lfpBo.getAttribute("PLAN_LIST")+"'");
|
||||
lfiBo.setAttributeValue("CHARGE_LIST",chargeList+1);
|
||||
lfiBo.setAttributeValue("FACT_DATE",vlrpBo.getAttribute("PLAN_DATE"));
|
||||
lfiBo.setAttributeValue("FACT_MONEY",drent);
|
||||
lfiBo.setAttributeValue("FEE_ADJUST","0.00");
|
||||
lfiBo.setAttributeValue("ACCOUNTING_DATE",vlrpBo.getAttribute("PLAN_DATE"));
|
||||
lfiBo.setAttributeValue("APPLYPAY_DATE",vlrpBo.getAttribute("PLAN_DATE"));
|
||||
lfiBo.setAttributeValue("MEMO","保证金抵扣定时任务");
|
||||
lfiBo.setAttributeValue("ROLL_BACK","0");
|
||||
lfiBo.setAttributeValue("INPUTTIME",sdf.format(new Date()));
|
||||
lfiBm.saveObject(lfiBo);
|
||||
|
||||
if( drent.compareTo(rentOver) == 0 ){//如果租金等于应该租金,修改租金计划表中的状态
|
||||
lrp.setAttributeValue("COLLECT_STATUS","保证金抵扣");
|
||||
lrp.setAttributeValue("COLLECT_MSG","保证金抵扣");
|
||||
lrpBm.saveObject(lrp);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
QuartzUtil.insertLog(startime,"com.tenwa.lease.app.quartzmession.MarginDeduction", "success", "成功", userId == null? "system" : userId.toString());
|
||||
} catch (Exception e1) {
|
||||
try {
|
||||
Sqlca.rollback();
|
||||
tx.rollback();
|
||||
} catch (JBOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
e1.printStackTrace();
|
||||
QuartzUtil.insertLog(startime,"com.tenwa.lease.app.quartzmession.MarginDeduction", "error", "失败", userId == null? "system" : userId.toString());
|
||||
|
||||
}finally {
|
||||
try {
|
||||
Sqlca.commit();
|
||||
tx.commit();
|
||||
} catch (JBOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user