基于jsp的高校公选课系统,javaweb课程设计

基于jsp的高校公选课系统登录注册界面

基于jsp的高校公选课系统mysql数据库版本源码:

超级管理员表创建语句如下:


create table t_admin(
	id int primary key auto_increment comment '主键',
	username varchar(100) comment '超级管理员账号',
	password varchar(100) comment '超级管理员密码'
) comment '超级管理员';
insert into t_admin(username,password) values('admin','123456');

课程表创建语句如下:


create table t_kc(
	id int primary key auto_increment comment '主键',
	teacherId int comment '老师',
	v1 varchar(100) comment '学期',
	v2 varchar(100) comment '课程名称',
	v3 int comment '学生人数',
	v4 int comment '学分',
	v5 varchar(100) comment '学时',
	v6 varchar(100) comment '状态',
	v7 varchar(100) comment '上课时间',
	v8 varchar(100) comment '地点',
	v9 datetime comment '选课开始时间',
	v10 datetime comment '选课结束时间',
	v3a int comment '管理员设定人数'
) comment '课程';

选课表创建语句如下:


create table t_kcxz(
	id int primary key auto_increment comment '主键',
	studentId int comment '学生',
	kcId int comment '课程',
	v1 int comment '喜爱程度',
	v2 varchar(100) comment '状态',
	insertDate datetime comment '选课申请时间',
	cj varchar(100) comment '成绩'
) comment '选课';

学生表创建语句如下:


create table t_student(
	id int primary key auto_increment comment '主键',
	username varchar(100) comment '学号',
	password varchar(100) comment '密码',
	studentName varchar(100) comment '姓名',
	age varchar(100) comment '年龄',
	sex varchar(100) comment '性别',
	phone varchar(100) comment '电话',
	bj varchar(100) comment '班级',
	nj int comment '年级'
) comment '学生';

老师表创建语句如下:


create table t_teacher(
	id int primary key auto_increment comment '主键',
	username varchar(100) comment '工号',
	password varchar(100) comment '密码',
	teacherName varchar(100) comment '老师名称',
	age varchar(100) comment '年龄',
	sex varchar(100) comment '性别',
	phone varchar(100) comment '电话',
	xy varchar(100) comment '学院'
) comment '老师';

基于jsp的高校公选课系统oracle数据库版本源码:

超级管理员表创建语句如下:


create table t_admin(
	id integer,
	username varchar(100),
	password varchar(100)
);
insert into t_admin(id,username,password) values(1,'admin','123456');
--超级管理员字段加注释
comment on column t_admin.id is '主键';
comment on column t_admin.username is '超级管理员账号';
comment on column t_admin.password is '超级管理员密码';
--超级管理员表加注释
comment on table t_admin is '超级管理员';

课程表创建语句如下:


create table t_kc(
	id integer,
	teacherId int,
	v1 varchar(100),
	v2 varchar(100),
	v3 int,
	v4 int,
	v5 varchar(100),
	v6 varchar(100),
	v7 varchar(100),
	v8 varchar(100),
	v9 datetime,
	v10 datetime,
	v3a int
);
--课程字段加注释
comment on column t_kc.id is '主键';
comment on column t_kc.teacherId is '老师';
comment on column t_kc.v1 is '学期';
comment on column t_kc.v2 is '课程名称';
comment on column t_kc.v3 is '学生人数';
comment on column t_kc.v4 is '学分';
comment on column t_kc.v5 is '学时';
comment on column t_kc.v6 is '状态';
comment on column t_kc.v7 is '上课时间';
comment on column t_kc.v8 is '地点';
comment on column t_kc.v9 is '选课开始时间';
comment on column t_kc.v10 is '选课结束时间';
comment on column t_kc.v3a is '管理员设定人数';
--课程表加注释
comment on table t_kc is '课程';

选课表创建语句如下:


create table t_kcxz(
	id integer,
	studentId int,
	kcId int,
	v1 int,
	v2 varchar(100),
	insertDate datetime,
	cj varchar(100)
);
--选课字段加注释
comment on column t_kcxz.id is '主键';
comment on column t_kcxz.studentId is '学生';
comment on column t_kcxz.kcId is '课程';
comment on column t_kcxz.v1 is '喜爱程度';
comment on column t_kcxz.v2 is '状态';
comment on column t_kcxz.insertDate is '选课申请时间';
comment on column t_kcxz.cj is '成绩';
--选课表加注释
comment on table t_kcxz is '选课';

学生表创建语句如下:


create table t_student(
	id integer,
	username varchar(100),
	password varchar(100),
	studentName varchar(100),
	age varchar(100),
	sex varchar(100),
	phone varchar(100),
	bj varchar(100),
	nj int
);
--学生字段加注释
comment on column t_student.id is '主键';
comment on column t_student.username is '学号';
comment on column t_student.password is '密码';
comment on column t_student.studentName is '姓名';
comment on column t_student.age is '年龄';
comment on column t_student.sex is '性别';
comment on column t_student.phone is '电话';
comment on column t_student.bj is '班级';
comment on column t_student.nj is '年级';
--学生表加注释
comment on table t_student is '学生';

老师表创建语句如下:


create table t_teacher(
	id integer,
	username varchar(100),
	password varchar(100),
	teacherName varchar(100),
	age varchar(100),
	sex varchar(100),
	phone varchar(100),
	xy varchar(100)
);
--老师字段加注释
comment on column t_teacher.id is '主键';
comment on column t_teacher.username is '工号';
comment on column t_teacher.password is '密码';
comment on column t_teacher.teacherName is '老师名称';
comment on column t_teacher.age is '年龄';
comment on column t_teacher.sex is '性别';
comment on column t_teacher.phone is '电话';
comment on column t_teacher.xy is '学院';
--老师表加注释
comment on table t_teacher is '老师';

oracle特有,对应序列如下:


create sequence s_t_kc;
create sequence s_t_kcxz;
create sequence s_t_student;
create sequence s_t_teacher;

基于jsp的高校公选课系统sqlserver数据库版本源码:

超级管理员表创建语句如下:


--超级管理员
create table t_admin(
	id int identity(1,1) primary key not null,--主键
	username varchar(100),--超级管理员账号
	password varchar(100)--超级管理员密码
);
insert into t_admin(username,password) values('admin','123456');

课程表创建语句如下:


--课程表注释
create table t_kc(
	id int identity(1,1) primary key not null,--主键
	teacherId int,--老师
	v1 varchar(100),--学期
	v2 varchar(100),--课程名称
	v3 int,--学生人数
	v4 int,--学分
	v5 varchar(100),--学时
	v6 varchar(100),--状态
	v7 varchar(100),--上课时间
	v8 varchar(100),--地点
	v9 datetime,--选课开始时间
	v10 datetime,--选课结束时间
	v3a int--管理员设定人数
);

选课表创建语句如下:


--选课表注释
create table t_kcxz(
	id int identity(1,1) primary key not null,--主键
	studentId int,--学生
	kcId int,--课程
	v1 int,--喜爱程度
	v2 varchar(100),--状态
	insertDate datetime,--选课申请时间
	cj varchar(100)--成绩
);

学生表创建语句如下:


--学生表注释
create table t_student(
	id int identity(1,1) primary key not null,--主键
	username varchar(100),--学号
	password varchar(100),--密码
	studentName varchar(100),--姓名
	age varchar(100),--年龄
	sex varchar(100),--性别
	phone varchar(100),--电话
	bj varchar(100),--班级
	nj int--年级
);

老师表创建语句如下:


--老师表注释
create table t_teacher(
	id int identity(1,1) primary key not null,--主键
	username varchar(100),--工号
	password varchar(100),--密码
	teacherName varchar(100),--老师名称
	age varchar(100),--年龄
	sex varchar(100),--性别
	phone varchar(100),--电话
	xy varchar(100)--学院
);

基于jsp的高校公选课系统登录后主页

基于jsp的高校公选课系统spring+springMVC+hibernate框架对象(javaBean,pojo)设计:

课程javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//课程
@Table(name = "t_kc")
public class Kc {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//老师
private Integer teacherId;
//学期
private String v1;
//课程名称
private String v2;
//学生人数
private Integer v3;
//学分
private Integer v4;
//学时
private String v5;
//状态
private String v6;
//上课时间
private String v7;
//地点
private String v8;
//选课开始时间
private Date v9;
//选课结束时间
private Date v10;
//管理员设定人数
private Integer v3a;
public Integer getTeacherId() {return teacherId;}
public void setTeacherId(Integer teacherId) {this.teacherId = teacherId;}
public String getV1() {return v1;}
public void setV1(String v1) {this.v1 = v1;}
public String getV2() {return v2;}
public void setV2(String v2) {this.v2 = v2;}
public Integer getV3() {return v3;}
public void setV3(Integer v3) {this.v3 = v3;}
public Integer getV4() {return v4;}
public void setV4(Integer v4) {this.v4 = v4;}
public String getV5() {return v5;}
public void setV5(String v5) {this.v5 = v5;}
public String getV6() {return v6;}
public void setV6(String v6) {this.v6 = v6;}
public String getV7() {return v7;}
public void setV7(String v7) {this.v7 = v7;}
public String getV8() {return v8;}
public void setV8(String v8) {this.v8 = v8;}
public Date getV9() {return v9;}
public void setV9(Date v9) {this.v9 = v9;}
public Date getV10() {return v10;}
public void setV10(Date v10) {this.v10 = v10;}
public Integer getV3a() {return v3a;}
public void setV3a(Integer v3a) {this.v3a = v3a;}
}

选课javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//选课
@Table(name = "t_kcxz")
public class Kcxz {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//学生
private Integer studentId;
//课程
private Integer kcId;
//喜爱程度
private Integer v1;
//状态
private String v2;
//选课申请时间
private Date insertDate;
//成绩
private String cj;
public Integer getStudentId() {return studentId;}
public void setStudentId(Integer studentId) {this.studentId = studentId;}
public Integer getKcId() {return kcId;}
public void setKcId(Integer kcId) {this.kcId = kcId;}
public Integer getV1() {return v1;}
public void setV1(Integer v1) {this.v1 = v1;}
public String getV2() {return v2;}
public void setV2(String v2) {this.v2 = v2;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getCj() {return cj;}
public void setCj(String cj) {this.cj = cj;}
}

学生javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//学生
@Table(name = "t_student")
public class Student {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//学号
private String username;
//密码
private String password;
//姓名
private String studentName;
//年龄
private String age;
//性别
private String sex;
//电话
private String phone;
//班级
private String bj;
//年级
private Integer nj;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getStudentName() {return studentName;}
public void setStudentName(String studentName) {this.studentName = studentName;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getBj() {return bj;}
public void setBj(String bj) {this.bj = bj;}
public Integer getNj() {return nj;}
public void setNj(Integer nj) {this.nj = nj;}
}

老师javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//老师
@Table(name = "t_teacher")
public class Teacher {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//工号
private String username;
//密码
private String password;
//老师名称
private String teacherName;
//年龄
private String age;
//性别
private String sex;
//电话
private String phone;
//学院
private String xy;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getTeacherName() {return teacherName;}
public void setTeacherName(String teacherName) {this.teacherName = teacherName;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getXy() {return xy;}
public void setXy(String xy) {this.xy = xy;}
}

基于jsp的高校公选课系统spring+springMVC+mybatis框架对象(javaBean,pojo)设计:

课程javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//课程
public class Kc  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//老师
private Integer teacherId;
//学期
private String v1;
//课程名称
private String v2;
//学生人数
private Integer v3;
//学分
private Integer v4;
//学时
private String v5;
//状态
private String v6;
//上课时间
private String v7;
//地点
private String v8;
//选课开始时间
private Date v9;
//选课结束时间
private Date v10;
//管理员设定人数
private Integer v3a;
public Integer getTeacherId() {return teacherId;}
public void setTeacherId(Integer teacherId) {this.teacherId = teacherId;}
public String getV1() {return v1;}
public void setV1(String v1) {this.v1 = v1;}
public String getV2() {return v2;}
public void setV2(String v2) {this.v2 = v2;}
public Integer getV3() {return v3;}
public void setV3(Integer v3) {this.v3 = v3;}
public Integer getV4() {return v4;}
public void setV4(Integer v4) {this.v4 = v4;}
public String getV5() {return v5;}
public void setV5(String v5) {this.v5 = v5;}
public String getV6() {return v6;}
public void setV6(String v6) {this.v6 = v6;}
public String getV7() {return v7;}
public void setV7(String v7) {this.v7 = v7;}
public String getV8() {return v8;}
public void setV8(String v8) {this.v8 = v8;}
public Date getV9() {return v9;}
public void setV9(Date v9) {this.v9 = v9;}
public Date getV10() {return v10;}
public void setV10(Date v10) {this.v10 = v10;}
public Integer getV3a() {return v3a;}
public void setV3a(Integer v3a) {this.v3a = v3a;}
}

选课javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//选课
public class Kcxz  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//学生
private Integer studentId;
//课程
private Integer kcId;
//喜爱程度
private Integer v1;
//状态
private String v2;
//选课申请时间
private Date insertDate;
//成绩
private String cj;
public Integer getStudentId() {return studentId;}
public void setStudentId(Integer studentId) {this.studentId = studentId;}
public Integer getKcId() {return kcId;}
public void setKcId(Integer kcId) {this.kcId = kcId;}
public Integer getV1() {return v1;}
public void setV1(Integer v1) {this.v1 = v1;}
public String getV2() {return v2;}
public void setV2(String v2) {this.v2 = v2;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getCj() {return cj;}
public void setCj(String cj) {this.cj = cj;}
}

学生javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//学生
public class Student  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//学号
private String username;
//密码
private String password;
//姓名
private String studentName;
//年龄
private String age;
//性别
private String sex;
//电话
private String phone;
//班级
private String bj;
//年级
private Integer nj;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getStudentName() {return studentName;}
public void setStudentName(String studentName) {this.studentName = studentName;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getBj() {return bj;}
public void setBj(String bj) {this.bj = bj;}
public Integer getNj() {return nj;}
public void setNj(Integer nj) {this.nj = nj;}
}

老师javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//老师
public class Teacher  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//工号
private String username;
//密码
private String password;
//老师名称
private String teacherName;
//年龄
private String age;
//性别
private String sex;
//电话
private String phone;
//学院
private String xy;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getTeacherName() {return teacherName;}
public void setTeacherName(String teacherName) {this.teacherName = teacherName;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getXy() {return xy;}
public void setXy(String xy) {this.xy = xy;}
}

源代码下载点这里

评论