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

📄 wageadd.asp

📁 目前人力资源管理系统的发展已经相对成熟
💻 ASP
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file=DataBase/conn.asp-->
<!--#include file=yan.asp-->
<!--#include file=purview.asp-->
<%
call xinchoudengji
	if request("post")<>"" then
	if request("name")="" then
	response.Write("<script language=javascript>alert('请选择一个员工');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("name")="1" then
	response.Write("<script language=javascript>alert('员工不能为首席执行官');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("gongzuo")="" then
	response.Write("<script language=javascript>alert('工作日数不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("rixin")="" then
	response.Write("<script language=javascript>alert('日薪不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("benxin")="" then
	response.Write("<script language=javascript>alert('本薪不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("jiangjin")="" then
	response.Write("<script language=javascript>alert('奖金不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("jiari")="" then
	response.Write("<script language=javascript>alert('假日津贴不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("quanqin")="" then
	response.Write("<script language=javascript>alert('全勤奖金不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("jiaban")="" then
	response.Write("<script language=javascript>alert('加班津贴不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("benqi")="" then
	response.Write("<script language=javascript>alert('本期工资不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("fuli")="" then
	response.Write("<script language=javascript>alert('福利金不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("huoshi")="" then
	response.Write("<script language=javascript>alert('伙食费不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("suode")="" then
	response.Write("<script language=javascript>alert('所得税不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("jiezhi")="" then
	response.Write("<script language=javascript>alert('借支不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	if request("shifa")="" then
	response.Write("<script language=javascript>alert('实发工资不能为空');location='javascript:history.go(-1)'</script>")
	response.End()
	end if
	'检测是否有重复
		set rsj=server.CreateObject("adodb.recordset")
	sqlj="select * from tb_Wage"
	rsj.open sqlj,conn,1,3
	
	set rsj=server.CreateObject("adodb.recordset")
	sqlj="select * from tb_Wage"
	rsj.open sqlj,conn,1,3
	rsj.addnew
	rsj("name")=request("name")
	rsj("year")=request("year")
	rsj("month")=request("month")
	rsj("gongzuo")=request("gongzuo")
	rsj("rixin")=request("rixin")
	rsj("benxin")=request("benxin")
	rsj("jiangjin")=request("jiangjin")
	rsj("jiari")=request("jiari")
	rsj("quanqin")=request("quanqin")
	rsj("jiaban")=request("jiaban")
	rsj("benqi")=request("benqi")
	rsj("fuli")=request("fuli")
	rsj("huoshi")=request("huoshi")
	rsj("suode")=request("suode")
	rsj("jiezhi")=request("jiezhi")
	rsj("shifa")=request("shifa")
	rsj.update
	rsj.close
	response.Write("<script language=javascript>alert('登记成功!')</script>")
	end if
	
    set rs=server.CreateObject("adodb.recordset")
	sql="Select * from tb_dept order by up"
	rs.Open sql,conn,1,1

	if request("suoshu")<>"" then
	suoshu=request("suoshu")
	else
    suoshu=1
	end if
	set rsr=server.CreateObject("adodb.recordset")
	sqlr="select * from tb_Employee where suoshu="&suoshu
	rsr.open sqlr,conn,1,1


%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<style type="text/css">
<!--
.style2 {color: #0000FF}
.style3 {color: #FF0000}
body,td,th {
	font-size: 12px;
}
-->
</style>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
//-->
</script>
<link href="CSS/css.css" rel="stylesheet" type="text/css">
</head>

<body topmargin="0">
<form name="form1" method="post" action="">
  <table width="550" border="0" align="center">
    <tr>
      <td width="55%" height="30"> -&nbsp;<span class="style2">薪水管理</span>→<span class="style3">薪水登记</span></td>
    </tr>
  </table>

  <table width="438" border="0" align="center" cellspacing="1" bgcolor="#000000">
    <tr>
      <td bgcolor="#FFFFFF">
	  <table width="438" height="436" border="0" align="center" cellspacing="0" >
      <tr>
      <td width="90" height="31" align="center" background="images/index_24.gif">  部  门:</td>
      <td width="151" background="images/index_24.gif"> 
        <select name="menu1" onChange="MM_jumpMenu('self',this,0)">
          <%
  do while not rs.eof

  	   xian=""
	for i=1 to rs("level")-1
		xian = xian&"├"
	next
	xian = xian&"〖"&trim(rs("title"))&"〗<br>"  
  %>
        <option value="wageadd.asp?suoshu=<%=rs("id")%>" <%if rs("id")=clng(request("suoshu")) then%>selected<%end if%>><%=xian%></option>
      <%

  rs.movenext
  loop
  %>
      </select>
        <input name="post" type="hidden" id="post" value="true"></td>
      <td width="56" align="center" background="images/index_24.gif">员工:</td>
      <td width="113" background="images/index_24.gif"> 
        <select name="name" id="name">
        <%do while not rsr.eof %>
        <option value="<%=rsr("id")%>"><%=rsr("name")%></option>
        <%
	rsr.movenext
	loop
	%>
      </select></td>
    </tr>
    <tr>
      <td align="center">日  期:</td>
      <td colspan="3">         <select name="year" id="year">
	  <%for i=2005 to 2050%>
        <option value="<%=i%>"><%=i%></option>
		<%next%>
      </select>
        <select name="month" id="month">
		<%for i=1 to 12%>
          <option value="<%=i%>"><%=i%></option>
		  <%next%>
        </select>
      月</td>
    </tr>
    <tr>
      <td align="center">工作日数:</td>
      <td colspan="3">         <input name="gongzuo" type="text" class="wenben" id="gongzuo" size="10" maxlength="10">
      天</td>
    </tr>
    <tr>
      <td align="center">日  薪:</td>
      <td colspan="3">         <input name="rixin" type="text" class="wenben" id="rixin" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">本  薪:</td>
      <td colspan="3">         <input name="benxin" type="text" class="wenben" id="benxin" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">奖  金:</td>
      <td colspan="3">         <input name="jiangjin" type="text" class="wenben" id="jiangjin" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">假日津贴:</td>
      <td colspan="3">         <input name="jiari" type="text" class="wenben" id="jiari" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">全勤奖金:</td>
      <td colspan="3">         <input name="quanqin" type="text" class="wenben" id="quanqin" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">加班津贴:</td>
      <td colspan="3">         <input name="jiaban" type="text" class="wenben" id="jiaban" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">本期工资:</td>
      <td colspan="3">         
      <input name="benqi" type="text" class="wenben" id="benqi" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">福 利 金:</td>
      <td colspan="3">         <input name="fuli" type="text" class="wenben" id="fuli" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">伙 食 费:</td>
      <td colspan="3">         <input name="huoshi" type="text" class="wenben" id="huoshi" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">所 得 税:</td>
      <td colspan="3">         <input name="suode" type="text" class="wenben" id="suode" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">借  支:</td>
      <td colspan="3">         <input name="jiezhi" type="text" class="wenben" id="jiezhi" size="10" maxlength="10">
      元</td>
    </tr>
    <tr>
      <td align="center">实发工资:</td>
      <td colspan="3">         <input name="shifa" type="text" class="wenben" id="shifa" size="10" maxlength="10">
      元</td>
    </tr>
    <tr align="center">
      <td colspan="4"><input name="Submit" type="submit" class="botton" value=" 提 交 ">
       
        <input name="Submit2" type="reset" class="botton" value=" 重 置 "></td>
    </tr>
  </table>
	  </td>
    </tr>
  </table>
</form>
</body>
</html>

⌨️ 快捷键说明

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