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

📄 employeesalarymodule.asp

📁 一个VB的p2p聊天系统
💻 ASP
字号:
<!--#include file="headfiles/Connection.inc"-->
<%
dim DepartID,level,DID,intOpt
DepartID=request.Form("txtDepart")
'response.Write(intOpt)
if DepartID="" or DepartID="1" then
	DID=""
	level=0
	DepartID=1
else
	level=cint(left(DepartID,1))
	DID=cint(right(DepartID,len(DepartID)-1))
end if
'response.Write("  DepartID="&DepartID&"  level="&level&"  Did="&did)
'response.Write(level&"...."&DepartID&"...."&len(DepartID))
dim rsDepart1,rsDepart2,rsDepart3,rsDepartDetail,rsSModule
set rsDepart1=server.CreateObject("adodb.recordset")
set rsDepart2=server.CreateObject("adodb.recordset")
set rsDepart3=server.CreateObject("adodb.recordset")
strSql="select * from Depart1Table order by Depart_ID"
rsDepart1.open strSql,conn,3,1
strSql="select * from Depart2Table order by Depart_Super"
rsDepart2.open strSql,conn,3,1
strSql="select * from Depart3Table order by Depart_Super"
rsDepart3.open strSql,conn,3,1
set rsSModule=server.CreateObject("adodb.recordset")
strSql="select * from SalaryModuleTable"
rsSModule.open strSql,conn,3,1
set rsDepartDetail=server.CreateObject("adodb.recordset")
if DepartID="" or DepartID="1" then
	strSql="select * from EmployeeSalaryView"
else
	strSql="select * from EmployeeSalaryView where Employee_Depart"&level&"="&DID
end if
rsDepartDetail.open strSql,conn,3,1
'response.Write(rsDepart1.recordcount&rsDepart2.recordcount&rsDepart3.recordcount)
'<a onmouseover="this.className='red'" onmouseout="this.className='detail'"></a>
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<SCRIPT language=javascript src="headfiles/PicTree.js"></SCRIPT>
<title>无标题文档</title>
<link href="headfiles/text.css" rel="stylesheet" type="text/css">
<script language="JavaScript">
function DoClick1(id){
	DoClick(id);
//	var level;
//	level=id.substring(0,1);
//	if(level=3){
//		frmDepart.btnNew.disabled=true;
//	}else{
//		frmDepart.btnNew.disabled=false;
//	}
	frmESM.txtDepart.value=id;
	frmESM.submit();
}

