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

📄 empquery.jsp

📁 办公自动化系统,有人事资源管理模块,考勤管理,审批管理,权限设定等.
💻 JSP
字号:
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"  contentType="text/html; charset=utf-8"%>

<jsp:directive.page import="com.lovo.vo.mjy.TermVo;"/>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
	     <%
			 String count="1";
			  if((String)session.getAttribute("count")!=null){
			    	count=(String)session.getAttribute("count");
			    }else{
			     	count="1";
			    }
		 %>
	 <script>
   		function jian(){
		   var nihao='';
			niaho=document.getElementById('yeshu').value;
			var shuzi= niaho-1;
			if(shuzi<=1){
					document.getElementById('shang').disabled=true;
					document.getElementById('xia').disabled=false;
					document.getElementById('yeshu').value=1;
					alert('已经到了第一页');
			}else{
					document.getElementById('xia').disabled=false;
					document.getElementById('yeshu').value=shuzi;
			}
		}
		function add(){
		    var nihao='';
			nihao=document.getElementById('yeshu').value;
			var shuzi=parseInt(nihao)+1;
			var max=<%=count %>
			if(shuzi>=parseInt(max)){
					document.getElementById('shang').disabled=false;
					document.getElementById('xia').disabled=true;
					document.getElementById('yeshu').value=max;
					alert('最后一页了');
			}else{
					document.getElementById('shang').disabled=false;
					document.getElementById('yeshu').value=shuzi;
			}
		}
		function end(){	
			var max=<%=count %>
			document.getElementById('yeshu').value=max;
		}
		function shouye(){
			document.getElementById('yeshu').value=1;
		}
     </script>
	   <title>人事查询界面</title>
			<style type="text/css">
			
			#id{
				float: left; 
				height: 100px; 
				width: 800px; 
			}
			
			#id2{
				float: left; 
				height: 800px; 
				width: 150px; 
				overflow:auto;
			}
			#id3{
			float: left; 
				height: 800px; 
				width: 643px; 
			}
			body { 
				font-size: 12px; 
				margin: 0px auto; 
				height: auto; 
				width: 805px; 
			}
			#id4{
				float: left; 
				height: 100px; 
				width: 800px; 
			} 
			.mainBox { 
				border: 1px dashed #0099CC; 
				margin: 1px; 
				padding: 0px; 
				 
				height: 300px; 
				width: 192px; 
			} 
		
		td{
			width:80px;
			background: #9FCEFF;
			}
	
			table{
				text-align: center;
			}
		</style> 
</head>
	<body bgcolor="#ffff1ff">
		<div class="mainBox" id = "id"> 
		</div> 
		<div class="mainBox" id = "id2" >
		</div> 
		<div class="mainBox" id = "id3">
	    <form action="<%=request.getContextPath() %>/ItemServlet" method="get" >
		<table align="center"  style="text-align:center;">
			<tr>请休假管理-->申请情况查看<br /></tr>
		
			<tr><tdcolspan="8" style="background:white;" >
				
				<span style="display:block; width:605px;text-align:center;">请休假情况列表如下:
				<input type="submit" name="button" value="查询" onclick="window.location='<%=request.getContextPath() %>/ItemServlet?yeshu='+document.getElementById('yeshu').value;"/>
				</span></tr>
			<tr>
				<td>部门</td><td>请假人</td><td>职务</td><td>请假天数

</td><td>起始时间</td><td>终止时间</td><td>情况</td>
			</tr>
			 <%
			  String buMen="",name="",zhiWu="",qiShi="",zhongZhi="",qingKuang="",tianShu="";
			  
			  if((Vector)request.getAttribute("vector")!=null){
			   		Vector ve=(Vector)request.getAttribute("vector");
					 for(int i=0;i<ve.size();i++){ 
				 		TermVo v1=(TermVo)ve.get(i);
			   			buMen=v1.getDept();
			   	    	name=v1.getUserName();
			   			zhiWu=v1.getDuty();
			   			qiShi=v1.getStartLeaveDate();
			   			zhongZhi=v1.getStopLeaveDate();
			   			qingKuang=v1.getCircs();
			   			tianShu=String.valueOf(v1.getTianShu());
			   			buMen=new String(name.getBytes("iso-8859-1"),"gbk");
			   			name=new String(name.getBytes("iso-8859-1"),"gbk");
			   			//zhiWu=new String(name.getBytes("iso-8859-1"),"gbk");
			   			//qingKuang=new String(name.getBytes("iso-8859-1"),"gbk");
				 %>
			<tr>
				<td><%=buMen %></td><td><%=name%></td><td><%=zhiWu%></td><td><%=tianShu%>

</td><td><%=qiShi%></td><td><%=zhongZhi %></td><td><%=qingKuang %></td>
			</tr>
			<%}
			} %>
			<tr>
			<td colspan="8" style="background:white;">
				<span style="display:block; width:605px;text-align:right;">共<%=count %>页
				<input id="shang" type = "button" value="上一页" onclick="jian();window.location='<%=request.getContextPath() %>/ItemServlet?yeshu='+document.getElementById('yeshu').value;" />
				<input id="xia" type = "button" value="下一页" onclick="add();window.location='<%=request.getContextPath() %>/ItemServlet?yeshu='+document.getElementById('yeshu').value;"  />
	            <input id="shou" type = "button" value="首页" onclick="shouye();window.location='<%=request.getContextPath() %>/ItemServlet?yeshu='+document.getElementById('yeshu').value;" />
	            <input id="wei"  type = "button" value="尾页" onclick="end();window.location='<%=request.getContextPath() %>/ItemServlet?yeshu='+document.getElementById('yeshu').value;"/>
				<input id="id7" type = "submit" value="转至" />
				<%String yeshus=(String)request.getAttribute("yeshu"); if(yeshus==null){yeshus="1";}%>
				<input type="text" size="3" name="yeshu" id="yeshu" value="<%=yeshus%>"/>页</span>
			</tr>
		</table>
	    </form>
		</div>
		<div class="mainBox" id = "id4">
		</div>
	</body>
</html>

⌨️ 快捷键说明

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