fenfa.asp
来自「功能非常强大的一款办公自动化软件原代码,其中的文档签收功能特别实用.不相信下下来」· ASP 代码 · 共 259 行
ASP
259 行
<!--#include file="check.asp"-->
<!--#INCLUDE FILE="connect.asp" -->
<html>
<head>
<title>公文归档</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<% if Request.ServerVariables("Request_Method")="POST" and request("flag")="2" then
set bzwb=server.createobject("oaserver.fenfa")
bzwb.main(conn)
response.write("<script language=javascript>alert('公文归档完成!')</script>")
response.write("<script>document.location='right.asp'</script>")
response.end
end if
LocalFile="fenfa.asp"
DocFile="loadhg.asp"
SaveFile="savehg.asp"
PsoFile="loadpso.asp"
HttpUrl="http://" & Request.ServerVariables("HTTP_HOST") & Request.ServerVariables("SCRIPT_NAME")
HttpUrl=Left(HttpUrl,Len(HttpUrl)-Len(LocalFile))
DocUrl=HttpUrl & DocFile
SaveUrl=HttpUrl & SaveFile
PsoUrl=HttpUrl & PsoFile
%>
<script language="JavaScript" src="fawen.js"></script>
<script language="JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
// -->
function checkform() {
FileName=document.form.opendoc.value
if (form.hiddenselect.value=="") {
if (!confirm("您没有选择收文人,您确定要继续吗?"))
{return false}
}
if (!confirm("您确定要归结公文吗?"))
{return false;}
else {
if(FileName!="") { //如果修改公文则保存公文
SaveUrl="<%=SaveUrl%>"
FileSize="<%=session("MaxSize")%>"
FilePath="" //为空表示文件在默认位置
result=form.web.upload(SaveUrl,FileName,FilePath,FileSize) //上传公文到数据库
if (!result)
{
alert("找不到公文或与服务器连接失败!")
return false;
} //公文上传失败,返回起草公文页面
form.web.delfile() //删除临时文件
} //上传公文完毕
}
}
function sendback(flowid1) {
if (confirm("您确定要把这稿件返回给拟稿人重新拟稿吗?"))
document.location="sendback.asp?flowid="+flowid1
}
</script>
<link rel="stylesheet" href="fawen.css" type="text/css">
</head>
<!--#include file="checkuser.asp"-->
<body LEFTMARGIN="0" TOPMARGIN="0" MARGINWIDTH="0" MARGINHEIGHT="0" oncontextmenu="return false">
<%
if CLng(request("flowid"))="" then response.end
nwid=CLng(request("nwid"))
flowid=CLng(request("flowid"))
session("fawenid")=flowid
set rs=server.createobject("adodb.recordset")
sql="select * from fawen where id="&flowid
rs.open sql,conn,1,1
if rs.eof then
response.redirect "error.htm"
response.end
end if
DocumentName=rs("DocumentName")
%>
<form name="form" method="POST">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr height="25" valign="middle">
<td valign="middle" height="50" align="center"> <img src="images/gwgd.gif" width="113" height="25"></td>
<td height="50" valign="top" align="left"> </td>
</tr>
<tr height="25">
<td valign="top" align="center" >
<table width="100%" border="0" cellspacing="1" cellpadding="2" bgcolor="990000">
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" width="46%"> 文 号: <font class="bblue"><%=rs("wenhao")%></font></td>
<td height="35" width="27%"> 密 级: <font class="bblue"><%=rs("miji")%></font></td>
<td height="35" width="27%"> 保密期限: <font class="bblue"><%=rs("baomiqx")%></font></td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" width="46%"> 缓 急: <font class="bblue"><%=rs("huanji")%></font>
</td>
<td height="35" colspan="2"> 定密依据: <font class="bblue"><%=rs("dingmiyj")%></font>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="top">
<td height="60" width="46%">
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
<tr bgcolor="ffffff">
<td valign="top" width="27%" bgcolor="f5f5f5"> 核稿意见: </td>
<td valign="top" width="73%" bgcolor="f5f5f5"><font class="bblue"><%=rs("name_hg")%></font></td>
</tr>
</table>
</td>
<td height="60" colspan="2">
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
<tr>
<td valign="top" width="24%"> 审核意见:</td>
<td valign="top" width="76%"><font class="bblue"><%=rs("name_sh")%></font></td>
</tr>
</table>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="top">
<td height="60" width="46%">
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
<tr>
<td width="27%" valign="top"> 签 发:</td>
<td width="73%" valign="top"> <font class="bblue"><%=rs("name_qf")%></font>
</td>
</tr>
</table>
</td>
<td height="60" colspan="2">
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
<tr>
<td valign="top" width="24%"> 会 签:</td>
<td valign="top" width="76%"><font class="bblue"><%=rs("name_hq")%></font></td>
</tr>
</table>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" colspan="3"> 主 送: <font class="bblue"><%=rs("mainsend")%></font>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" colspan="3"> 抄 送: <font class="bblue"><%=rs("tosend")%></font>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" width="46%"> 拟稿单位:<font class="bblue"><%=rs("writedep")%></font></td>
<td height="35" width="27%"> 拟 稿 人:<font class="bblue"><%=rs("writename")%></font></td>
<td height="35" width="27%"> 核 稿 人:<font class="bblue"><%=rs("hegaoname")%></font></td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" width="46%"> 印 制:<font class="bblue"><%=session("username")%></font>
</td>
<td height="35" width="27%"> 校 对:<font class="bblue"><%=session("username")%></font>
</td>
<td height="35" width="27%"> 份 数:<font class="bblue"><%=rs("copy")%></font>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" width="46%"> 附 件:
<%fujianname=rs("fujianname")
if fujianname<>"" then
response.write "<a href='"&PsoUrl&"' target='_blank'>"&fujianname&"</a>"
end if
%>
</td>
<td height="35" colspan="2"> 公文正文: <a href="readword.asp" onClick="return OpenWindows('this.href')"><%=rs("documentname")%></a></td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" colspan="3"> 标 题: <font class="bblue"><%=rs("title")%></font>
</td>
</tr>
<tr bgcolor="f5f5f5" valign="middle">
<td height="35" colspan="3"> 主 题 词: <font class="bblue"><%=rs("keywords")%></font>
</td>
</tr>
</table>
</td>
<td valign="top" align="center" width="180" height="25" >
<!--#include file="turnmorefawen.asp"-->
</td>
</tr>
<tr>
<td valign="bottom" height="35" class="bblue" align="center">
收文登记员:
<input readonly class=lineinput type="text" name="username" size="20" maxlength="20" onClick="checkpeople()" style="cursor:hand;" title="点击选择收文人员">
<input type="image" name="send" value="公文归档" onClick="return checkform();return false;" src="images/guidanggif.gif" alt="公文归档">
<input type="image" name="send22" value=" 打 印 " onClick="window.print();return false;" src="images/printgif.gif" alt="打印">
<input type="image" name="send2" value=" 返 回 " onClick="history.go(-1);return false;" src="images/fanhuigif.gif" alt="返回">
</td>
<td valign="bottom" height="35">
<input type="hidden" name="hiddenselect">
<input type="hidden" name="hiddennum" value="0">
<input type="hidden" name="single" value="single">
<input type="hidden" name="flag" value="2">
<input type="hidden" name="flowid" value="<%=request("flowid")%>">
<input type="hidden" name="nwid" value="<%=request("nwid")%>">
<input type="hidden" name="opendoc">
</td>
</tr>
<tr>
<script language=javascript>
</script>
<td valign="top" height="25" colspan="3" >
<object classid="clsid:8C9AA244-AC33-47F9-8968-CC114654A6EC" codebase="web.ocx" id="web" width="1" height="1">
<param name="_ExtentX" value="847">
<param name="_ExtentY" value="847">
</object> </td>
</tr>
</table>
</form>
<%rs.close
set rs=nothing
conn.close
set conn=nothing
%>
<script language=javascript>
function OpenWindows() //下载打开公文函数
{
var DocumentName="<%=DocumentName%>"
if(document.form.opendoc.value=="") //如果ckicknum的值为空说明还没有下载公文
{
var result
HTTPURL="<%=DocUrl%>"
result=form.web.download(HTTPURL,DocumentName); //判断下载文件是否成功
if (!result)
{
alert("打开公文失败,请与管理员联系!")
return false;
}
else {
document.form.opendoc.value=DocumentName
}
}
var url="readwordff.asp?documentname="+DocumentName //调用writeword.asp来打开文件
OpenWord(url)
return false;
}
</script>
</body>
</html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?