function ModifySM(id,smid){
	window.open("ModifyESM.asp?id="+id+"&smid="+smid,"newESM","width=500px; height=300px; left=10px; top=10px");
}
</script>
</head>
<body background="images\bg.gif" class="detail2" style="CURSOR:AUTO" bottommargin="0" leftmargin="0" rightmargin="0" topmargin="0">
<table width="580" border="0" cellpadding="0" cellspacing="0">
<form id="frmESM" name="frmESM" method="post" action="EmployeeSalaryModule.asp">
	<tr><td width="160" height="390" valign="top" bgcolor="#66CCFF">
		<table width="150" height="10" border="0" cellpadding="0" cellspacing="0" class="title3">
		  <tr> 
			<td width="42" height="24"><a class=Parent id=1  style="CURSOR: hand" onClick="ExpandCollapse(1)"><img id=image1 height=22 
					src="./images/Ftv2mNode.gif" width=16 border=0 isopen="0"></a><img 
					class=classlogo id=folder1 height=22 src="./images/ftv2folderclosed.gif" width=24 border=0 clid="1"></td>
			<td width="158"><a class=bold id=1  style="CURSOR: hand" onClick="DoClick1('1')" target=""><span 
				  id=folder1d onMouseOver="this.className='red1'" onMouseOut="this.className=''">本公司</span></a>
				<input type="text" id="txtDepart" name="txtDepart" style="width:20px;visibility:hidden">
		</td>
		  </tr>
		 <tr> 
			<td colspan="2" id="child1">
			  <table width="100%" height="20" border="0" cellpadding="0" cellspacing="0" class="title3">
		<%
			dim intCount,end1,end2,end3,intCount3
			end1=0
			end2=0
			end3=0
			intCount=1
			do while not rsDepart1.eof
			if rsDepart1.recordcount=intCount then
				end1=1
			end if
			end2=0
			end3=0
		%>
				<tr> 
				  <td width="60" height="20"><img height=22 src="./images/blank.gif" width=16 border=0><%if rsDepart1("Depart_Sub")<>0 then %><a class=Parent
				   id=1<%=rsDepart1("Depart_ID")%> style="CURSOR: hand" onClick=ExpandCollapse(1<%=rsDepart1("Depart_ID")%>)><img id=image1<%=rsDepart1("Depart_ID")%> height=22 
					src="./images/Ftv2mNode.gif" width=16 border=0 isopen="0"></a><% else  if  end1=1 then
					%><img src="images/ftv2Lastnode.gif" width=16 border=0><% else %><img src="images/ftv2node.gif" width=16 border=0><%end if
					end if %><img class=classlogo id=folder1<%=rsDepart1("Depart_ID")%> height=22 
					src="./images/ftv2folderclosed.gif" width=24 border=0 clid="1<%=rsDepart1("Depart_ID")%>"></td>
				  <td width="110"><a class=bold id=1<%=rsDepart1("Depart_ID")%> style="CURSOR: hand" onClick="DoClick1('1<%=rsDepart1("Depart_ID")%>')" target="">
				  <span id=folder1<%=rsDepart1("Depart_ID")%>d onMouseOver="this.className='red1'" onMouseOut="this.className=''"><%=rsDepart1("Depart_Name")%></span></a></td>
				</tr>
			<%
				if rsDepart1("Depart_Sub")<>0 then
			%>
				<tr> 
				  <td colspan="2" id="child1<%=rsDepart1("Depart_ID")%>">
				  <table width="100%" height="20" border="0" cellpadding="0" cellspacing="0" class="title2">
				<%
					rsDepart2.movefirst
					do while not rsDepart2.eof
						end3=0
						if rsDepart2("Depart_Super")=rsDepart1("Depart_ID") then
							rsDepart2.movenext
							if rsDepart2.eof then
								end2=1
							else if rsDepart2("Depart_Super")<>rsDepart1("Depart_ID") then
										end2=1
									end if
							end if
							rsDepart2.moveprevious
