?? doclist.jsp
字號:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*,java.util.*"%>
<jsp:useBean id="docBList" class="com.csbook.documentsystem.DocBaseMan" scope="page"/>
<jsp:useBean id="docList" class="com.csbook.documentsystem.DocMan" scope="page"/>
<jsp:useBean id="ce" class="com.csbook.documentsystem.ChangeEncoding" scope="page"/>
<html>
<head>
<title>電子政務檔案管理系統</title>
<script language="javascript" src="tools.js"></script>
</head>
<body>
<%
String docBase=request.getParameter("docBase");
if(docBase==null)
{
ArrayList docBases=docBList.getDocBaseList();
Iterator it=docBases.iterator();
%>
<form name="form1" method="get" action="doclist.jsp">
請選擇檔案庫:
<select name="docBase">
<%
while(it.hasNext()){
%>
<option>
<%=(String)it.next()%>
</option>
<%
}
%>
</select>
<input type="submit" name="Submit" value="進入">
</form>
<%
}
else
{
String operator=(String)session.getAttribute("userId");
if(!docBList.isWritableForDocBase(docBase,operator))
{
%>
<jsp:forward page="err.jsp?err=您沒有權限管理該檔案庫"/>
<%
}
ArrayList docBaseOption=docBList.getDocBaseList();
Iterator itOption=null;
%>
<div align="center">
<table width="90%" border="1">
<tr>
<td width="261"><div align="center">檔案名稱</div></td>
<td width="79"><div align="center">機構</div></td>
<td width="61"><div align="center">年度</div></td>
<td width="272"><div align="center">操作</div></td>
</tr>
<%
ArrayList docs=docList.getDocList(0,"","",0,"",docBase);
Iterator it=docs.iterator();
StringTokenizer st=null;
String tempName,tempId;
while(it.hasNext())
{
st=new StringTokenizer((String)it.next());
tempId=st.nextToken();
tempName=st.nextToken();
st.nextToken();
%>
<tr>
<td height="47">
<div align="center"><%=tempName%></div></td>
<td><div align="center"><%=st.nextToken()%></div></td>
<td><div align="center"><%=st.nextToken()%></div></td>
<td><div align="center">
<form name="form1" method="get" action="action.jsp">
<p>存到檔案庫
<select name="todocBase">
<%
itOption=docBaseOption.iterator();
while(itOption.hasNext()){
%>
<option><%=(String)itOption.next()%></option>
<%
}
%>
</select>
<input type="hidden" name="op" value="changeDocBase">
<input type="hidden" name="docid" value="<%=tempId%>">
<input type="submit" name="Submit" value="執行">
</p>
<p><a href="javascript:doWhenConfirm('確定要刪除檔案<%=tempName%>嗎?','action.jsp?op=delDoc&id=<%=tempId%>')">刪除</a>
<a href="docinfo.jsp?id=<%=tempId%>">歸檔</a>
</p>
</form>
</div></td>
</tr>
<%
}
%>
</table>
</div>
<p align="center"><a href="addDocument.jsp?docBase=<%=ce.changeCharset(docBase)%>">在<%=ce.changeCharset(docBase)%>檔案庫中增加檔案</a></p>
<%}%>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -