⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 office_document_sending_create.jsp

📁 非常完整的Java开发的网络办公系统
💻 JSP
📖 第 1 页 / 共 2 页
字号:
<%@ taglib uri="/vnex.tld" prefix="vnex" %>
<%@ taglib uri="/vnex_workflow.tld" prefix="vnex_workflow" %>
<%@ page errorPage="/vnex/ErrorPage.jsp" %>
<%@ page import="java.util.*" %>
<%@ page import="com.vnex.intranet.util.TimeStamp" %>
<%@ page import="com.vnex.intranet.workflow.document.value.*" %>
<%@ page import="com.vnex.intranet.workflow.util.*" %>
<%@ page import="com.vnex.intranet.workflow.pub.value.WorkflowFileValueBean" %>
<%@ page import="com.vnex.intranet.workflow.pub.value.SubTaskValueBean" %>
<%@ page import="com.vnex.intranet.workflow.loader.WorkflowLoader" %>
<%@ page import="com.vnex.intranet.util.*"%>
<%@ page import="com.vnex.intranet.system.loader.ConfigParaLoader"%>
<%@ page import="com.vnex.intranet.util.FieldUtil" %> 

<jsp:useBean id="BusinessName" scope="session" class="com.vnex.intranet.pub.BusinessSession" />
<jsp:useBean id="dsvb" scope="session" class="com.vnex.intranet.workflow.document.value.DocumentSendValueBean"/>
<jsp:useBean id="routeInfo" scope="session" class="com.vnex.intranet.workflow.pub.value.RouteValueBean" />
<%  
    // this attribute used by FileAttributeTag.java to change encode of chinese file name to view.
    pageContext.setAttribute("encodeFlag" , "false");
    if( request.getParameter("type") == null )
    {        
        dsvb = ( DocumentSendValueBean )session.getAttribute( "document" );
        String root = ConfigParaLoader.getParameter("rootUrl");
	    String attachURL =  ConfigParaLoader.getParameter("documentAttachmentUrl");
    
        Collection files = dsvb.getFiles();
        Iterator c = files.iterator();       
        while( c.hasNext() )
        {
            WorkflowFileValueBean wf = ( WorkflowFileValueBean )c.next();
            String ff = wf.getTitle();
            String sTitle = SubPathGenerater.copyFile( root + SubPathGenerater.getSeperator() + ff, SubPathGenerater.getSeperator() + root + SubPathGenerater.getSeperator() + attachURL );
            wf.setTitle( attachURL + "/" + sTitle );                            
        } 
        dsvb.setFiles( files );          
    }  
    if( request.getParameter("type") !=null && Integer.parseInt( request.getParameter("type") ) == 1 ) //上传文件
    {           
%>
<vnex_workflow:docfileupload />     
<% dsvb = ( DocumentSendValueBean )session.getAttribute( "document" ); 
   }
   if( request.getParameter("type") !=null && Integer.parseInt( request.getParameter("type") ) == 2 ) //Delete文件
   {          
%>
<vnex_workflow:docfileremove />     
<%
        dsvb = ( DocumentSendValueBean )session.getAttribute( "document" ); 
    }      
         
    routeInfo = dsvb.getRoute();
    ArrayList subtasks = routeInfo.getSubtaskList();
%>
<jsp:include page="/vnex/head.jsp"/>

<script language="JavaScript" src="/vnex/util/validate.js"></script>
<script language=JavaScript>
 
function createDoc( form, type )
{
   if(checkIt(form))
   {
      checkAll(document.forms[0].attachments);
      form.action="/mainctrl/office/document/sentcreateok?type=" + type;
      form.submit();
   }   
}

function uploadDoc(form)
{      
    form.action="/mainctrl/office/document/sentcreate?type=1";
    form.encoding="multipart/form-data";
    form.submit();     
}

function deleteDoc(form)
{      
    form.action="/mainctrl/office/document/sentcreate?type=2";    
    form.submit();     
}

function saveRoute(form)
{      
    if( checkSequence( form.stepNos ) )
    { 
        form.action="/mainctrl/office/document/routepersonalcreate";    
        form.submit();   
    }  
}

function checkIt(form)
{
   if(isEmpty(stripWhitespace(form.title.value)))
   {
      alert("请输入发文标题");
      form.title.focus();
      return false;
   }
   if( form.title.value.length >64 )
   {
      alert("发文标题长度不能超过64位.");
      form.title.focus();
      return false;
   }  
   
   if( form.description.value.length >400 )
   {
      alert("发文内容的长度不能超过400位.");
      form.description.focus();
      return false;
   } 
   if( form.keyword.value.length >400 )
   {
      alert("发文关键字的长度不能超过400位.");
      form.keyword.focus();
      return false;
   } 
   
   return checkSequence( form.stepNos ); 
      
   return true;
}  

function checkAll( selObj )
{
    for ( var i = 0; i < selObj.options.length; i++ )
       selObj.options[i].selected = true;
}

function addSub( form )
{
    form.action="/mainctrl/office/document/sentsubtaskcreate?isDocCreate=docCreate";
    form.submit();   
}
function deleteSub( myform )
{
   if( confirm( "确定要删除选择的子任务?" ) )
   {  
       myform.action="/mainctrl/office/document/sentsubtaskdelete?isDocCreate=docCreate";
       myform.submit();
   }
}

function modifySubtask(form,id)
{   
   form.action="/mainctrl/office/document/sentsubtaskmodify?subtaskId="+id+"&isDocCreate=docCreate";
   form.submit();      
}

function openAttach( mSelObj )
{    
    for( var i = 0; i < mSelObj.options.length; i++ )
    {
       var oriLen = mSelObj.options.length;
       if ( mSelObj.options[i].selected )
       {
           var eid = mSelObj.options[i].value;
           window.open( "/" + eid );
       }
    }
}
</script>
<script language="JavaScript" src="/vnex/intranet/workflow/util/checkRoute.js"></script>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<jsp:include page="/vnex/page/FORM_HEAD.jsp" />

<BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff topMargin=20 leftmargin="0" marginwidth="0" marginheight="0">

<script language="JavaScript1.2" src="/vnex/menu/dockmenu_office.js"></script>
<script language="JavaScript1.2" src="/vnex/menu/dockmenu.js"></script>

<SCRIPT>
window.onload=init
</SCRIPT>
<DIV align=center>
  <form name="myform" method="post" >
    <TABLE class=outter cellSpacing=0 cellPadding=0 width=600 border=0>
     <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
    <TR> 
        <TD colSpan=3 align="center">
          <br><!--个人信息开始 -->
          <table width="600" border="1" cellspacing="1" bordercolor="#666666">
            <tr bgcolor="#fafafa"> 
              <td bgcolor="#fafafa"> 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -