📄 signquerymanage.jsp
字号:
<%@ page contentType="text/html; charset=gb2312"%>
<%@ page import="com.gforce.gfoa.*,com.gforce.currency.*,java.util.*" %>
<jsp:include page="/CheckLogin.jsp" flush="true"/>
<%
Session m_session = new Session(session);
Request m_request = new Request(request);
int iDepartmentID =m_request.GetInt("DepartmentID");
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"><meta http-equiv="pragma" content="no-cache">
<title>考勤查询管理-- GForce OA 2.0</title>
<link href="../css/txt.jsp" rel="stylesheet" type="text/css">
<SCRIPT language="JavaScript" src="/Calendar/PopUpCalendarDlg.js"></SCRIPT>
<script language="JavaScript" src="/js/changestyle.js"></SCRIPT>
<script language="JavaScript" type="text/javascript">
function checkSignApply()
{
if(!isDate(document.SignApply.StartDate.value))
{
alert("日期格式错误,请按照“2002-02-18”重新输入!");
document.SignApply.StartDate.focus();
return false;
}
if(!isDate(document.SignApply.EndDate.value))
{
alert("日期格式错误,请按照“2002-02-18”重新输入!");
document.SignApply.EndDate.focus();
return false;
}
}
</SCRIPT>
</head>
<body bgcolor="<%=m_session.GetString("BackColor")%>" leftmargin="0" topmargin="0" onload="javascript:for(var i=0;i<document.all.GoByDepartmentID.length;i++)if(document.all.GoByDepartmentID.options[i].value=='<%=iDepartmentID%>')document.all.GoByDepartmentID.selectedIndex=i;">
<table width="100%" height="100%" border="0" align="center" cellspacing="0">
<tr>
<td height="20" colspan="7" align="right" valign="middle"> </td>
</tr>
<form name="SignApply" action="SignQueryManage.jsp" method="post" onSubmit="javascript:return checkSignApply();">
<tr>
<td width="98" height="27" align="right" valign="middle"><strong>选择部门:</strong>
</td>
<td width="124" align="left" valign="middle">
<select name="DepartmentID" id="GoByDepartmentID">
<option value="">请选择所属部门</option>
<script language="JavaScript" src="/js/AddDepartment.jsp"></script>
</select></td>
<td width="135" align="right" valign="middle"><strong>开始时间:</strong></td>
<td width="85" height="27" align="left" valign="middle"> <input name="StartDate" type="text" onFocus="JavaScript:this.value=fPopUpCalendarDlg(this.value);" maxlength="12" size="12" onDblClick="JavaScript:this.value=fPopUpCalendarDlg(this.value);">
</td>
<td width="98" height="27" align="right" valign="middle"><strong>结束时间:</strong></td>
<td width="94" height="27" align="left" valign="middle"> <input name="EndDate" type="text" onFocus="JavaScript:this.value=fPopUpCalendarDlg(this.value);" maxlength="12" size="12" onDblClick="JavaScript:this.value=fPopUpCalendarDlg(this.value);">
</td>
<td width="154" height="27" align="left" valign="middle"> <input type="submit" value="查询">
</td>
</tr>
</form>
<tr>
<td height="20" colspan="7" align="center" valign="top"> <hr></td>
</tr>
<tr>
<td colspan="7" align="center" valign="top"> <table width="90%" border="1" cellpadding="3" cellspacing="0" bordercolordark="#ffffff" bordercolorlight="#0a0a0a" style="">
<tr align="center" valign="middle" bgcolor="<%=m_session.GetString("TitleColor")%>">
<th width="4%" height="24" nowrap><img src="/images/white.gif" width="12"></th>
<th width="4%" nowrap><font color="#000000">员工编号</font></th>
<th width="8%" nowrap><font color="#000000">姓名</font></th>
<%
int iPageSize = 15;
int iPage = m_request.GetInt("Page");
String strStartDate = "";
strStartDate =m_request.GetString("StartDate");
String strEndDate = "";
strEndDate = m_request.GetString("EndDate");
Vector vtType = SignTypeManager.getAllRecord();
for (int i=0;i<vtType.size();i++)
{
out.println("<th width=\"8%\" nowrap><font color=\"#000000\">" + ((Vector)vtType.get(i)).get(1).toString() + "</font></th>");
}
%>
</tr>
<%
if (!(strStartDate.equalsIgnoreCase("")||strEndDate.equalsIgnoreCase("")))
{
Vector vt = UserManager.getRecordAndPersonnelInfoByDepartmentID(iDepartmentID);
if(iPage<1)iPage=1;
int iPageCount = StringNew.getPageCount(vt.size(),iPageSize);
if(iPage>iPageCount) iPage=1;
for(int i=(iPage-1)*iPageSize;i<vt.size()&&i<iPage*iPageSize;i++)
{
String strID = ((Vector)vt.get(i)).get(0).toString();
if( i% 2 == 0)
out.println("<tr id=\"Row"+ i + "\" class=\"DataRowsSingle\" onmouseover=\"mouseon(this,'image" + i + "');\" onmouseout=\"mouseout(this,'image" + i + "','DataRowsSingle');\">");
else
out.println("<tr id=\"Row"+ i + "\" class=\"DataRowsDouble\" onmouseover=\"mouseon(this,'image" + i + "');\" onmouseout=\"mouseout(this,'image" + i + "','DataRowsDouble');\">");
out.println("<td align=\"right\" valign=\"middle\"><img id=\"image" + i + "\" src=\"../images/lastpost1.gif\" style=\"display:none;\"> </td>");
out.println("<td align=\"center\" valign=\"middle\">" + ((Vector)vt.get(i)).get(8).toString() + "</td>");
out.println("<td align=\"center\" valign=\"middle\" nowrap title=\"" + ((Vector)vt.get(i)).get(9).toString() + "\" onclick=\"window.open('SignLinkManage.jsp?UserID="+ strID +"&StartDate=" + strStartDate + "&EndDate="+ strEndDate +"','_blank')\"><a href=\"\" onclick=\"return false;\">" + ((Vector)vt.get(i)).get(9).toString() + "</a></td>");
//*************
if (vtType.size()>0)
{
for(int j=0;j < vtType.size();j++)
{
String strSignSUM = SignManager.getSignSUM(Integer.parseInt(strID),Integer.parseInt(((Vector)vtType.get(j)).get(0).toString()),strStartDate,strEndDate);
out.println("<td align=\"center\" valign=\"middle\" nowrap>" +strSignSUM + "</td>");
}
}
out.println("</tr>");
}
//********************************
out.println("<tr><td colspan=\"7\" align=\"center\" valign=\"middle\"><strong>");
String strCurrentPageURL = request.getRequestURI();
if(iPage<2)
out.print("首页 上页");
else
out.print("<a href=\""+ strCurrentPageURL+"?Page=" + 1 + "&StartDate=" + strStartDate + "&EndDate="+ strEndDate + "&DepartmentID=" + iDepartmentID + "\">首页</a> <a href=\""+ strCurrentPageURL+"?Page=" + (iPage-1) + "&StartDate=" + strStartDate + "&EndDate="+ strEndDate + "&DepartmentID="+ iDepartmentID +"\">上页</a>");
out.print(" 当前是第" + iPage + "页,共" + vt.size() + "条记录" + iPageCount + "页 ");
if(iPage>=iPageCount)
out.print("下页 末页");
else
out.print("<a href=\""+ strCurrentPageURL+"?Page=" + (iPage+1) + "&StartDate=" + strStartDate + "&EndDate="+ strEndDate + "&DepartmentID="+ iDepartmentID +"\">下页</a> <a href=\""+ strCurrentPageURL+"?Page=" + iPageCount + "&StartDate=" + strStartDate + "&EndDate="+ strEndDate + "&DepartmentID=" + iDepartmentID + "\">末页</a>");
out.println("</strong></td></tr>");
}
%>
</table></td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -