Merge branch 'develop' of http://git2.tenwa.com.cn/ApzlDev/apzl_leasing.git into zhuhuichen
This commit is contained in:
commit
a3dde487fd
@ -13,9 +13,11 @@
|
||||
String sTempletNo = "DDepositReturn_TempInfo";//--Ä£°åºÅ--
|
||||
ASObjectModel doTemp = new ASObjectModel(sTempletNo);
|
||||
/* doTemp.setColTips("", "²âÊÔ"); */
|
||||
doTemp.setHtmlEvent("CAUTION_MONEY", "onblur", "selectBalance");
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
|
||||
dwTemp.Style = "2";//freeform
|
||||
//dwTemp.ReadOnly = "-2";//Ö»¶Áģʽ
|
||||
|
||||
dwTemp.genHTMLObjectWindow(CurPage.getParameter("ID"));
|
||||
|
||||
String sButtons[][] = {
|
||||
@ -26,7 +28,7 @@
|
||||
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
|
||||
<script type="text/javascript">
|
||||
var sFlowUnid = "<%=sFlowUnid%>";
|
||||
setItemValue(0,0,"MONEY_TYPE","ÍË¿î");
|
||||
setItemValue(0,0,"MONEY_TYPE","±£Ö¤½ðÍË¿î");
|
||||
setItemValue(0,0,"REFUND_PERSON","<%=ProjectName%>");
|
||||
setItemValue(0,0,"InputUserID","<%=CurUser.getUserName()%>");
|
||||
setItemValue(0,0,"InputOrgID","<%=CurUser.getOrgName()%>");
|
||||
@ -42,5 +44,9 @@
|
||||
function returnList(){
|
||||
AsControl.OpenView("/DealerDeposit/DDepositReturn_TempList.jsp", "FlowUnid="+sFlowUnid,"_self","");
|
||||
}
|
||||
function selectBalance(){
|
||||
AsControl.RunJavaMethod(ClassName,MethodName, Args);
|
||||
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -1,47 +0,0 @@
|
||||
<%@ page contentType="text/html; charset=GBK"%>
|
||||
<%@ include file="/Frame/resources/include/include_begin_info.jspf"%><%
|
||||
/*
|
||||
Author: undefined 2018-05-27
|
||||
Content: 示例详情页面
|
||||
History Log:
|
||||
*/
|
||||
String sFlowUnid = CurPage.getParameter("FlowUnid");
|
||||
String sPrevUrl = CurPage.getParameter("ID");
|
||||
//String ProjectName = CurPage.getParameter("ProjectName");
|
||||
/* if(sPrevUrl == null) sPrevUrl = "/DealerDeposit/DMarginChargeInfo_TempList.jsp"; */
|
||||
BizObject flow=JBOFactory.createBizObjectQuery("jbo.com.tenwa.entity.comm.flow.FLOW_BUSSINESS_OBJECT","flow_unid=:flowunid").setParameter("flowunid", sFlowUnid).getSingleResult(false);
|
||||
String DISTRIBUTOR_NO=flow.getAttribute("Flow_Key").getString();
|
||||
String sTempletNo = "DMarginChargeInfo_Temp";//--模板号--
|
||||
ASObjectModel doTemp = new ASObjectModel(sTempletNo);
|
||||
/* doTemp.setColTips("", "测试"); */
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
|
||||
dwTemp.Style = "2";//freeform
|
||||
//dwTemp.ReadOnly = "-2";//只读模式
|
||||
dwTemp.genHTMLObjectWindow(CurPage.getParameter("ID"));
|
||||
|
||||
String sButtons[][] = {
|
||||
{"true","All","Button","保存","保存所有修改","save()","","","",""},
|
||||
{String.valueOf(!com.amarsoft.are.lang.StringX.isSpace(sPrevUrl)),"All","Button","返回","返回列表","returnList()","","","",""}
|
||||
};
|
||||
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
|
||||
<script type="text/javascript">
|
||||
var sFlowUnid = "<%=sFlowUnid%>";
|
||||
setItemValue(0,0,"MONEY_TYPE","收款");
|
||||
setItemValue(0,0,"DISTRIBUTOR_ID","<%=DISTRIBUTOR_NO%>");
|
||||
setItemValue(0,0,"PAYER","<%=CurPage.getParameter("ProjectName")%>");
|
||||
setItemValue(0,0,"InputUserID","<%=CurUser.getUserName()%>");
|
||||
setItemValue(0,0,"InputOrgID","<%=CurUser.getOrgName()%>");
|
||||
setItemValue(0,0,"InputTime","<%=StringFunction.getTodayNow()%>");
|
||||
setItemValue(0,0,"UpdateUserID","<%=CurUser.getUserName()%>");
|
||||
setItemValue(0,0,"UpdateOrgID","<%=CurUser.getOrgName()%>");
|
||||
setItemValue(0,0,"UpdateTime","<%=StringFunction.getTodayNow()%>");
|
||||
function save(){
|
||||
var sFlowUnid = "<%=sFlowUnid%>";
|
||||
setItemValue(0,getRow(),"FlowUnid",sFlowUnid);//初始化流程编号
|
||||
as_save("myiframe0","returnList()");
|
||||
}
|
||||
function returnList(){
|
||||
AsControl.OpenView("/DealerDeposit/DMarginChargeInfo_TempList.jsp", "FlowUnid="+sFlowUnid,"_self","");
|
||||
}
|
||||
</script>
|
||||
<%@ include file="/Frame/resources/include/include_end.jspf"%>
|
||||
@ -6,8 +6,8 @@
|
||||
History Log:
|
||||
*/
|
||||
String sPrevUrl = CurPage.getParameter("ID");
|
||||
String docClassItemno = CurPage.getParameter("docClassItemno");
|
||||
String custid = CurPage.getParameter("custid");
|
||||
/* String docClassItemno = CurPage.getParameter("docClassItemno");
|
||||
String custid = CurPage.getParameter("custid"); */
|
||||
/* if(sPrevUrl == null) sPrevUrl = ""; */
|
||||
|
||||
String sTempletNo = "CustomerDoc_Info";//--模板号--
|
||||
@ -17,8 +17,8 @@
|
||||
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
|
||||
dwTemp.Style = "2";//freeform
|
||||
//dwTemp.ReadOnly = "-2";//只读模式
|
||||
//dwTemp.genHTMLObjectWindow(CurPage.getParameter("ID"));
|
||||
dwTemp.genHTMLObjectWindow("");
|
||||
dwTemp.genHTMLObjectWindow(CurPage.getParameter("ID"));
|
||||
//dwTemp.genHTMLObjectWindow("");
|
||||
|
||||
String sButtons[][] = {
|
||||
{"true","All","Button","保存","保存所有修改","save()","","","",""},
|
||||
@ -28,8 +28,8 @@
|
||||
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
|
||||
<script type="text/javascript">
|
||||
function save(){
|
||||
setItemValue(0,0,"doc_Class_Itemno","<%=docClassItemno%>");
|
||||
setItemValue(0,0,"cust_id","<%=custid%>");
|
||||
<%-- setItemValue(0,0,"doc_Class_Itemno","<%=docClassItemno%>");
|
||||
setItemValue(0,0,"cust_id","<%=custid%>"); --%>
|
||||
as_save("myiframe0","returnList()");
|
||||
}
|
||||
|
||||
|
||||
@ -10,9 +10,9 @@
|
||||
String custid=CurPage.getParameter("customerid");//客户ID
|
||||
String mainType= CurPage.getParameter("mainType");
|
||||
String docClassItemno="";
|
||||
if(mainType.equals("Customer")){
|
||||
if("Customer".equals(mainType)){
|
||||
docClassItemno="001001";
|
||||
}else if(mainType.equals("Guarantee")){
|
||||
}else if("Guarantee".equals(mainType)){
|
||||
docClassItemno="001002";
|
||||
}
|
||||
String compClientID = request.getParameter("CompClientID");
|
||||
@ -49,6 +49,9 @@
|
||||
String sButtons[][] =null;
|
||||
|
||||
sButtons=new String[][]{
|
||||
{"true","All","Button","新增","新增","newRecord()","","","",""},
|
||||
{"true","All","Button","修改","修改","viewAndEdit()","","","","btn_icon_edit"},
|
||||
{"true","","Button","删除","删除","if(confirm('确实要删除吗?'))as_delete(0)","","","","btn_icon_delete",""},
|
||||
};
|
||||
|
||||
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
|
||||
@ -58,8 +61,19 @@ window.onload=function(){
|
||||
$("#DWTD").width( document.body.offsetHeight - 20);
|
||||
document.getElementById('DWTD').innerHTML = '<div style="width:'+(document.body.offsetWidth - 10)+'px;height:'+(document.body.offsetHeight - 40)+'px;overflow: scroll;">'+document.getElementById('DWTD').innerHTML+'</div>';
|
||||
}
|
||||
function saveRecord(){
|
||||
as_save("myiframe0");
|
||||
function newRecord(){
|
||||
//debugger;
|
||||
var sUrl = "/Tenwa/Comm/CustomerDoc/CustomerDoc_Info.jsp";
|
||||
AsControl.OpenView(sUrl,'','_self','');<%-- "docClassItemno="+<%=docClassItemno%>+"&custid="+<%=custid%> --%>
|
||||
}
|
||||
function viewAndEdit(){
|
||||
var sUrl = "/Tenwa/Comm/CustomerDoc/CustomerDoc_Info.jsp";
|
||||
var sPara = getItemValue(0,getRow(0),'ID');
|
||||
if(typeof(sPara)=="undefined" || sPara.length==0 ){
|
||||
alert("参数不能为空!");
|
||||
return ;
|
||||
}
|
||||
AsControl.OpenView(sUrl,'ID=' +sPara ,'_self','');
|
||||
}
|
||||
//在加载完表格后调用
|
||||
function afterSearch(){
|
||||
@ -104,7 +118,7 @@ function showWord(id,name){
|
||||
var param="attrid="+id;
|
||||
AsControl.OpenPage(sUrl,param,"","");
|
||||
}
|
||||
//在线编辑
|
||||
<%-- //在线编辑
|
||||
function editOffice(id,filename,sRightType){
|
||||
var filetype=filename.substr(filename.indexOf(".")+1);
|
||||
var status=2;
|
||||
@ -121,7 +135,7 @@ function editOffice(id,filename,sRightType){
|
||||
alert("提交失败!");
|
||||
}
|
||||
},"编辑文档");
|
||||
}
|
||||
} --%>
|
||||
function showImage(id,name){
|
||||
var sUrl="/Tenwa/Comm/DocList/showImage.jsp";
|
||||
var param="attrid="+id;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -72,11 +72,6 @@
|
||||
<attribute name="EFFECTIVEDATE" label="生效日期" type="STRING" length="10"/>
|
||||
<attribute name="EXPIFYDATE" label="失效日期" type="STRING" length="10"/>
|
||||
<attribute name="CONFIGFILE" label="配置文件" type="STRING" length="100"/>
|
||||
<attribute name="LeasForm" label="租赁类型" type="STRING" length="20"/>
|
||||
<attribute name="equip_type" label="租赁物类型" type="STRING" length="20"/>
|
||||
<attribute name="IS_ALL_DEALER" label="产品适用所有经销商" type="STRING" length="10"/>
|
||||
<attribute name="IS_ALL_DEALER_GROUP" label="产品适用所经销商集团" type="STRING" length="10"/>
|
||||
<attribute name="IS_ALL_AREA" label="产品适用所有区域" type="STRING" length="10"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
|
||||
@ -3,9 +3,14 @@ package com.tenwa.flow;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO_TEMP;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITCHARGE_INFO_TEMP;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO;
|
||||
import jbo.com.tenwa.entity.comm.flow.D_DEPOSITRETURN_INFO_TEMP;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.baseBussion.BaseBussiness;
|
||||
@ -20,6 +25,14 @@ public class CopyDReturnTempToFormal extends BaseBussiness {
|
||||
fromCondtion.put("FLOWUNID", flowunid);
|
||||
Map<String,String> otherProperty = new HashMap<String,String>();
|
||||
otherProperty.put("ID", id);
|
||||
|
||||
BizObject dst= DataOperatorUtil.getSingleJBO(DISTRIBUTOR_INFO_TEMP.CLASS_NAME, fromCondtion, Sqlca);
|
||||
String disStatus = dst.getAttribute("id").toString();
|
||||
BizObjectManager dit = JBOFactory.getBizObjectManager(D_DEPOSITRETURN_INFO_TEMP.CLASS_NAME,Sqlca);
|
||||
BizObject deit = dit.createQuery("select * from O where FLOWUNID=:flowUnid").setParameter("flowUnid", flowunid).getSingleResult(true);
|
||||
deit.setAttributeValue("DISTRIBUTOR_ID", disStatus);
|
||||
dit.saveObject(deit);
|
||||
|
||||
DataOperatorUtil.copySingleJBO(D_DEPOSITRETURN_INFO_TEMP.CLASS_NAME, fromCondtion, D_DEPOSITRETURN_INFO.CLASS_NAME, null, otherProperty, Sqlca);
|
||||
return "true";
|
||||
}
|
||||
|
||||
78
calc/com/tenwa/flow/CopyInfoTempToFormal.java
Normal file
78
calc/com/tenwa/flow/CopyInfoTempToFormal.java
Normal file
@ -0,0 +1,78 @@
|
||||
package com.tenwa.flow;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO_TEMP;
|
||||
|
||||
import com.amarsoft.app.util.ASOrgObject;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.amarsoft.context.ASUser;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.baseBussion.BaseBussiness;
|
||||
import com.tenwa.lease.flow.project.businessapply.DistributorCompare;
|
||||
|
||||
public class CopyInfoTempToFormal extends BaseBussiness{
|
||||
|
||||
@Override
|
||||
public Object run(Transaction Sqlca) throws Exception {
|
||||
this.initBussinessParam(Sqlca);
|
||||
String orgid=this.saveOrgInfo(Sqlca);
|
||||
Map<String,String>fromCondtion=new HashMap<String, String>();
|
||||
fromCondtion.put("flowunid",this.getAttribute("FlowUnid").toString());
|
||||
BizObject dst= DataOperatorUtil.getSingleJBO(DISTRIBUTOR_INFO_TEMP.CLASS_NAME, fromCondtion, Sqlca);
|
||||
String disStatus = dst.getAttribute("distributor_status").toString();
|
||||
dst.setAttributeValue("orgid",orgid );
|
||||
BizObjectManager dit = JBOFactory.getBizObjectManager(DISTRIBUTOR_INFO_TEMP.CLASS_NAME,Sqlca);
|
||||
if("distributor_status08".equals(disStatus)){
|
||||
dst.setAttributeValue("distributor_status", "distributor_status09");
|
||||
}
|
||||
dit.saveObject(dst);
|
||||
Map<String,String>toCondtion=new HashMap<String, String>();
|
||||
DistributorCompare dc=new DistributorCompare();
|
||||
fromCondtion.clear();
|
||||
fromCondtion.put("flowunid",this.getAttribute("FlowUnid").toString());
|
||||
toCondtion.clear();
|
||||
toCondtion.put("distributor_no", dst.getAttribute("distributor_no").getString());
|
||||
|
||||
DataOperatorUtil.copyJBOSet(DISTRIBUTOR_INFO_TEMP.CLASS_NAME, fromCondtion, DISTRIBUTOR_INFO.CLASS_NAME, toCondtion, null, dc, Sqlca);
|
||||
String sMessage="true";
|
||||
return sMessage;
|
||||
}
|
||||
/**
|
||||
* 保存渠道信息
|
||||
* @author 2018-06-10
|
||||
*/
|
||||
private String saveOrgInfo(Transaction Sqlca) throws Exception {
|
||||
ASOrgObject orgObject= new ASOrgObject("8006");//默认为安鹏向下的渠道信息
|
||||
Map<String,String> mapOrgInfo=orgObject.nextLevalOrgNo(Sqlca);
|
||||
BizObjectManager manager = JBOFactory.getFactory().getManager("jbo.sys.ORG_INFO");
|
||||
BizObject bo=null;
|
||||
BizObjectManager PM=JBOFactory.getBizObjectManager(DISTRIBUTOR_INFO_TEMP.CLASS_NAME);
|
||||
BizObject partnerInfo=PM.createQuery(" select * from O where O.flowUnid=:flowUnid").setParameter("flowUnid", this.getAttribute("FlowUnid").toString()).getSingleResult(true);
|
||||
if(!mapOrgInfo.isEmpty()){
|
||||
ASUser asUser=new ASUser(this.getAttribute("CurUserID").toString());
|
||||
bo=manager.newObject();
|
||||
bo.setAttributeValue("ORGID", mapOrgInfo.get("orgno"));
|
||||
bo.setAttributeValue("SORTNO", mapOrgInfo.get("sortno"));
|
||||
bo.setAttributeValue("TREESORTNO", mapOrgInfo.get("sortno"));
|
||||
bo.setAttributeValue("ORGLEVEL", "9");//默认渠道
|
||||
bo.setAttributeValue("STATUS", "1");//默认启用
|
||||
if(partnerInfo!=null){
|
||||
bo.setAttributeValue("RELATIVEORGID", "8006");
|
||||
bo.setAttributeValue("BELONGORGID", "8006");
|
||||
bo.setAttributeValue("ORGNAME", partnerInfo.getAttribute("distributor_name").toString());
|
||||
bo.setAttributeValue("INPUTORG", asUser.getOrgID());
|
||||
bo.setAttributeValue("InputUser", asUser.getUserID());
|
||||
bo.setAttributeValue("InputTime", StringFunction.getTodayNow());
|
||||
}
|
||||
manager.saveObject(bo);
|
||||
}
|
||||
return bo.getAttribute("ORGID").toString();
|
||||
}
|
||||
}
|
||||
78
calc/com/tenwa/flow/CopyReturnInfoTempToFormal.java
Normal file
78
calc/com/tenwa/flow/CopyReturnInfoTempToFormal.java
Normal file
@ -0,0 +1,78 @@
|
||||
package com.tenwa.flow;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO;
|
||||
import jbo.app.tenwa.customer.DISTRIBUTOR_INFO_TEMP;
|
||||
|
||||
import com.amarsoft.app.util.ASOrgObject;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.amarsoft.context.ASUser;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.baseBussion.BaseBussiness;
|
||||
import com.tenwa.lease.flow.project.businessapply.DistributorCompare;
|
||||
|
||||
public class CopyReturnInfoTempToFormal extends BaseBussiness{
|
||||
|
||||
@Override
|
||||
public Object run(Transaction Sqlca) throws Exception {
|
||||
this.initBussinessParam(Sqlca);
|
||||
String orgid=this.saveOrgInfo(Sqlca);
|
||||
Map<String,String>fromCondtion=new HashMap<String, String>();
|
||||
fromCondtion.put("flowunid",this.getAttribute("FlowUnid").toString());
|
||||
BizObject dst= DataOperatorUtil.getSingleJBO(DISTRIBUTOR_INFO_TEMP.CLASS_NAME, fromCondtion, Sqlca);
|
||||
String disStatus = dst.getAttribute("distributor_status").toString();
|
||||
dst.setAttributeValue("orgid",orgid );
|
||||
BizObjectManager dit = JBOFactory.getBizObjectManager(DISTRIBUTOR_INFO_TEMP.CLASS_NAME,Sqlca);
|
||||
if("distributor_status06".equals(disStatus)){
|
||||
dst.setAttributeValue("distributor_status", "distributor_status10");
|
||||
}
|
||||
dit.saveObject(dst);
|
||||
Map<String,String>toCondtion=new HashMap<String, String>();
|
||||
DistributorCompare dc=new DistributorCompare();
|
||||
fromCondtion.clear();
|
||||
fromCondtion.put("flowunid",this.getAttribute("FlowUnid").toString());
|
||||
toCondtion.clear();
|
||||
toCondtion.put("distributor_no", dst.getAttribute("distributor_no").getString());
|
||||
|
||||
DataOperatorUtil.copyJBOSet(DISTRIBUTOR_INFO_TEMP.CLASS_NAME, fromCondtion, DISTRIBUTOR_INFO.CLASS_NAME, toCondtion, null, dc, Sqlca);
|
||||
String sMessage="true";
|
||||
return sMessage;
|
||||
}
|
||||
/**
|
||||
* 保存渠道信息
|
||||
* @author 2018-06-10
|
||||
*/
|
||||
private String saveOrgInfo(Transaction Sqlca) throws Exception {
|
||||
ASOrgObject orgObject= new ASOrgObject("8006");//默认为安鹏向下的渠道信息
|
||||
Map<String,String> mapOrgInfo=orgObject.nextLevalOrgNo(Sqlca);
|
||||
BizObjectManager manager = JBOFactory.getFactory().getManager("jbo.sys.ORG_INFO");
|
||||
BizObject bo=null;
|
||||
BizObjectManager PM=JBOFactory.getBizObjectManager(DISTRIBUTOR_INFO_TEMP.CLASS_NAME);
|
||||
BizObject partnerInfo=PM.createQuery(" select * from O where O.flowUnid=:flowUnid").setParameter("flowUnid", this.getAttribute("FlowUnid").toString()).getSingleResult(true);
|
||||
if(!mapOrgInfo.isEmpty()){
|
||||
ASUser asUser=new ASUser(this.getAttribute("CurUserID").toString());
|
||||
bo=manager.newObject();
|
||||
bo.setAttributeValue("ORGID", mapOrgInfo.get("orgno"));
|
||||
bo.setAttributeValue("SORTNO", mapOrgInfo.get("sortno"));
|
||||
bo.setAttributeValue("TREESORTNO", mapOrgInfo.get("sortno"));
|
||||
bo.setAttributeValue("ORGLEVEL", "9");//默认渠道
|
||||
bo.setAttributeValue("STATUS", "1");//默认启用
|
||||
if(partnerInfo!=null){
|
||||
bo.setAttributeValue("RELATIVEORGID", "8006");
|
||||
bo.setAttributeValue("BELONGORGID", "8006");
|
||||
bo.setAttributeValue("ORGNAME", partnerInfo.getAttribute("distributor_name").toString());
|
||||
bo.setAttributeValue("INPUTORG", asUser.getOrgID());
|
||||
bo.setAttributeValue("InputUser", asUser.getUserID());
|
||||
bo.setAttributeValue("InputTime", StringFunction.getTodayNow());
|
||||
}
|
||||
manager.saveObject(bo);
|
||||
}
|
||||
return bo.getAttribute("ORGID").toString();
|
||||
}
|
||||
}
|
||||
@ -1,133 +0,0 @@
|
||||
package com.tenwa.voucher.CreateVoucherProcess;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import jbo.voucher.LV_VOUCHER_CONFIG;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.flow.baseBussion.BaseBussiness;
|
||||
import com.tenwa.leasing.serviceImpl.voucher.CreateVoucherServiceImpl;
|
||||
|
||||
public class CreateVoucherLoanDistributor extends BaseBussiness{
|
||||
@Override
|
||||
public Object run(Transaction Sqlca) throws Exception {
|
||||
this.initBussinessParam(Sqlca);
|
||||
Map<String,String> map=new HashMap<String, String>();
|
||||
Map<String,String> param=new HashMap<String, String>();
|
||||
|
||||
String ACCOUNT_DATE=null;
|
||||
String FACT_DATE=null;
|
||||
String CONTRACT_ID=null;
|
||||
String CONTRACT_NUMBER=null;
|
||||
String PROJECT_NAME=null;
|
||||
String leas_form=null;
|
||||
String CONSTARTNUM=null;
|
||||
String ORGNAME=null;
|
||||
String ORGID=null;
|
||||
String MONEY=null;
|
||||
String ACCOUNTNO=null;
|
||||
String CUSTOMERID=null;
|
||||
String CUSTOMERNAME=null;
|
||||
String FlowUnid=this.getAttribute("FlowUnid").toString();
|
||||
param.clear();
|
||||
map.put("FlowUnid", FlowUnid);
|
||||
map.put("FEE_TYPE", "feetype16");
|
||||
String sql=
|
||||
" SELECT LFIT.FACT_MONEY AS MONEY,LFIT.ACCOUNTING_DATE AS ACCOUNT_DATE, "
|
||||
+" LFIT.FACT_DATE,LFIT.CONTRACT_ID,LCI.CONTRACT_NUMBER, "
|
||||
+" LCI.PROJECT_NAME,LCI.LEAS_FORM,nvl(LFIT.acc_number,'122905168210604') as ACCOUNTNO,CASE WHEN LCI.CONSTARTNUM IS NULL THEN '000000000000' ELSE LCI.CONSTARTNUM END AS CONSTARTNUM, "
|
||||
+" ORG.ORGNAME,ORG.ORGID,LESS.CUSTOMER_ID as CUSTOMERID,LESS.CUSTOMER_NAME AS CUSTOMERNAME "
|
||||
+" FROM LC_FUND_INCOME_TEMP LFIT "
|
||||
+" LEFT JOIN LB_CONTRACT_INFO LCI ON LFIT.CONTRACT_ID=LCI.ID "
|
||||
+" LEFT JOIN ORG_INFO ORG ON ORG.ORGID=LCI.PROJECT_DEPT "
|
||||
+" LEFT JOIN LB_UNION_LESSEE LESS ON LESS.CONTRACT_ID=LCI.ID "
|
||||
+" where LFIT.FEE_TYPE=:FEE_TYPE and LFIT.FLOWUNID=:FlowUnid ";
|
||||
List<Map<String,String>> dataList=DataOperatorUtil.getDataBySql(Sqlca, sql, map);
|
||||
|
||||
CreateVoucherServiceImpl vs=new CreateVoucherServiceImpl();
|
||||
String VOUCHER_TYPE="1";// 凭证分类 金蝶
|
||||
String userid ="admin";
|
||||
for (int i=0;i<dataList.size();i++){
|
||||
|
||||
ACCOUNT_DATE=dataList.get(i).get("ACCOUNT_DATE").toString();
|
||||
FACT_DATE =dataList.get(i).get("FACT_DATE").toString();
|
||||
CONTRACT_ID=dataList.get(i).get("CONTRACT_ID").toString();
|
||||
CONTRACT_NUMBER=dataList.get(i).get("CONTRACT_NUMBER").toString();
|
||||
PROJECT_NAME=dataList.get(i).get("PROJECT_NAME").toString();
|
||||
leas_form=dataList.get(i).get("LEAS_FORM").toString();
|
||||
CONSTARTNUM=dataList.get(i).get("CONSTARTNUM").toString();
|
||||
ORGNAME=dataList.get(i).get("ORGNAME").toString();
|
||||
ORGID=dataList.get(i).get("ORGID").toString();
|
||||
MONEY=dataList.get(i).get("MONEY").toString();
|
||||
ACCOUNTNO=dataList.get(i).get("ACCOUNTNO").toString();
|
||||
CUSTOMERID=dataList.get(i).get("CUSTOMERID");
|
||||
CUSTOMERNAME=dataList.get(i).get("CUSTOMERNAME");
|
||||
param.put("ACCOUNT_DATE",ACCOUNT_DATE);
|
||||
param.put("FACT_DATE",FACT_DATE);
|
||||
param.put("CONTRACT_ID",CONTRACT_ID);
|
||||
param.put("CONTRACT_NUMBER",CONTRACT_NUMBER);
|
||||
param.put("PROJECT_NAME",PROJECT_NAME);
|
||||
param.put("CONSTARTNUM",CONSTARTNUM);
|
||||
param.put("ORGNAME",ORGNAME);
|
||||
param.put("ORGID",ORGID);
|
||||
param.put("LEAS_FORM",leas_form);
|
||||
param.put("FACT_MONEY",MONEY);
|
||||
param.put("ACCOUNTNO",ACCOUNTNO);
|
||||
param.put("FlowUnid", FlowUnid);
|
||||
param.put("CUSTOMERID",CUSTOMERID);
|
||||
param.put("CUSTOMERNAME",CUSTOMERNAME);
|
||||
map.clear();
|
||||
map.put("PROJ_TYPE", leas_form);
|
||||
map.put("MODULAR_NUMBER", "风险抵押金抵扣租金");
|
||||
BizObject vouch=DataOperatorUtil.getSingleJBO(LV_VOUCHER_CONFIG.CLASS_NAME, map, Sqlca);
|
||||
|
||||
if(vouch!=null){
|
||||
//vs.createVoucher("风险抵押金抵扣租金", vouch.getAttribute("OWNED_COMPANY").getString(), leas_form, VOUCHER_TYPE, userid,param, Sqlca);
|
||||
}
|
||||
}
|
||||
|
||||
// 租金部分
|
||||
map.clear();
|
||||
map.put("FlowUnid", FlowUnid);
|
||||
String rentIncomeSql="select ID,PLAN_ID,RENT,CORPUS,INTEREST,nvl(PENALTY,'0.00') as PENALTY,HIRE_DATE as FACT_DATE,ACCOUNTING_DATE as ACCOUNT_DATE,CONTRACT_ID,PLAN_LIST, "
|
||||
+ "own_number as ACCOUNTNO from LC_RENT_INCOME_TEMP where FLOWUNID=:FlowUnid ";
|
||||
List<Map<String,String>> RentdataList=DataOperatorUtil.getDataBySql(Sqlca, rentIncomeSql, map);
|
||||
|
||||
for (int i=0;i<RentdataList.size();i++){
|
||||
String ID=RentdataList.get(i).get("ID").toString();
|
||||
String PLAN_ID=RentdataList.get(i).get("PLAN_ID").toString();
|
||||
String RENT=RentdataList.get(i).get("RENT").toString();
|
||||
String CORPUS=RentdataList.get(i).get("CORPUS").toString();
|
||||
String INTEREST=RentdataList.get(i).get("INTEREST").toString();
|
||||
String PENALTY=RentdataList.get(i).get("PENALTY").toString();
|
||||
String PLAN_LIST=RentdataList.get(i).get("PLAN_LIST").toString();
|
||||
CONTRACT_ID=RentdataList.get(i).get("CONTRACT_ID").toString();
|
||||
String ACCOUNTNORent=RentdataList.get(i).get("ACCOUNTNO").toString();
|
||||
param.put("ID",ID);
|
||||
param.put("PLAN_ID",PLAN_ID);
|
||||
param.put("RENT", RENT);
|
||||
param.put("CORPUS",CORPUS);
|
||||
param.put("INTEREST",INTEREST);
|
||||
param.put("PENALTY",PENALTY);
|
||||
param.put("FACT_DATE",FACT_DATE);
|
||||
param.put("ACCOUNT_DATE", ACCOUNT_DATE);
|
||||
param.put("ACCOUNTNO", ACCOUNTNORent);
|
||||
|
||||
//createVoucherRentIncome createVoucherRentIncome=new createVoucherRentIncome();
|
||||
String Vparams=ID+","+PLAN_ID+","+RENT+","+CORPUS+","+INTEREST+","+PENALTY+","+CONTRACT_ID+","+FACT_DATE+","+ACCOUNT_DATE+","+"admin"+","+PLAN_LIST;
|
||||
//createVoucherRentIncome.setVparams(Vparams);
|
||||
//createVoucherRentIncome.createVoucher(Sqlca);
|
||||
|
||||
}
|
||||
if(Sqlca!=null){
|
||||
Sqlca.commit();
|
||||
}
|
||||
|
||||
String sMessage="true";
|
||||
return sMessage;
|
||||
}
|
||||
}
|
||||
@ -46,7 +46,6 @@ public class DistributorInfoTempToFormalBusiness extends BaseBussiness {
|
||||
dst.setAttributeValue("orgid",orgid );
|
||||
BizObjectManager dit = JBOFactory.getBizObjectManager(DISTRIBUTOR_INFO_TEMP.CLASS_NAME,Sqlca);
|
||||
if(null==disStatus || disStatus.length()<=0){
|
||||
dst.setAttributeValue("distributor_status", "distributor_status04");
|
||||
dst.setAttributeValue("distributor_status", "distributor_status08");
|
||||
}
|
||||
dit.saveObject(dst);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user