📄 user_search.jsp
字号:
<%
/*---------------------------------------------
功能描述:选择查找学生的条件
编写时间:2003-08-21
编写人:侯雄飞
email:houxf@whaty.com
修改情况记录
修改时间: 修改内容: 修改人:
-----------------------------------------------*/
%>
<%@ page language="java" %>
<%@ page contentType="text/html;charset=gb2312" %>
<%
//////////////////////////////////////////////////////////////
// Privilege Guarding
String PrivXP="查找学生";
String PrivME="00106";
%>
<%@ include file="../pub/privGuarding.jsp" %>
<%
// Privilege Guarding
//////////////////////////////////////////////////////////////
%>
<jsp:useBean id="work" scope="application" class="com.dbConnection.dbpool"/>
<%
String sql = "";
int count = 0;
com.dbConnection.MyResultSet rs ;
%>
<html>
<head>
<title>学生列表 </title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../css/style.css" rel="stylesheet" type="text/css">
<script language=javascript src="../js/check.js">
</script>
<script>
function userSearchGuarding()
{
var hasCondition = false;
if(isNull(document.search.site_id.value))
{
hasCondition=true;
}
if(isNull(document.search.major_id.value))
{
hasCondition=true;
}
if(isNull(document.search.edu_type_id.value))
{
hasCondition=true;
}
if(isNull(document.search.grade_id.value))
{
hasCondition=true;
}
if(isNull(document.search.name.value))
{
hasCondition=true;
}
if(isNull(document.search.reg_no.value))
{
hasCondition=true;
}
if(isNull(document.search.id_card.value))
{
hasCondition=true;
}
if(isNull(document.search.phone.value))
{
hasCondition=true;
}
if(hasCondition == false)
{
alert("请至少选择一个条件进行查询!");
return hasCondition;
}
}
</script>
</head>
<body leftmargin=0 topmargin=0 bgcolor=FFFFFF>
<br>
<form name="search" method="post" action="user_searchexe.jsp" target="_blank" onSubmit="return userSearchGuarding()">
<table width="75%" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="3F6c61">
<tr class="t08_bgwhite_p2">
<td colspan=2>
<p align="center"><b>查找学生--选择查询条件</b></td>
</tr>
<tr>
<td class="t12_14_bgE3EAE9">选择校外学习中心</td>
<td class="t08_bgwhite_p2"> <select name="site_id">
<option value="" selected>所有校外学习中心 </option>
<%
sql = "select id,name from lrn_site_info order by name";
count = work.countselect(sql);
if(count > 0)
{
rs = work.executeQuery(sql);
while(rs.next())
{
String id = rs.getString("id");
String name = rs.getString("name");
%>
<option value="<%=id%>" >(<%=id%>)<%=name%></option>
<%
}
work.close(rs);
}
%>
</select></td>
</tr>
<tr>
<td width="50%" class="t12_14_bgE3EAE9">选择专业</td>
<td width="50%" class="t08_bgwhite_p2">
<select name="major_id" size="1">
<option value="" selected>所有专业</option>
<%
sql = "select id,name from lrn_major_info where id <> '0' and status='1111' order by name";
count = work.countselect(sql);
if(count > 0)
{
rs = work.executeQuery(sql);
while(rs.next())
{
String id = rs.getString("id");
String name = rs.getString("name");
%>
<option value="<%=id%>" ><%=name%></option>
<%
}
work.close(rs);
}
%>
</select></td>
</tr>
<tr>
<td class="t12_14_bgE3EAE9">选择层次</td>
<td class="t08_bgwhite_p2">
<select name="edu_type_id">
<option value="" selected>所有层次</option>
<%
sql = "select id,name from lrn_edu_type order by name";
count = work.countselect(sql);
if(count > 0)
{
rs = work.executeQuery(sql);
while(rs.next())
{
String id = rs.getString("id");
String name = rs.getString("name");
%>
<option value="<%=id%>" ><%=name%></option>
<%
}
work.close(rs);
}
%>
</select></td>
</tr>
<tr>
<td class="t12_14_bgE3EAE9">选择年级</td>
<td class="t08_bgwhite_p2"> <select name="grade_id">
<option value="" selected>所有年级</option>
<%
sql = "select id,name from lrn_grade_info order by name";
count = work.countselect(sql);
if(count > 0)
{
rs = work.executeQuery(sql);
while(rs.next())
{
String id = rs.getString("id");
String name = rs.getString("name");
%>
<option value="<%=id%>" ><%=name%></option>
<%
}
work.close(rs);
}
%>
</select></td>
</tr>
<tr>
<td width=150 class="t12_14_bgE3EAE9">学生姓名</td>
<td width="350" class="t08_bgwhite_p2"><input type="text" name="name" size="25"></td>
</tr>
<tr>
<td width=150 class="t12_14_bgE3EAE9">学号</td>
<td width="350" class="t08_bgwhite_p2"><input type="text" name="reg_no" size="25"></td>
</tr>
<tr>
<td width=150 class="t12_14_bgE3EAE9">身份证</td>
<td width="350" class="t08_bgwhite_p2"><input type="text" name="id_card" size="25"></td>
</tr>
<tr>
<td width=150 class="t12_14_bgE3EAE9">电话</td>
<td width="350" class="t08_bgwhite_p2"><input type="text" name="phone" size="25"></td>
</tr>
<tr class="t08_bgwhite_p2">
<td colspan="2"> <div align="center">
<input type="submit" name="submit" value="查询" >
</div></td>
</tr>
</table>
</form>
<p align="center"><a href="user_manage.jsp">返回</a></p>
<p> </p>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -