📄 addchangjob.asp
字号:
<%@ LANGUAGE = VBScript %>
<!--#include file="asp/sqlstr.asp"-->
<!--#include file="asp/opendb.asp"-->
<!--#include file="asp/checked.asp"-->
<!--#include file="asp/keepformat.asp"-->
<%
'-----------------------------------------
oabusyname=request.cookies("oabusyname")
oabusyusername=request.cookies("oabusyusername")
oabusyuserdept=request.cookies("oabusyuserdept")
oabusyuserlevel=request.cookies("oabusyuserlevel")
if oabusyusername="" then
response.write("<script language=""javascript"">")
response.write("window.top.location.href='default.asp';")
response.write("</script>")
response.end
end if
'--------------------------------------
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<link rel="stylesheet" href="css/css.css">
<script language="javascript1.2" src="js/openwin.js"></script>
<SCRIPT language=javascript>
<!--
if (window.Event)
document.captureEvents(Event.MOUSEUP);
function nocontextmenu() {
event.cancelBubble = true
event.returnvalue = false;
return false;
}
function norightclick(e) {
if (window.Event) {
if (e.which == 2 || e.which == 3)
return false;
} else if (event.button == 2 || event.button == 3) {
event.cancelBubble = true
event.returnvalue = false;
return false;
}
}
document.oncontextmenu = nocontextmenu; // for IE5+
document.onmousedown = norightclick; // for all others
//-->
</SCRIPT>
<title>OA办公系统</title>
<style type="text/css">
<!--
.style2 {color: #0d79b3;
font-weight: bold;
}
.style7 {color: #2d4865}
-->
</style>
</head>
<body topmargin="0" leftmargin="0">
<table width="583" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="21"><div align="center">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="2" height="25"><span class="style2"><img src="images/main/l3.gif" width="2" height="25"></span></td>
<td background="images/main/m3.gif"><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="21"><div align="center"><span class="style2"><img src="images/main/icon.gif" width="15" height="12"></span></div></td>
<td class="style7">员工管理</td>
</tr>
</table></td>
<td width="1"><span class="style2"><img src="images/main/r3.gif" width="1" height="25"></span></td>
</tr>
</table>
<font color="0D79B3"></font></div></td>
</tr>
</table>
<%
'打开数据库读出用户名
set conn=opendb("oabusy","conn","accessdsn")
set rs=server.createobject("adodb.recordset")
sql="select name from userinf where username=" & sqlstr(request("username"))
rs.open sql,conn,1
name=rs("name")
%>
<center>
<br>
<table>
<tr>
<td> 增加<%=name%>的职位变动信息 </td>
<form method="post" action="jobchanginf.asp" name="form2"><td>
<input type="hidden" name="userdept" value="<%=request("userdept")%>">
<input type="hidden" name="username" value="<%=request("username")%>">
<input type="submit" value="返回">
</td>
</form>
</tr>
</table>
</center>
<%
if request("submit")="增加" then
username=request("username")
oldjob=request("oldjob")
changjob=request("changjob")
changdate=request("changdate")
changfile=request("changfile")
changsort=request("changsort")
changtype=request("changtype")
changreason=request("changreason")
recusername=oabusyname
updateusername=oabusyname
set conn=opendb("oabusy","conn","accessdsn")
sql = "Insert Into changjob (username,oldjob,changjob,changdate,changfile,changsort,changtype,changreason,recusername,updateusername) Values( "
sql = sql & SqlStr(username) & ", "
sql = sql & SqlStr(oldjob) & ", "
sql = sql & SqlStr(changjob) & ", "
sql = sql & SqlStr(changdate) & ", "
sql = sql & SqlStr(changfile) & ", "
sql = sql & SqlStr(changsort) & ", "
sql = sql & SqlStr(changtype) & ", "
sql = sql & SqlStr(changreason) & ", "
sql = sql & SqlStr(recusername) & ", "
sql = sql & SqlStr(updateusername) & ")"
conn.Execute sql
%>
<br><br>
<center><font color=red >成功增加员工职务变动信息!</font></center>
<%
else
%>
<script Language="JavaScript">
function form_check(){
var l1=document.form1.oldjob.value;
if(l1==""){window.alert("原职务必须填写!");document.form1.oldjob.focus();return (false);}
var l2=document.form1.changjob.value;
if(l2==""){window.alert("变动职务必须填写!");document.form1.changjob.focus();return (false);}
var l3=document.form1.changdate.value;
if(l3==""){window.alert("变动时间必须填写!");document.form1.changdate.focus();return (false);}
}
</script>
<br>
<center>
<form method="post" action="addchangjob.asp" name="form1" onsubmit="return form_check();">
<table border="0" cellpadding="4" cellspacing="0" width="540">
<tr>
<td height="25" width="15%" style="border-left: 2 solid #B0C8EA; border-top: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" align="center">员工姓名</td>
<td colspan="3" width="85%" style="border-left: 1 solid #B0C8EA; border-right: 2 solid #B0C8EA; border-top: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA"><%=name%>
</td>
</tr>
<tr>
<td width="15%" style="border-left: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" align="center">原 职 务</td>
<td width="35%" style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="oldjob" size=10>
<font color=red>*</font> </td>
<td width="15%" style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" align="center">变动职务</td>
<td width="35%" style="border-left: 1 solid #B0C8EA; border-right: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="changjob" size=10>
<font color=red>*</font> </td>
</tr>
<tr>
<td style="border-left: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" width="15%" align="center">变动时间</td>
<td style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="changdate" size=10>
<font color=red>*</font> </td>
<td style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" width="15%" align="center">变动文号</td>
<td style="border-left: 1 solid #B0C8EA; border-right: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="changfile" size=10>
</td>
</tr>
<tr>
<td style="border-left: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" width="15%" align="center">变动类型</td>
<td style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="changsort" size=10>
</td>
<td style="border-left: 1 solid #B0C8EA; border-bottom: 1 solid #B0C8EA" width="15%" align="center">变动方式</td>
<td style="border-left: 1 solid #B0C8EA; border-right: 2 solid #B0C8EA; border-bottom: 1 solid #B0C8EA">
<input type="text" name="changtype" size=10>
</td>
</tr>
<tr>
<td width="15%" style="border-left: 2 solid #B0C8EA; border-bottom: 2 solid #B0C8EA" align="center">变动原因<br>
备注说明</td>
<td colspan="3" width="85%" style="border-left: 1 solid #B0C8EA; border-right: 2 solid #B0C8EA; border-bottom: 2 solid #B0C8EA">
<textarea rows="3" name="changreason" cols="46"></textarea>
</td>
</tr>
</table>
<br>
<input type="hidden" name="userdept" value="<%=request("userdept")%>">
<input type="hidden" name="username" value="<%=request("username")%>">
<font color=red>*</font>为必填项 <input type="submit" name="submit" value="增加">
</form>
</center>
<%
end if
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -