diff --git a/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp b/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp index 3bc7f883c..31a343918 100644 --- a/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp +++ b/WebContent/Tenwa/Lease/Flow/Project/BusinessApproval/ProjectApprovalCreationInfo.jsp @@ -93,7 +93,7 @@ var productModel =getItemValue(0,getRow(),"productModel"); var carSeries = getItemValue(0,getRow(),"carSeries"); var carSystem = getItemValue(0,getRow(),"carSystem"); - var productid = getItemValue(0,getRow(),"productId"); + var productId = getItemValue(0,getRow(),"productId"); var productname = getItemValue(0,getRow(),"productName"); var custid = getItemValue(0,getRow(),"CustomerID"); var custname = getItemValue(0,getRow(),"CustomerName"); @@ -116,9 +116,8 @@ alert("请选择租赁方式"); return; } - if(certtype==""){ - alert("请选择证件类型"); - + if(productModel==""){ + alert("请选择汽车品牌"); return; } if(carSystem==""){ @@ -130,29 +129,25 @@ alert("请选择品牌车型"); return; } - if(certid==""){ - alert("请输入证件号码"); - - return; - } - if(productModel==""){ - alert("请选择汽车品牌"); - - return; - } - if(productid==""){ - alert("请选择业务品种"); - + if(custname==""){ + alert("请输入客户名称"); return; } if(customerType==""){ alert("请选择客户类别"); - + return; + } + if(certtype==""){ + alert("请选择证件类型"); + return; + } + if(certid==""){ + alert("请输入证件号码"); return; } var sParams = "ApplyType=<%=sApplyType%>,CurUserID=<%=CurUser.getUserID()%>"; - sParams =sParams+",ProductId="+productid+",ProductName="+productname+",CustomerType="+customerType+",carAttributes="+carAttributes+",leasehold="+leasehold+",carSystem="+carSystem+",custname="+custname+",certtype="+certtype+",certid="+certid+",productModel="+productModel+",carSeries="+carSeries+",versionid="+versionid+",modelid="+modelid+",businessType="+businessType+",price="+price+",liter="+liter+",geartype="+geartype; + sParams =sParams+",ProductId="+productId+",ProductName="+productname+",CustomerType="+customerType+",carAttributes="+carAttributes+",leasehold="+leasehold+",carSystem="+carSystem+",custname="+custname+",certtype="+certtype+",certid="+certid+",productModel="+productModel+",carSeries="+carSeries+",versionid="+versionid+",modelid="+modelid+",businessType="+businessType+",price="+price+",liter="+liter+",geartype="+geartype; var sReturnInfo = RunJavaMethodTrans("com.tenwa.lease.flow.project.projectapproval.BusinessApprovalStartAction","initFLow",sParams); if(typeof(sReturnInfo)=="undefined" || sReturnInfo=="" || sReturnInfo=="_CANCEL_" ) { @@ -316,9 +311,20 @@ } sReturn = sReturn.split("@"); // alert(sReturn); - setItemValue(0,0,"productId",sReturn[0]); - setItemValue(0,0,"productName",sReturn[1]); - setItemValue(0,0,"versionid",sReturn[1]); + MyOjbect.typeno = sReturn[0];//产品编号 + MyOjbect.sortno = sReturn[1];//产品排序号 + MyOjbect.typename = sReturn[2];//产品名称 + MyOjbect.PRODUCTID = sReturn[3];//产品ID + MyOjbect.VERSIONID = sReturn[4];//版本ID + MyOjbect.id = sReturn[5];//经销商ID + MyOjbect.distributor_name = sReturn[6];//经销商名称 + MyOjbect.modelid = sReturn[7];//车型ID + MyOjbect.modelname = sReturn[8];//车型名称 + + setItemValue(0,0,"productName",sReturn[2]); + setItemValue(0,0,"productId",sReturn[3]); + setItemValue(0,0,"versionid",sReturn[4]); + },"请选择产品",''); }else{ if(modelid){ @@ -375,7 +381,7 @@ sReturn = sReturn.split("@"); // alert(sReturn[1]); setItemValue(0,0,"CUSTOMERID",sReturn[0]); - setItemValue(0,0,"customername",sReturn[1]); + setItemValue(0,0,"CustomerName",sReturn[1]); setCertType(); },"请选择客户",''); } diff --git a/src_tenwa/com/tenwa/lease/flow/project/commbusiness/LBProjectIntoTempInitCarBusiness.java b/src_tenwa/com/tenwa/lease/flow/project/commbusiness/LBProjectIntoTempInitCarBusiness.java index d38661d73..4b7165b98 100644 --- a/src_tenwa/com/tenwa/lease/flow/project/commbusiness/LBProjectIntoTempInitCarBusiness.java +++ b/src_tenwa/com/tenwa/lease/flow/project/commbusiness/LBProjectIntoTempInitCarBusiness.java @@ -86,32 +86,32 @@ public class LBProjectIntoTempInitCarBusiness extends BaseBussiness { boLULT.setAttributeValue("InputUserID", asUser.getUserID()); boLULT.setAttributeValue("InputTime", StringFunction.getToday()); boLULT.setAttributeValue("is_main", "Y"); - //项目编号, + + //项目信息表 String deptid = asUser.getOrgID() ; if(deptid.startsWith("8006")) { BizObject distributor_bo=JBOFactory.createBizObjectQuery(DISTRIBUTOR_INFO.CLASS_NAME,"orgid=:orgid").setParameter("orgid",deptid).getSingleResult(false); if(distributor_bo!=null) { - bo.setAttributeValue("distributor_id",distributor_bo.getAttribute("distributor_no")); + bo.setAttributeValue("distributor_id",distributor_bo.getAttribute("distributor_no"));//经销商ID } } - bo.setAttributeValue("PROJECT_NO",this.getAttribute("ProjectNo")); - bo.setAttributeValue("id", this.getAttribute("ProjectId")); - bo.setAttributeValue("FLOWUNID", this.getAttribute("FlowUnid")); - bo.setAttributeValue("project_name",this.getAttribute("ProjectName")+"-"+this.getAttribute("ProductName")); - bo.setAttributeValue("project_name",this.getAttribute("ProjectNo")); - bo.setAttributeValue("project_manage",this.getAttribute("CurUserID")); - bo.setAttributeValue("project_dept",deptid); - bo.setAttributeValue("VERSIONID", this.getAttribute("versionid")); - bo.setAttributeValue("BUSINESSTYPE", this.getAttribute("businessType")); + bo.setAttributeValue("FLOWUNID", this.getAttribute("FlowUnid"));//流程ID + bo.setAttributeValue("id", this.getAttribute("ProjectId"));//项目ID + bo.setAttributeValue("PROJECT_NO",this.getAttribute("ProjectNo"));//申请编号 + bo.setAttributeValue("project_name",this.getAttribute("ProjectNo")+"-"+this.getAttribute("ProductName")); + bo.setAttributeValue("CAR_TYPE",this.getAttribute("carAttributes"));//车辆属性 bo.setAttributeValue("LEAS_FORM", this.getAttribute("leasehold"));//租赁方式 - bo.setAttributeValue("PRODUCT_ID",this.getAttribute("ProductId"));//业务品种编号 - bo.setAttributeValue("PRODUCT_NAME",this.getAttribute("ProductName"));//业务品种名称 - bo.setAttributeValue("CAR_TYPE",this.getAttribute("carAttributes")); - bo.setAttributeValue("PROJECT_STATUS","0"); + bo.setAttributeValue("VERSIONID", this.getAttribute("versionid"));//版本ID + bo.setAttributeValue("PRODUCT_ID",this.getAttribute("ProductId"));//产品ID + bo.setAttributeValue("PRODUCT_NAME",this.getAttribute("ProductName"));//产品名称 bo.setAttributeValue("Is_Flow","inFlow");//在流程中-inFlow,流程结束-outFlow - bo.setAttributeValue("InputOrgID", asUser.getOrgID()); - bo.setAttributeValue("InputUserID", asUser.getUserID()); - bo.setAttributeValue("InputTime", StringFunction.getToday()); + bo.setAttributeValue("INPUTUSERID", asUser.getUserID());//登记人 + bo.setAttributeValue("INPUTORGID", asUser.getOrgID());//登记部门 + bo.setAttributeValue("INPUTTIME", StringFunction.getTodayNow());//登记时间,系统当前时间 + bo.setAttributeValue("BUSINESSTYPE", this.getAttribute("businessType"));//业务类型 + bo.setAttributeValue("project_manage",asUser.getUserID());//项目经理 + bo.setAttributeValue("project_dept",deptid);//出单部门 + bo.setAttributeValue("PROJECT_STATUS","0");//项目状态 bm.saveObject(bo); bmCPT.saveObject(boCRT); diff --git a/src_tenwa/com/tenwa/lease/flow/project/projectapproval/BusinessApprovalStartAction.java b/src_tenwa/com/tenwa/lease/flow/project/projectapproval/BusinessApprovalStartAction.java index 2e8fd07eb..e7e7b2393 100644 --- a/src_tenwa/com/tenwa/lease/flow/project/projectapproval/BusinessApprovalStartAction.java +++ b/src_tenwa/com/tenwa/lease/flow/project/projectapproval/BusinessApprovalStartAction.java @@ -49,9 +49,11 @@ public class BusinessApprovalStartAction extends BaseFlowStartAction{ private String liter; private String geartype; private String ProductName; + private String ProductId; @Override public void customOperation(JBOTransaction tx,BizObject flowBussiness) throws Exception { + String uuid = UUID.randomUUID().toString(); this.FlowParam.put("ProjectId", UUID.randomUUID().toString().replaceAll("-", "")); String projectNO=SerialNumberUtil.getProjectSerialNumber1(this.getAsUser().getOrgID(), tx); //String projectName=projectNO+"_"+this.FlowParam.get("CustName")+this.FlowParam.get("ProductName")+"项目"; @@ -74,9 +76,20 @@ public class BusinessApprovalStartAction extends BaseFlowStartAction{ this.FlowParam.put("liter", this.getLiter()); this.FlowParam.put("geartype", this.getGeartype()); this.FlowParam.put("ProductName", this.getProductName()); + this.FlowParam.put("ProductId", this.getProductId()); } + public String getProductId() { + return ProductId; + } + + + public void setProductId(String productId) { + ProductId = productId; + } + + public String getProductName() { return ProductName; }