修改审批意见
This commit is contained in:
parent
c1e311bf52
commit
54444c3038
@ -15,7 +15,7 @@
|
||||
String taskno=CurPage.getParameter("TaskNo");
|
||||
String RightType= CurPage.getParameter("RightType");
|
||||
String customerType= CurPage.getParameter("CustomerType");
|
||||
|
||||
String flowstate = CurPage.getParameter("flowstate");
|
||||
String flowunid = CurPage.getParameter("FlowUnid");
|
||||
String clean_lease_money = Sqlca.getString("select CLEAN_LEASE_MONEY from LC_CALC_CONDITION_TEMP where flowunid='"+flowunid+"'");
|
||||
//int money = Integer.parseInt(clean_lease_money);
|
||||
@ -25,7 +25,7 @@
|
||||
double money = Double.parseDouble(clean_lease_money);
|
||||
CurPage.getCurComp().setAttribute("RightType", null);
|
||||
|
||||
String sTempletNo = "VI_BUSINESS_APPROVAL";//--Ä£°åºÅ--
|
||||
String sTempletNo = "VI_PROJECTINFO_APPROVAL";//--ÄŁ°ĺşĹ--
|
||||
ASObjectModel doTemp = new ASObjectModel(sTempletNo);
|
||||
if("01".equals(customerType)){
|
||||
doTemp.setVisible("SEX",false);//如果是法人客户隐藏性别字段
|
||||
@ -50,6 +50,15 @@
|
||||
dwTemp.getDataObject().setRequired("firstchoice", true);
|
||||
dwTemp.getDataObject().setRequired("firstopinion", true);
|
||||
dwTemp.setGroupHidden("0030,0040,0050");
|
||||
if("BACK".equals(flowstate)||"ANYBACK".equals(flowstate)){
|
||||
dwTemp.getDataObject().setVisible("secondchoice", true);
|
||||
dwTemp.getDataObject().setVisible("secondopinion", true);
|
||||
dwTemp.getDataObject().setReadOnly("secondchoice", true);
|
||||
dwTemp.getDataObject().setReadOnly("secondopinion", true);
|
||||
dwTemp.getDataObject().setVisible("InterOpinion2", true);
|
||||
dwTemp.getDataObject().setReadOnly("InterOpinion2", true);
|
||||
dwTemp.setGroupHidden("0040,0050");
|
||||
}
|
||||
}else if("0040".equals(phaseNo)){//复审
|
||||
dwTemp.getDataObject().setVisible("firstchoice", true);
|
||||
dwTemp.getDataObject().setVisible("firstopinion", true);
|
||||
@ -59,7 +68,16 @@
|
||||
dwTemp.getDataObject().setVisible("secondopinion", true);
|
||||
dwTemp.getDataObject().setRequired("secondchoice", true);
|
||||
dwTemp.getDataObject().setRequired("secondopinion", true);
|
||||
dwTemp.setGroupHidden("0040,0050");
|
||||
dwTemp.setGroupHidden("0040");
|
||||
if("BACK".equals(flowstate)||"ANYBACK".equals(flowstate)){
|
||||
dwTemp.getDataObject().setVisible("thirdchoice", true);
|
||||
dwTemp.getDataObject().setVisible("thirdopinion", true);
|
||||
dwTemp.getDataObject().setReadOnly("thirdchoice", true);
|
||||
dwTemp.getDataObject().setReadOnly("thirdopinion", true);
|
||||
dwTemp.getDataObject().setVisible("INTEROPINION3", true);
|
||||
dwTemp.getDataObject().setReadOnly("INTEROPINION3", true);
|
||||
dwTemp.setGroupHidden("0050");
|
||||
}
|
||||
}else if("0050".equals(phaseNo)){//信审
|
||||
if(!"true".equals(ishistory)){
|
||||
dwTemp.getDataObject().setVisible("firstchoice", true);
|
||||
@ -123,6 +141,11 @@
|
||||
$("#A_div_1240").attr("style","display:none;");
|
||||
$("#A_div_1250").attr("style","display:none;");
|
||||
$("#A_div_1260").attr("style","display:none;");
|
||||
if("BACK"=="<%=flowstate%>"||"ANYBACK"=="<%=flowstate%>"){
|
||||
$("#A_div_1230").attr("style","display:block;");
|
||||
$("#A_div_1240").attr("style","display:block;");
|
||||
$("#A_div_1260").attr("style","display:block;");
|
||||
}
|
||||
_user_validator[0]['rules']['FIRSTCHOICE']['required0'] = true;
|
||||
_user_validator[0]['messages']['FIRSTCHOICE']['required0'] = '请输入初审意见';
|
||||
_user_validator[0]['rules']['FIRSTOPINION']['required0'] = true;
|
||||
@ -136,7 +159,10 @@
|
||||
$("#FIRSTOPINION").attr("disabled","disabled");//审批意见
|
||||
$("#INTEROPINION1").attr("disabled","disabled");//初审内部意见
|
||||
$("#DISTRIOPINION1").attr("disabled","disabled");//初审经销商意见
|
||||
|
||||
if("BACK"=="<%=flowstate%>"||"ANYBACK"=="<%=flowstate%>"){
|
||||
$("#A_div_1250").attr("style","display:block;");
|
||||
$("#A_div_1260").attr("style","display:block;");
|
||||
}
|
||||
_user_validator[0]['rules']['SECONDCHOICE']['required0'] = true;
|
||||
_user_validator[0]['messages']['SECONDCHOICE']['required0'] = '请输入复审意见';
|
||||
_user_validator[0]['rules']['SECONDOPINION']['required0'] = true;
|
||||
@ -219,6 +245,7 @@
|
||||
setItemValue(0,0,"firstopinion","");
|
||||
$("#FIRSTOPINION").attr("disabled","disabled");
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
function checkCertId(){//校验证件号
|
||||
@ -263,6 +290,7 @@
|
||||
if(firstchoice=="0030"){
|
||||
setItemRequired(0,"InterOpinion1",false);
|
||||
setItemRequired(0,"DistriOpinion1",true);
|
||||
setItemRequired(0,"FIRSTOPINION",false);
|
||||
setItemValue(0,0,"firstopinion","");
|
||||
$("#FIRSTOPINION").attr("disabled","disabled");
|
||||
}
|
||||
|
||||
@ -1062,6 +1062,48 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="VI_PROJECTINFO_APPROVAL" label="审批表(承租人基本信息)" keyAttributes="">
|
||||
<attributes>
|
||||
<attribute name="FLOWUNID" label="流程编号" type="STRING"/>
|
||||
<attribute name="FULLNAME" label="姓名" type="STRING"/>
|
||||
<attribute name="SEX" label="性别" type="STRING"/>
|
||||
<attribute name="CERTTYPE" label="证件类型" type="STRING"/>
|
||||
<attribute name="CERTID" label="证件号码" type="STRING"/>
|
||||
<attribute name="WORKCORP" label="单位名称" type="STRING"/>
|
||||
<attribute name="WORKADD" label="单位地址" type="STRING"/>
|
||||
<attribute name="ENTRYTIME" label="入职时间" type="STRING"/>
|
||||
<attribute name="FORMALEMP" label="是否是正式员工" type="STRING"/>
|
||||
<attribute name="PRODUCTNAME" label="产品" type="STRING"/>
|
||||
<attribute name="CLEANLEASEMONEY" label="融资金额" type="STRING"/>
|
||||
<attribute name="LEASETERM" label="融资期限(月)" type="STRING"/>
|
||||
<attribute name="INCOMENUMBERYEAR" label="还款方式" type="STRING"/>
|
||||
<attribute name="firstchoice" label="初审意见" type="STRING"/>
|
||||
<attribute name="firstopinion" label="审批意见" type="STRING"/>
|
||||
<attribute name="secondchoice" label="复审意见" type="STRING"/>
|
||||
<attribute name="secondopinion" label="审批意见" type="STRING"/>
|
||||
<attribute name="thirdchoice" label="部门负责人意见" type="STRING"/>
|
||||
<attribute name="thirdopinion" label="审批意见" type="STRING"/>
|
||||
<attribute name="fourchoice" label="总经理意见" type="STRING"/>
|
||||
<attribute name="fouropinion" label="审批意见" type="STRING"/>
|
||||
<attribute name="project_no" label="项目编号" type="STRING"/>
|
||||
<attribute name="car_type" label="车类型" type="STRING"/>
|
||||
<attribute name="LEAS_FORM" label="租赁方式" type="STRING"/>
|
||||
<attribute name="InterOpinion1" label="内部意见1" type="STRING"/>
|
||||
<attribute name="DistriOpinion1" label="经销商意见1" type="STRING"/>
|
||||
<attribute name="InterOpinion2" label="内部意见2" type="STRING"/>
|
||||
<attribute name="DistriOpinion2" label="经销商意见2" type="STRING"/>
|
||||
<attribute name="InterOpinion3" label="内部意见3" type="STRING"/>
|
||||
<attribute name="DistriOpinion3" label="经销商意见3" type="STRING"/>
|
||||
<attribute name="InterOpinion4" label="内部意见4" type="STRING"/>
|
||||
<attribute name="DistriOpinion4" label="经销商意见4" type="STRING"/>
|
||||
</attributes>
|
||||
<manager>
|
||||
<managerProperties>
|
||||
<property name="table" value="VI_PROJECTINFO_APPROVAL" />
|
||||
<property name="createKey" value="true" />
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
<class name="LB_MEETING_RECODE" label="会议记录" keyAttributes="ID">
|
||||
<attributes>
|
||||
<attribute name="ID" label="标识" type="STRING" length="32"/>
|
||||
@ -4284,6 +4326,5 @@
|
||||
</managerProperties>
|
||||
</manager>
|
||||
</class>
|
||||
|
||||
</package>
|
||||
</jbo>
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
package com.tenwa.controller;
|
||||
|
||||
import jbo.com.tenwa.lease.comm.VI_BUSINESS_APPROVAL;
|
||||
import jbo.com.tenwa.lease.comm.VI_PROJECTINFO_APPROVAL;
|
||||
import jbo.com.tenwa.limit.LA_LIMIT_ELEMENT;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
@ -61,17 +62,17 @@ public class LAElementConfigController {
|
||||
}
|
||||
public String queryBusinessApproval(JBOTransaction tx)throws Exception {
|
||||
String meagess="";
|
||||
BizObjectManager lleManager = JBOFactory.getBizObjectManager(VI_BUSINESS_APPROVAL.CLASS_NAME,tx);
|
||||
BizObjectManager lleManager = JBOFactory.getBizObjectManager(VI_PROJECTINFO_APPROVAL.CLASS_NAME,tx);
|
||||
BizObject bo = lleManager.createQuery("FLOWUNID=:FLOWUNID ").setParameter("FLOWUNID",this.getObjectNo()).getSingleResult(false);
|
||||
switch (this.getPhaseNo()) {
|
||||
case "0030":
|
||||
meagess=bo!=null?bo.getAttribute(VI_BUSINESS_APPROVAL.firstopinion).toString():"false";
|
||||
meagess=bo!=null?bo.getAttribute(VI_PROJECTINFO_APPROVAL.firstopinion).toString():"false";
|
||||
break;
|
||||
case "0040":
|
||||
meagess=meagess=bo!=null?bo.getAttribute(VI_BUSINESS_APPROVAL.secondopinion).toString():"false";;
|
||||
meagess=meagess=bo!=null?bo.getAttribute(VI_PROJECTINFO_APPROVAL.secondopinion).toString():"false";;
|
||||
break;
|
||||
case "0050":
|
||||
meagess=meagess=bo!=null?bo.getAttribute(VI_BUSINESS_APPROVAL.thirdopinion).toString():"false";;
|
||||
meagess=meagess=bo!=null?bo.getAttribute(VI_PROJECTINFO_APPROVAL.thirdopinion).toString():"false";;
|
||||
break;
|
||||
default:
|
||||
meagess="false";
|
||||
|
||||
@ -143,8 +143,8 @@ public class BusinessApproveManager {
|
||||
public String saveApproveOpinion(JBOTransaction tx){
|
||||
try{
|
||||
BizObjectManager bomFT = JBOFactory.getBizObjectManager(FLOW_TASK.CLASS_NAME,tx);
|
||||
BizObject boFT = bomFT.createQuery("objectno=:flowunid and phaseno=:phaseNo and serialno=:serialno and relativeobjectno is not null")
|
||||
.setParameter("flowunid", flowunid).setParameter("phaseNo", phaseNo).setParameter("serialno", serialNo).getSingleResult(true);
|
||||
BizObject boFT = bomFT.createQuery("objectno=:flowunid and phaseno=:phaseNo and relativeobjectno is not null")
|
||||
.setParameter("flowunid", flowunid).setParameter("phaseNo", phaseNo).getSingleResult(true);
|
||||
BizObjectManager bomFO = JBOFactory.getBizObjectManager(FLOW_OPINION.CLASS_NAME,tx);
|
||||
BizObject bo = bomFO.createQuery("serialno='"+serialNo+"'").getSingleResult(true);
|
||||
if(boFT != null){
|
||||
@ -154,7 +154,7 @@ public class BusinessApproveManager {
|
||||
bomFT.createQuery("update O set relativeobjectno='"+serialNo+"' where serialno='"+serialNo+"'").executeUpdate();
|
||||
bo.setAttributeValue(FLOW_OPINION.phaseopinion, phaseOpinion);
|
||||
bo.setAttributeValue(FLOW_OPINION.phasechoice, phaseChoice);
|
||||
bo.setAttributeValue(FLOW_OPINION.phaseopinion1, InterOpinion1);
|
||||
bo.setAttributeValue(FLOW_OPINION.InterOpinion1, InterOpinion1);
|
||||
bo.setAttributeValue(FLOW_OPINION.DistriOpinion1, DistriOpinion1);
|
||||
bo.setAttributeValue("InterOpinion2", InterOpinion2);
|
||||
bo.setAttributeValue("DistriOpinion2", DistriOpinion2);
|
||||
|
||||
@ -22,34 +22,41 @@ public class ApprovalOpinionCheck extends DefaultBussinessCheck{
|
||||
String flowunid=this.getAttribute("ObjectNo").toString();
|
||||
String phaseno=this.getAttribute("PhaseNo").toString();
|
||||
boolean flag = true;
|
||||
SqlObject so = new SqlObject("select ft.serialno,fo.phasechoice,fo.phaseopinion from flow_task ft left join flow_opinion fo on ft.relativeobjectno=fo.serialno where ft.objectno='"+flowunid+"' and ft.phaseno='"+phaseno+"' and ft.relativeobjectno is not null");
|
||||
ASResultSet result = Sqlca.getASResultSet(so);
|
||||
String sql="select case when ft.phaseno='0030' then case when fo.phasechoice is not null then 1 else 0 end when ft.phaseno='0040' then case when fo.phasechoice is not null then 1 else 0 end when ft.phaseno='0050' then case when fo.phasechoice is not null then 1 else 0 end else 99 end phasechoice,case when ft.phaseno='0030' then case when fo.phaseopinion is not null then 1 else 0 end when ft.phaseno='0040' then case when fo.phaseopinion is not null then 1 else 0 end when ft.phaseno='0050' then case when fo.phaseopinion is not null then 1 else 0 end else 99 end phaseopinion from flow_task ft left join flow_opinion fo on ft.relativeobjectno = fo.serialno "
|
||||
+" where ft.objectno = '"+flowunid+"' and ft.phaseno = '"+phaseno+"' and ft.serialno='"+serialno+"' and ft.relativeobjectno is not null";
|
||||
SqlObject so = new SqlObject(sql);
|
||||
ASResultSet result = Sqlca.getASResultSet(so);
|
||||
String phasechoice = "";
|
||||
String phaseopinion = "";
|
||||
while(result.next()){
|
||||
phasechoice = result.getString("phasechoice");
|
||||
phaseopinion = result.getString("phaseopinion");
|
||||
}
|
||||
String message = "";
|
||||
switch(phaseno){
|
||||
case "0030":
|
||||
message = "初审意见未填写!";
|
||||
if(!"1".equals(phasechoice)){
|
||||
message = "初审意见未填写!";
|
||||
flag = false;
|
||||
}
|
||||
break;
|
||||
case "0040":
|
||||
message = "复审意见未填写!";
|
||||
if(!"1".equals(phasechoice)){
|
||||
message = "复审意见未填写!"; flag = false;
|
||||
}
|
||||
break;
|
||||
case "0050":
|
||||
message = "部门负责人意见未填写!";
|
||||
if(!"1".equals(phasechoice)){
|
||||
message = "部门负责人意见未填写!"; flag = false;
|
||||
}
|
||||
break;
|
||||
// case "0050":
|
||||
// message = "总经理意见未填写!";
|
||||
// break;
|
||||
}
|
||||
String phasechoice = "";
|
||||
String phaseopinion = "";
|
||||
String deleteSerialno = "";
|
||||
while(result.next()){
|
||||
deleteSerialno = result.getString("serialno");
|
||||
phasechoice = result.getString("phasechoice");
|
||||
phaseopinion = result.getString("phaseopinion");
|
||||
}
|
||||
result.close();
|
||||
String thisResult = "";
|
||||
if(!"".equals(deleteSerialno)){
|
||||
//String thisResult = "";
|
||||
/* if(!"".equals(deleteSerialno)){
|
||||
thisResult = Sqlca.getString("select case when count(*)>0 then 'true' else 'false' end from flow_task where serialno='"+serialno+"' and phaseno='"+phaseno+"' and relativeobjectno is not null");
|
||||
if("false".equals(thisResult)){
|
||||
ASResultSet ars = Sqlca.getASResultSet(new SqlObject("select userid,orgid from flow_task where serialno='"+serialno+"'"));
|
||||
@ -69,13 +76,10 @@ public class ApprovalOpinionCheck extends DefaultBussinessCheck{
|
||||
}
|
||||
}else{
|
||||
flag = false;
|
||||
}
|
||||
if(flag && "true".equals(thisResult)){
|
||||
}*/
|
||||
if(flag ){
|
||||
putMsg("验证通过!");
|
||||
setPass(true);
|
||||
}else if(flag && "false".equals(thisResult)){
|
||||
putMsg("验证通过!但是意见使用的是退回前的意见!");
|
||||
setPass(true);
|
||||
}else{
|
||||
putMsg(message);
|
||||
setPass(false);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user