'							response.write(end1)
				%>
						<TR> 
						  <TD width="95" id=self2<%=rsDepart2("Depart_ID")%> height="20"><IMG height=22 src="./images/blank.gif" 
					width=16 border=0><% if end1=1 then %><IMG height=22 src="./images/blank.gif" 
					width=16 border=0><% else %><IMG height=22 src="./images/ftv2vertline.gif" 
					width=16 border=0><% end if
					 if rsDepart2("Depart_Sub")<>0 then %><a class=Parent id=2<%=rsDepart2("Depart_ID")%> style="CURSOR: hand" 
					onClick=ExpandCollapse(2<%=rsDepart2("Depart_ID")%>)><img id=image2<%=rsDepart2("Depart_ID")%> height=22 
					src="./images/Ftv2mNode.gif" width=16 border=0 isopen="0"></a><% else if end2=1 then%><img src="images/ftv2Lastnode.gif" width=16 border=0><% else %><img src="images/ftv2node.gif" width=16 border=0><%end if
					 end if %><IMG class=classlogo id=folder2<%=rsDepart2("Depart_ID")%> height=22 
					src="./images/ftv2folderclosed.gif" width=24 border=0 
				  clid="2<%=rsDepart2("Depart_ID")%>"></TD>
						  <TD width="75" noWrap style="CURSOR: hand"><A class=bold id=2<%=rsDepart2("Depart_ID")%> 
					style="CURSOR:hand" onclick="DoClick1('2<%=rsDepart2("Depart_ID")%>')"><SPAN 
					id=folder2<%=rsDepart2("Depart_ID")%>d onMouseOver="this.className='red1'" onMouseOut="this.className=''"><%=rsDepart2("Depart_Name")%></SPAN></A></TD>
						</TR>
				<%
							if rsDepart2("Depart_Sub")<>0 then
				%>
						<tr><td colspan="2" id="child2<%=rsDepart2("Depart_ID")%>">
							<TABLE width="100%" height="20" cellSpacing=0 cellPadding=0 border=0 class="title1">
						<%
							rsDepart3.movefirst
							dim total
							total=0
							do while not rsDepart3.eof
								if rsDepart3("Depart_Super")=rsDepart2("Depart_ID") then
									total=total+1
								end if
								rsDepart3.movenext
							loop
							intCount3=1
							rsDepart3.movefirst
							do while not rsDepart3.eof 
								if rsDepart3("Depart_Super")=rsDepart2("Depart_ID") then
						%>
								<tr><td width="90" height="22"><IMG height=22 src="./images/blank.gif" 
					width=16 border=0><%if end1=1 then%><IMG height=22 src="./images/blank.gif" 
					width=16 border=0><%else%><IMG height=22 src="./images/ftv2vertline.gif" 
					width=16 border=0><%end if
					 if end2=1 then%><IMG height=22 src="./images/blank.gif" 
					width=16 border=0><% else %><IMG height=22 src="./images/ftv2vertline.gif" 
					width=16 border=0><% end if 
					if total=intCount3 then%><img src="images/ftv2Lastnode.gif" width=16 border=0><% else %><img src="images/ftv2node.gif" width=16 border=0><% end if %><img 
					class=classlogo id=folder3<%=rsDepart3("Depart_ID")%> height=22 
					src="./images/ftv2folderclosed.gif" width=24 border=0 clid="3<%=rsDepart3("Depart_ID")%>"></td>
					<td width="80"><A class=bold id=3<%=rsDepart3("Depart_ID")%> style="CURSOR:hand"
					onclick="DoClick1('3<%=rsDepart3("Depart_ID")%>')"><SPAN 
					id=folder3<%=rsDepart3("Depart_ID")%>d onMouseOver="this.className='red1'" onMouseOut="this.className=''"><%=rsDepart3("Depart_Name")%></SPAN></A></td></tr>
						<%
									intCount3=intCount3+1
								end if
								rsDepart3.movenext
							loop
						%>
							</table>
						</td></tr>
				<%
							end if
						end if
						rsDepart2.movenext
					loop
				%>
					</TABLE></td>
				</tr>
		<%
				end if
				rsDepart1.movenext
				intCount=intCount+1
			loop
		%>
			  </table></td>
		  </tr>
		</table>
	</td>
    <td width="420" valign="top"><table width="100%" cellpadding="0" cellspacing="0" border="1" bordercolordark="#999999" bordercolorlight="#CCCCCC">
	  <tr bgcolor="#FF99FF"><td class="title3" align="center" width="60">编号</td><td class="title3" align="center" width="80">姓名</td>
	  <td class="title3" align="center" width="60">职称</td><td class="title3" align="center" width="60">职务</td><td class="title3" align="center" width="150">工资账套</td></tr>
<%
	dim i
	i=1
	do while not rsDepartDetail.eof
%>
	  <tr onMouseOut="this.className='';" onMouseOver="this.className='hand2';" <% if (i mod 2)=0 then response.Write("bgcolor='#eeeeff'") end if%>><td class="title2">&nbsp;&nbsp;<%=rsDepartDetail("Employee_ID")%></td><td class="title2">&nbsp;&nbsp;<%=rsDepartDetail("Employee_Name")%></td><td class="title2">&nbsp;&nbsp;<%=rsDepartDetail("JobTitle_Name")%></td><td class="title2">&nbsp;&nbsp;<%=rsDepartDetail("Position_Name")%></td><td class="title2">
	  	<select id="sltSM<%=i%>" name="sltSM<%=i%>" style="width:150px" onChange="ModifySM('<%=rsDepartDetail("Employee_ID")%>', this.value);">
<%
		rsSModule.movefirst
		do while not rsSModule.eof
%>
		  <option value="<%=rsSModule("SModule_ID")%>"><%=rsSModule("SModule_Name")%></option>
<%
			rsSModule.movenext
		loop
%>
		</select>
	  </td></tr>
	  <script language="JavaScript">
	  	frmESM.sltSM<%=i%>.value=<%=rsDepartDetail("SModule_ID")%>;
	  </script>
<%
		rsDepartDetail.movenext
		i=i+1
	loop
%>
	</table></td>
  </tr>
</form>
</table>
</body>
<script language="JavaScript">
	DoClick('<%=DepartID%>');
</script>
</html>

⌨️ 快捷键说明

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