web学生管理系统
目录第一章 项目需求分析11.1业务流程图1.2功能性需求1.1系统功能模块图第二章 技术说明第三章 项目数据库设计3.1 E-R图3.2数据库表第四章 项目实现情况4.1核心代码4.2系统运行第一章 项目需求分析1.1业务流程图一、注册流程二、登录流程三、学生信息管理流程1.2功能性需求学生信息管理系统具有注册登录功能对学生信息进行增删改查操作。1.3系统功能模块图第二章 技术说明注册界面,登录
目 录
第一章 项目需求分析 1
1.1业务流程图
1.2功能性需求
1.1系统功能模块图
第二章 技术说明
第三章 项目数据库设计
3.1 E-R图
3.2数据库表
第四章 项目实现情况
4.1核心代码
4.2系统运行
第一章 项目需求分析
1.1业务流程图
一、注册流程
二、登录流程
三、学生信息管理流程
1.2功能性需求
学生信息管理系统具有注册登录功能
对学生信息进行增删改查操作。
1.3系统功能模块图
第二章 技术说明
注册界面,登录界面,信息管理界面,
使用html引用css样式。
使用html以及其他元素嵌入jsp操作。
使用MVC模型框架
通过jsp,servlet,javabean在前端界面对后台数据库进行操作。
第三章 项目数据库设计
3.1 E-R图
3.2数据库表
第四章 项目实现情况
4.1核心代码
一、M层设计
entity包下
Student.java
代码:
package entity;
public class Student {
private String studentNumber;
private String studentName;
private String studentClass;
private String studentMajor;
private String studentAge;
public String getStudentNumber() {
return studentNumber;
}
public void setStudentNumber(String studentNumber) {
this.studentNumber = studentNumber;
}
public String getStudentName() {
return studentName;
}
public void setStudentName(String studentName) {
this.studentName = studentName;
}
public String getStudentClass() {
return studentClass;
}
public void setStudentClass(String studentClass) {
this.studentClass = studentClass;
}
public String getStudentMajor() {
return studentMajor;
}
public void setStudentMajor(String studentMajor) {
this.studentMajor = studentMajor;
}
public String getStudentAge() {
return studentAge;
}
public void setStudentAge(String studentAge) {
this.studentAge = studentAge;
}
}
User.java
代码:
package entity;
public class User {
private String name;
private String password;
private String iphone;
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
public String getIphone() {
return iphone;
}
public void setIphone(String iphone) {
this.iphone = iphone;
}
}
dao 包下
StudentDao.java
代码:
package dao;
import java.sql.*;
import java.util.ArrayList;
import java.util.List;
import entity.Student;
import tool.DBCon;
public class StudentDao {
// 查询所有的学生信息
public List getAllStudent() {
List List = new ArrayList();
Connection conn = DBCon.getConnection();
String sql = “select * from sinfo”;
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
ResultSet rs = pstmt.executeQuery();
while (rs.next()) {
Student s = new Student();
s.setStudentNumber(rs.getString(“studentNumber”));
s.setStudentName(rs.getString(“studentName”));
s.setStudentClass(rs.getString(“studentClass”));
s.setStudentMajor(rs.getString(“studentMajor”));
s.setStudentAge(rs.getString(“studentAge”));
List.add(s);
}
rs.close();
pstmt.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return List;
}
// 增添学生信息
public boolean addStudent(Student s) {
String sql = “insert into sinfo(studentNumber,studentName,studentClass,studentMajor,studentAge) values(?,?,?,?,?)”;
Connection conn = DBCon.getConnection();
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
pstmt.setString(1, s.getStudentNumber());
pstmt.setString(2, s.getStudentName());
pstmt.setString(3, s.getStudentClass());
pstmt.setString(4, s.getStudentMajor());
pstmt.setString(5, s.getStudentAge());
int count = pstmt.executeUpdate();
pstmt.close();
return count > 0 ? true : false;
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return false;
}
//修改学生信息
public boolean updateStudent(Student s) {
String sql = “update sinfo set studentName=?,studentClass=?,studentMajor=?,studentAge=? where studentNumber=?”;
Connection conn = DBCon.getConnection();
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
pstmt.setString(1, s.getStudentName());
pstmt.setString(2, s.getStudentClass());
pstmt.setString(3, s.getStudentMajor());
pstmt.setString(4, s.getStudentAge());
pstmt.setString(5, s.getStudentNumber());
int count = pstmt.executeUpdate();
pstmt.close();
return count > 0 ? true : false;
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return false;
}
// 删除学生信息
public boolean deleteStudent(String studentNumber) {
String sql = “delete from sinfo where studentNumber=?”;
Connection conn = DBCon.getConnection();
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
pstmt.setString(1, studentNumber);
int count = pstmt.executeUpdate();
pstmt.close();
return count > 0 ? true : false;
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return false;
}
public Student selectStudentByNumber(String number) {
Connection conn = DBCon.getConnection();
String sql = “select * from sinfo where studentNumber=”+number;
Student s = null;
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
ResultSet rs = pstmt.executeQuery();
while (rs.next()) {
s = new Student();
s.setStudentName(rs.getString(“studentName”));
s.setStudentNumber(rs.getString(“studentNumber”));
s.setStudentClass(rs.getString(“studentClass”));
s.setStudentMajor(rs.getString(“studentMajor”));
s.setStudentAge(rs.getString(“studentAge”));
}
rs.close();
pstmt.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return s;
}
// 查询基于某个条件的学生信息
public List selectStudentByName(String studentName) {
List List = new ArrayList();
Connection conn = DBCon.getConnection();
String sql = “select * from sinfo where studentName=?”;
Student s = null;
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
pstmt.setString(1, studentName);
ResultSet rs = pstmt.executeQuery();
while (rs.next()) {
s = new Student();
s.setStudentNumber(rs.getString(“studentNumber”));
s.setStudentName(rs.getString(“studentName”));
s.setStudentClass(rs.getString(“studentClass”));
s.setStudentMajor(rs.getString(“studentMajor”));
s.setStudentAge(rs.getString(“studentAge”));
List.add(s);
}
rs.close();
pstmt.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return List;
}
UserDao.java
代码:
package dao;
import java.sql.*;
import com.mysql.jdbc.Connection;
import entity.User;
import tool.DBCon;
public class UserDao {
public boolean addUser(User s) {
String sql = “insert into tb_user(name, password, iphone) values(?,?,?)”;
Connection conn = (Connection) DBCon.getConnection();
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
//byte b[] = s.getName().getBytes(“ISO-8859-1”);
// s.setName(new String(b, “UTF-8”));
pstmt.setString(1, s.getName());
pstmt.setString(2, s.getPassword());
pstmt.setString(3, s.getIphone());
int count = pstmt.executeUpdate();
pstmt.close();
return count > 0 ? true : false;
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} /catch (UnsupportedEncodingException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}/
return false;
}
public int selectUserByName(String name) {
Connection conn = (Connection) DBCon.getConnection();
String sql = “select * from tb_user where name = ?”;
int resultout=0;
try {
PreparedStatement pstmt = conn.prepareStatement(sql);
pstmt.setString(1, name);
ResultSet rs = pstmt.executeQuery();
if (rs.next()) {
resultout=1;
}
rs.close();
pstmt.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return resultout;
}
tool包下
DBCon.java
代码:
package tool;
import java.sql.*;
public class DBCon {
private static String url=“jdbc:mysql://localhost:3306/jdbc3”;
private static String username=“root”;
private static String password=“123456”;
private static Connection conn=null;
public static Connection getConnection() {
if(null==conn) {
try {
Class.forName(“com.mysql.jdbc.Driver”);
conn = DriverManager.getConnection(url, username, password);
}catch(ClassNotFoundException e) {
e.printStackTrace();
}catch(SQLException e) {
e.printStackTrace();
}
}
return conn;
}
public static void main(String[] args) {
System.out.println(getConnection());
}
public ResultSet query(String sql, Object[] objs) {
// TODO Auto-generated method stub
return null;
}
}
二、V层设计
1.regist.html
代码:
2.login.html
代码:
<div class="header">
学生信息管理系统
</div>
<form action="ligon" method="post">
<div class="input-wrapper">
<div class="border-wrapper">
<input type="text" name="name" placeholder="username" class="border-item" autocomplete="off">
</div>
<div class="border-wrapper">
<input type="password" name="password" placeholder="password" class="border-item" autocomplete="off">
</div>
</div>
<div class="action">
<div class="btn"><input type="submit" value="登录" ></div>
</div>
</form>
<div class="icon-wrapper">
<a href="regist.html">注册</a>
</div>
</div>
3.first.css
代码:
@charset “UTF-8”;
* {
margin: 0;
padding: 0;
}
html {
height: 100%;
}
body {
height: 100%;
font-family: JetBrains Mono Medium;
display: flex;
align-items: center;
justify-content: center;
}
.form-wrapper {
width: 20%;
height: 375px;
background-color: #00000050;
margin: auto;
margin-top: 8%;
text-align: center;
border-radius: 10px;
padding: 50px 50px;
}
.form-wrapper .header {
text-align: center;
font-size: 35px;
text-transform: uppercase;
line-height: 100px;
color:cornflowerblue;
}
.form-wrapper .input-wrapper input {
background-color: rgb(41, 45, 62);
border: 0;
width: 100%;
text-align: center;
font-size: 15px;
color: cornflowerblue;
outline: none;
}
.form-wrapper .input-wrapper input::placeholder {
text-transform: uppercase;
}
.form-wrapper .input-wrapper .border-wrapper {
background-image: linear-gradient(to right, #e8198b, #0eb4dd);
width: 100%;
height: 50px;
margin-bottom: 20px;
border-radius: 30px;
display: flex;
align-items: center;
justify-content: center;
}
.form-wrapper .input-wrapper .border-wrapper .border-item {
height: calc(100% - 4px);
width: calc(100% - 4px);
border-radius: 30px;
}
.form-wrapper .action {
display: flex;
justify-content: center;
}
.form-wrapper .action .btn {
width: 60%;
text-transform: uppercase;
border: 2px solid #0e92b3;
text-align: center;
line-height: 50px;
border-radius: 30px;
cursor: pointer;
}
.form-wrapper .action .btn:hover {
background-image: linear-gradient(120deg, #84fab0 0%, #8fd3f4 100%);
}
.form-wrapper .icon-wrapper {
text-align: center;
width: 60%;
margin: 0 auto;
margin-top: 20px;
border-top: 1px dashed rgb(146, 146, 146);
padding: 20px;
}
.form-wrapper .icon-wrapper i {
font-size: 20px;
color: rgb(187, 187, 187);
cursor: pointer;
border: 1px solid #fff;
padding: 5px;
border-radius: 20px;
}
.form-wrapper .icon-wrapper i:hover {
background-color: #0e92b3;
}
input {
width:100px;
height:50px;
border: 0;
outline: none;
background-color:rgba(0,0,0,0)
}
4.list.jsp
代码:
<%@ page language=“java” contentType=“text/html; charset=UTF-8”
pageEncoding=“UTF-8”%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>学生信息管理系统</title>
<style>
td, th {
/* white-space: nowrap; 文本不换行显示 */
white-space: nowrap;
width: 70px;
height: 35px;
/*text-align: center;文本居中显示*/
text-align: center;
}
/* div块居中显示 */
.divcenter {
width: 750px;
height: 700px;
background-color: #9bfaff;
/* overflow: auto;当内容溢出时添加滚动条 */
overflow: auto;
/* margin: auto;使div块居中显示 */
margin: auto;
}
</style>
</head>
<body background="images/101.jpg">
<div class="divcenter">
<h3 align="center">所有学生信息</h3>
<%-- style="text-align: center; 使form表单居中显示 --%>
<form action="StudentListByName" style="text-align: center;margin-top: 10px">
<input type="submit" value="高级查询">
<input type="button" value="增加学生信息" onclick="window.location.href='add.jsp'">
</form>
<h1></h1>
<table border=2 bgcolor="aqua" align="center">
<tr>
<th width="200" >学号</th>
<th width="200" >姓名</th>
<th width="200" >班级</th>
<th width="200" >专业</th>
<th width="200" >年龄</th>
<th width="200" colspan="2" >操作</th>
</tr>
</table>
</div>
</body>
</html>
5.listbyname.jsp
代码:
<%@ page language=“java” contentType=“text/html; charset=UTF-8”
pageEncoding=“UTF-8”%>
学生信息
<%-- style="text-align: center; 使form表单居中显示 --%>
<form action="StudentListByName" style="text-align: center;margin-top: 10px">
<input id="name" name="name" placeholder="按姓名查询">
<input type="submit" value="查询">
<input type="button" value="增加学生信息" onclick="window.location.href='add.jsp'">
</form>
<div align="center">
<h1></h1>
学号 | 姓名 | 班级 | 专业 | 年龄 | 操作 |
---|
6.Index.jsp
代码:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>主界面</title>
</head>
<body background="images/101.jpg">
<h1 align="center">学生信息管理系统</h1>
<h2 align="center"><a href="StudentList">学生信息管理</a></h2>
</body>
</html>
7.add.jsp
代码:
<%@ page language=“java” contentType=“text/html; charset=UTF-8”
pageEncoding=“UTF-8”%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>添加学生信息</title>
</head>
<body background="images/101.jpg">
<form action="Add" method="post">
<h3 align="center">添加学生信息</h3>
<table align="center">
<tr>
<th width="200" >学号:</th>
<th width="200" ><input type="text" name="studentNumber"></th>
</tr>
<tr>
<th width="200" >姓名:</th>
<th width="200" ><input type="text" name="studentName"></th>
</tr>
<tr>
<th width="200" >班级:</th>
<th width="200" ><input type="text" name="studentClass"></th>
</tr>
<tr>
<th width="200" >专业:</th>
<th width="200" ><input type="text" name="studentMajor"></th>
</tr>
<tr>
<th width="200" >年龄:</th>
<th width="200" ><input type="text" name="studentAge"></th>
</tr>
<tr><td colspan="2" align="center">
<input type="submit"value="添加">
</td></tr>
</table>
</form>
</body>
</html>
8.update.jsp
代码:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>修改学生信息</title>
</head>
<body background="images/101.jpg">
<form action="Update" method="post">
<h3 align="center">修改学生信息</h3>
<table align="center">
<tr>
<th width="200" >学号:</th>
<th width="200" ><input type="text" name="studentNumber" value="${s.studentNumber}" readonly="readonly"></th>
</tr>
<tr>
<th width="200" >姓名:</th>
<th width="200" ><input type="text" name="studentName" value="${s.studentName}"></th>
</tr>
<tr>
<th width="200" >班级:</th>
<th width="200" ><input type="text" name="studentClass" value="${s.studentClass}"></th>
</tr>
<tr>
<th width="200" >专业:</th>
<th width="200" ><input type="text" name="studentMajor" value="${s.studentMajor}"></th>
</tr>
<tr>
<th width="200" >年龄:</th>
<th width="200" ><input type="text" name="studentAge" value="${s.studentAge}"></th>
</tr>
<tr><td colspan="2" align="center">
<input type="submit"value="修改">
<input type="reset" value="重置">
</td></tr>
</table>
</form>
</body>
</html>
三、C层设计
Servlet包下
Add.java
Delete.java
ligon.java
代码
package servlet;
import java.io.IOException;
import java.io.PrintWriter;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.mysql.jdbc.PreparedStatement;
/**
* Servlet implementation class ligon
*/
@WebServlet("/ligon")
public class ligon extends HttpServlet {
private static final long serialVersionUID = 1L;
private static String url="jdbc:mysql://localhost:3306/jdbc3";
private static String username="root";
private static String password="123456";
private static Connection conn=null;
private static PreparedStatement pst=null;
private static ResultSet rs=null;
static boolean flag=false;
String name=null;
/**
* @see HttpServlet#HttpServlet()
*/
public ligon() {
super();
// TODO Auto-generated constructor stub
}
/**
* @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response)
*/
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
//response.getWriter().append("Served at: ").append(request.getContextPath());
request.setCharacterEncoding("utf-8");
response.setCharacterEncoding("utf-8");
response.setContentType("text/html;charset=UTF-8");
PrintWriter out=response.getWriter();
try {
Class.forName("com.mysql.jdbc.Driver");
conn = DriverManager.getConnection(url, username, password);
System.out.println("连接成功");
String sql="select * from tb_user where name=? and password=?";
pst=(PreparedStatement) conn.prepareStatement(sql);
pst.setString(1, request.getParameter("name"));
pst.setString(2, request.getParameter("password"));
rs=pst.executeQuery();
if(rs.next()) {
//flag=true;
name=rs.getString(1);
out.print("<script>alert('登录成功!');window.location.href='index.jsp'</script>");
}
else {
//request.setAttribute("No", "登录失败");
out.print("<script>alert('登录失败!');window.location.href='login.html'</script>");
//getServletContext().getRequestDispatcher("/login.html").forward(request, response);
}
rs.close();
pst.close();
conn.close();
}catch(Exception e) {
e.printStackTrace();
}finally {
}
}
/**
* @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)
*/
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
doGet(request, response);
}
}
Regist.java
代码:
package servlet;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import dao.UserDao;
import entity.User;
/**
* Servlet implementation class Regist
*/
@WebServlet("/Regist")
public class Regist extends HttpServlet {
private static final long serialVersionUID = 1L;
/**
* @see HttpServlet#HttpServlet()
*/
public Regist() {
super();
// TODO Auto-generated constructor stub
}
/**
* @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse
* response)
*/
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
// TODO Auto-generated method stub
// response.getWriter().append("Served at: ").append(request.getContextPath());
}
/**
* @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse
* response)
*/
protected void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
// TODO Auto-generated method stub
// doGet(request, response);
response.setContentType("text/html;charset=UTF-8");
String name = request.getParameter("name");
String password = request.getParameter("password");
String iphone = request.getParameter("iphone");
PrintWriter out = response.getWriter();
System.out.println(name);
System.out.println(password);
System.out.println(iphone);
byte b[] = name.getBytes("ISO-8859-1");
name = new String(b, "UTF-8");
byte b1[] = password.getBytes("ISO-8859-1");
password = new String(b1, "UTF-8");
byte b2[] = iphone.getBytes("ISO-8859-1");
iphone = new String(b2, "UTF-8");
User s = new User();
s.setName(name);
s.setPassword(password);
s.setIphone(iphone);
UserDao dao = new UserDao();
if (name == null || name.equalsIgnoreCase("") || password == null || password.equalsIgnoreCase("")
|| iphone == null || iphone.equalsIgnoreCase("")) {
out.print("<script>alert('请将注册信息填写完整');"
+ "window.location.href='regist.html'</script>");
out.flush();
out.close();
} else {
if (dao.selectUserByName(name) == 1) {// 1
out.print("<script>alert('该账户存在,注册失败!');" + "window.location.href='regist.html'</script>");
out.flush();
out.close();
} else {
// s.setName(name);
// s.setPassword(password);
// s.setIphone(iphone);
boolean flag = dao.addUser(s);
if (flag) {
out.print("<script>alert('注册成功!现在去登录吧!');"
+ "window.location.href='login.html'</script>");
out.flush();
out.close();
dao.addUser(s);
} else {
out.print("<script>alert('注册失败!重新注册吧!');"
+ "window.location.href='regist.html'</script>");
out.flush();
out.close();
}
}
}
// dao.addUser(s);
// request.getRequestDispatcher("login.html").forward(request, response);
}
}
StudentList.java
StudentListByName.java
Update.java
代码:
package servlet;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import dao.StudentDao;
import entity.Student;
/**
* Servlet implementation class Update
*/
@WebServlet("/Update")
public class Update extends HttpServlet {
private static final long serialVersionUID = 1L;
/**
* @see HttpServlet#HttpServlet()
*/
public Update() {
super();
// TODO Auto-generated constructor stub
}
/**
* @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response)
*/
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
//response.getWriter().append("Served at: ").append(request.getContextPath());
String number1=request.getParameter("number");
if(number1!=null&&!number1.equals("")) {
StudentDao dao=new StudentDao();
Student s=dao.selectStudentByNumber(number1);
request.setAttribute("s", s);
}
request.getRequestDispatcher("update.jsp").forward(request, response);
}
/**
* @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)
*/
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
//doGet(request, response);
String sno=request.getParameter("studentNumber");
String sname=request.getParameter("studentName");
String sclass=request.getParameter("studentClass");
String smajor=request.getParameter("studentMajor");
String sage=request.getParameter("studentAge");
byte b[]=sno.getBytes("ISO-8859-1");
sno=new String(b,"UTF-8");
byte b1[]=sname.getBytes("ISO-8859-1");
sname=new String(b1,"UTF-8");
byte b2[]=sclass.getBytes("ISO-8859-1");
sclass=new String(b2,"UTF-8");
byte b3[]=smajor.getBytes("ISO-8859-1");
smajor=new String(b3,"UTF-8");
byte b4[]=sage.getBytes("ISO-8859-1");
sage=new String(b4,"UTF-8");
Student s=new Student();
s.setStudentNumber(sno);
s.setStudentName(sname);
s.setStudentClass(sclass);
s.setStudentMajor(smajor);
s.setStudentAge(sage);
StudentDao dao=new StudentDao();
dao.updateStudent(s);
request.getRequestDispatcher("StudentList").forward(request, response);
}
}
系统运行截图
更多推荐
所有评论(0)