邮寄档案归档流程添加‘一键归档’按钮

This commit is contained in:
tangfutang 2019-12-11 15:11:22 +08:00
parent f83cef02be
commit 5a2b2828e9
4 changed files with 45 additions and 6 deletions

View File

@ -54,7 +54,9 @@
String sButtons[][] = {
{"true","All","Button","保存","保存所有修改","save()","","","",""},
{"false","All","Button","·µ»Ø","·µ»ØÁбí","returnList()","","","",""}
{"false","All","Button","返回","返回列表","returnList()","","","",""},
{"0020".equals(CurPage.getParameter("PhaseNo"))&&!"his".equals(type)?"true":"false","","Button","一键归档","一键归档","guidang()","","","",""},
};
// sButtonPosition = "south";
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
@ -79,5 +81,10 @@
//as_save(0,'frame_list.window.saveRecordForApprove()'); IE浏览器不起作用
as_save(0,'$("#frame_list")[0].contentWindow.saveRecordForApprove();');
}
function guidang(){
$("#frame_list")[0].contentWindow.guidang();
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -33,7 +33,8 @@
};
%><%@include file="/Frame/resources/include/ui/include_list.jspf"%>
<script type="text/javascript">
$(function(){
//$(function(){
function afterSearch(){
for(var i=0;i<getRowCount(0);i++){
if(getObj(0,i,"action")!=null&&getObj(0,i,"action")!="null"){
getObj(0,i,"action").innerHTML='<a class="box" onclick="viewAllInfo(\''+i+'\')" style={color:#000;text-decoration:underline;}><font color="blue">ÓʼÄÃ÷ϸ</font></a>';
@ -45,7 +46,8 @@
getObj(0,i,"filelist").innerHTML='<a class="box" onclick="viewOpinionFilelist(\''+i+'\')" style={color:#000;text-decoration:underline;}><font color="blue">ÀúÊ·¸½¼þ²é¿´</font></a>';
}
}
})
}
//})
function viewOpinionInfo(i){
var contract_id=getItemValue(0, i, "contract_id");
var sUrl = "/Tenwa/Apzl/FileUpload/LmApprovaloppinionDocTempList.jsp";

View File

@ -97,7 +97,7 @@
String sButtons[][] =null;
sButtons=new String[][]{
{"0010".equals(CurPage.getParameter("PhaseNo"))&&!"his".equals(type)?"true":"false","","Button","保存","保存所有修改","0010".equals(CurPage.getParameter("PhaseNo"))?"saveRecord()":"saveRecordForApprove()","","","",""},
{"0010".equals(CurPage.getParameter("PhaseNo"))&&!"his".equals(type)?"true":"false","","Button","保存","保存所有修改","0010".equals(CurPage.getParameter("PhaseNo"))?"saveRecord()":"saveRecordForApprove()","","","",""},
};
%>
@ -194,8 +194,11 @@ function saveRecordForApprove(){
var param="MailStatus="+MAILSTATUS+",libraryid="+id+",flowunid=<%=flowunid%>,AllStatus="+allstatus+",contractid=<%=contract_id%>";
var str=RunJavaMethodTrans("com.tenwa.lease.flow.project.businessapply.DocMailAction","asSaveHandOverStatus",param);
}
var str=RunJavaMethodTrans("com.tenwa.lease.flow.project.businessapply.DocMailAction","SaveHandOverStatus",param);
location.reload();
alert('保存成功!');
parent.AsDialog.ClosePage();
}
//在加载完表格后调用
function afterSearch(){
@ -310,5 +313,13 @@ function deleteFile(id){
}
}
function guidang(){
for(var i=0;i<getRowCount(0);i++){
$("#INPUT_myiframe0_HANDOVERSTATUS_"+i+"_5").val('all');//设置value为xx的option选项为默认选中
setItemValue(0,i,"HANDOVERSTATUS","all");
}
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>

View File

@ -115,16 +115,35 @@ public class DocMailAction {
}
public String asSaveHandOverStatus(JBOTransaction tx) throws JBOException{
BizObjectManager lfmitBom = JBOFactory.getBizObjectManager(LM_MAILONLINE_DOC_TEMP.CLASS_NAME, tx);
BizObjectManager lfmiBom = JBOFactory.getBizObjectManager(LB_FILE_MAILARCHIVING_INFO_TEMP.CLASS_NAME, tx);
//BizObjectManager lfmiBom = JBOFactory.getBizObjectManager(LB_FILE_MAILARCHIVING_INFO_TEMP.CLASS_NAME, tx);
if("all".equals(MailStatus)){
lfmitBom.createQuery("update O set HANDOVERSTATUS = '"+MailStatus+"',attribute1 = '1' where flowunid='"+flowunid+"' and libraryid='"+libraryid+"'").executeUpdate();
}else{
lfmitBom.createQuery("update O set HANDOVERSTATUS = '"+MailStatus+"',attribute1 = '' where flowunid='"+flowunid+"' and libraryid='"+libraryid+"'").executeUpdate();
}
lfmiBom.createQuery("update O set ALLHANDOVERSTATUS = '"+AllStatus+"' where flowunid='"+flowunid+"' and contract_id='"+contractid+"'").executeUpdate();
//lfmiBom.createQuery("update O set ALLHANDOVERSTATUS = '"+AllStatus+"' where flowunid='"+flowunid+"' and contract_id='"+contractid+"'").executeUpdate();
return "success";
}
public String SaveHandOverStatus(JBOTransaction tx) throws JBOException{
BizObjectManager lfmitBom = JBOFactory.getBizObjectManager(LM_MAILONLINE_DOC_TEMP.CLASS_NAME, tx);
BizObjectManager lfmiBom = JBOFactory.getBizObjectManager(LB_FILE_MAILARCHIVING_INFO_TEMP.CLASS_NAME, tx);
List<BizObject> alllmdt = lfmitBom.createQuery(" flowunid=:flowunid and contract_id=:contractId and HANDOVERSTATUS='all' ").setParameter("flowunid", flowunid).setParameter("contractId", contractid).getResultList(false);
List<BizObject> nonelmdt = lfmitBom.createQuery(" flowunid=:flowunid and contract_id=:contractId and HANDOVERSTATUS='none' ").setParameter("flowunid", flowunid).setParameter("contractId", contractid).getResultList(false);
String handSql = "update O set ALLHANDOVERSTATUS = '";
if(alllmdt.size()>0&&nonelmdt.size()>0){
handSql = handSql+"part";
}else if(alllmdt.size()==0&&nonelmdt.size()>0){
handSql = handSql+"none";
}else if(alllmdt.size()>0&&nonelmdt.size()==0){
handSql = handSql+"all";
}else{
handSql = handSql+"null";
}
lfmiBom.createQuery(handSql+"' where flowunid='"+flowunid+"' and contract_id='"+contractid+"'").executeUpdate();
return "success";
}
public String saveERPInfo(JBOTransaction tx) throws JBOException{
BizObjectManager lfmiBom = JBOFactory.getBizObjectManager(LB_FILE_MAILARCHIVING_INFO_TEMP.CLASS_NAME, tx);
// String[] contractidlist = contractid.split("@");