Design of online course selection system for JSP students (source code + thesis + defense PPT)

Summary

With the continuous improvement of science and technology, computer science is becoming more and more mature, and its powerful functions have been deeply recognized by people. It has entered various fields of human society and is playing an increasingly important role. As a modern teaching technology, the student course selection system is getting more and more attention from the people. It is an indispensable part of a school. The student course selection system is designed to manage course selection information. The student course selection system will standardize, systematize, and program the course selection management, avoid the randomness of course selection management, improve the speed and accuracy of information processing, and enable timely, accurate and effective query and modification of course selection.

The system realizes the management of the basic information of the courses, the course selection of students, and the users of students and teachers. The system provides personal information viewing, course selection management and other functions for student roles; provides teachers with viewing the class schedule of the course they are in charge of and the student information of the course; provides administrators with the following functions: view information about all courses, students, and teachers And they can be managed (add, edit, delete), and realize news release and modification.

Keywords : course selection, course information release, B/S, SQL Server 2000, JSP

Abstract

With the improvement of science technology, the computer science becomes gradually mature, people have already deeply understood its strong function, and it has already got into each realm of the human society to exert a more and more important function. The student selecting system, a modernizing teaching technology, pays much more attention by people. It is indispensable part for a school. The student selecting system is for the sake of managing to the information of selecting courses. The tendency of student selecting system will edify the selecting management, it would be more systematical and procedural in future work. We try to avoid the random work, promoting the accuracy and speed of the processing information, so that we can check the information of selecting course with a convenient and efficient form.

The system carried out the management of basic information of course, the student selecting course, the student and the teacher's customer. The system provides a function, which is good for students to check their personal information and the management of selecting course, to the characters of the students. And for the teachers, it is convenient to look into the curricular lesson that he hold and the Student's information that chose the course. At last, it is good for manager to check all the information of the lessons, students and teachers. Furthermore, it can carry on a management (increase, edit, delete) to them, and carry out the renounce of the news.

Key words: select course, the renouncement of course information, B/S、SQL Server 2000、JSP

Table of contents

SCIENCE & TECHNOLOGY COLLEGE OF- 1 -

NANCHANG UNIVERSITY- 1 -

THESIS OF BACHELOR- 1 -

Summary- 2 -- 2 --

Abstract- 3 -

Directory - 4 -- 4 -

Chapter 1  Introduction - 5 - 5 -

1.1 Course Background - 5 -- 5 -

1.2 Curriculum status - 6 -- 6 -

Chapter Two System Requirements Analysis - 6 -- 6 -

2.1 Demand Analysis - 6 -- 6 -

2.2 Feasibility Analysis - 7 -- 7 -

2.3 System Configuration Requirements - 7 -- 7 -

Chapter 3 System Overall Design - 8 -- 8 -

3.1 Project Planning - 8 -- 8 -

3.2 Design goals - 8 -- 8 -

3.3 Introduction to related technologies of the system - 8 -- 8 -

3.3.1 Technical solution adopted in system development - B/S mode - 8 -- 8 -

3.3.2 Introduction to JSP Technology - 8 -- 8 -

3.3.3 SQL 2000 SERVE database introduction - 10 -- 10 -

3.4 Database analysis and design - 10 -- 10 -

3.4.1 Database requirements analysis - 10 -- 10 -

3.4.2 Database concept structure design - 10 -- 10 -

3.4.3 Design and creation of database table - 12 -- 12 -

Chapter 4 System Detailed Design and Implementation - 15 -- 15 -

4.1 Main interface design - 16 -- 16 -

4.2 Interface head and tail design - 16 -- 16 -

4.3 Login interface - 16 -- 16 -

4.4 Student User Interface Design - 17 -- 17 --

4.4.1 Functional module design of personal information module - 18 -- 18 -

4.4.2 Functional Design of Online Platform Module - 19 -- 19 -

4.4.3 System Bulletin - 21 -- 21 -

4.4.4 Design of other functional modules - 22 -- 22 -

4.5 Administrator User Interface Design - 22 -- 22 -

4.5.1 User management module function design - 23 -- 23 -

4.5.2 Functional Design of Online Platform Module - 24 -- 24 -

4.5.3 System bulletin module design - 25 -- 25 -

4.5.4 Design of other functional modules - 26 -- 26 -

4.6 Teacher user interface design - 26 -- 26 -

4.7 System background module - 27 -- 27 -

References - 28 - 28 -

Chapter One Introduction

1.1 Course Background

The development of the Internet has made our education more modern, and now online information management is a hot spot in our education. Now, the dissemination of information between teachers and students and the school is only between one finger, creating a convenient and fast way for us. There are certain deficiencies in terms of security and information updating. The data of each existing system is established separately, and the sharing is poor. In the method with the manager as the main body, information selection depends on the manager’s cognition and preferences for information, which is relatively unsatisfactory. It is easy to grasp the real needs of users, and therefore cannot fully meet the needs of users. At present, the country's education system is also in the stage of continuous reform and innovation. my country's education department has fully absorbed foreign excellent teaching models, combined with many years of domestic experience in running schools, and gradually explored teaching forms suitable for Chinese characteristics. All kinds of schools have launched a comprehensive reform of the credit system. Therefore, the teaching management software should fully rely on the campus network to realize the centralized management, decentralized operation and information sharing of teaching information, so that the traditional teaching management will develop in the direction of digitization, paperless, intelligent and comprehensive, and further realize the perfect It has laid a good foundation for the advanced computer teaching file management system and the whole school information system. "Student Online Course Selection System" is an important part of the teaching management system in colleges and universities. Familiar with the whole process of teaching management work, proceed from the reality of educational affairs, solve key and difficult problems in the work, and make full use of computer network functions to realize computer management of the whole process of teaching work, and help specific managers to liberate from complex and tedious work come out. Make teaching management move towards paperless office and standardized and modernized management.

Because the Internet has a wide range of influence, it can transmit information conveniently and quickly, it has near real-time interactivity, and it is itself a huge and incomparable information base, and many other advantages. The online course selection system for students can improve the management efficiency of teachers, students and schools. Our goal is to use the student online course selection system to achieve the fastest release of elective courses and news releases for the whole school, so that teachers and students can know as soon as possible, and create a modern learning environment. Student course selection is one of the main management tasks of a university, involving many aspects of the school, department, teachers, and students. With the continuous reform of the teaching system, the constraints of student course selection are more complicated, the workload is also heavy, and often requires Complete in a shorter time. Here, by using computer-aided course selection, a large amount of course selection data can be inspected and counted in real time, and the result of course selection can be output very conveniently, and at the same time, mistakes that are prone to occur during manual processing can be avoided.

Chapter Two System Requirements Analysis

2.1 Demand Analysis

As a modern teaching technology, the student course selection system has been paid more and more attention by the people. It is an indispensable part of a school, and its content is very important to the decision-makers and managers of the school, so the student course selection system should be able to provide users with sufficient information and fast query methods. However, people have always used the traditional manual method to manage files and archives. This management method has many shortcomings, such as: low efficiency, poor confidentiality, and over time, a large number of files and data will be generated, which is very important for searching, updating and maintaining. All brought a lot of difficulties.

The system specifically has the following functions:

  • Personal information: including student and student personal data
  • Course plan: plan the course start time, class location, class teacher and other information
  • Management functions: course publishing, modification, deletion. Add and delete students and teacher users. Publishing and deletion and modification of news
  • Teacher user: Teachers can change their passwords, view courses and the list of students who have taken their own courses, and view news
  • Student users: elective courses, can be deselected
  • Conditional query: users can query the information they need
  • Exit system

2.2 Feasibility analysis

1. Economy

The system interface is friendly, the operation is simple, the configuration requirements of the system are not high, the realization is feasible, and therefore the economy is feasible. The system can easily realize the connection between students, teachers and schools, complete part of the educational affairs on the Internet, and improve the efficiency and cycle of work.

2. Technical

With the vigorous development of the Internet, more and more institutions integrate scientific research management with the Internet to facilitate the management of universities. Under such a social background, based on Windows and SQL Server 2000, using advanced JSP technology, the student online course selection system developed by B/S mode organically combines students, teachers, administrators, and effectively improves management level and efficiency. With the continuous improvement of science and technology, computer science is becoming more and more mature, and the technology based on the above is relatively easy to realize nowadays.

3. Operability:

The system is easy and simple to operate.

2.3 System Configuration Requirements

(1) Server configuration

Hardware platform:

CPU: P4 1.8GHz or above;

Memory: 256MB or more.

software platform:

Operating system: Windows 2000 Server;

Database: SQL Server 2000;

Development Kit: JDK Version 1.4.2;

JSP server: Tomcat 5.0;

Chapter 3 System Overall Design

3.1 Project planning

Based on Windows operating system and Microsoft SQL Server 2000 database, a B/S layer structure student course selection system is established, and JSP programming is used to realize the function of students' course selection and teachers' inquiry of class information.

The online course selection system is divided into three main modules in terms of functions, which mainly realize teacher information management, student information management, and course information management, among which teacher information management includes teacher name, teacher job number, teacher title, teacher's department; student information management There are student names, student ID numbers, and student departments; course information management includes course names, credits, class locations, class times, and class teachers. The administrator has the right to change the information of the courses selected.

  • Identity login: student, teacher, and administrator login with three identities (different permissions)
  • User management: administrators can add users with various permissions, modify, and delete users
  • Curriculum management: can add, delete and modify the promulgated curriculum
  • News release: administrators can release news and modify and delete it

3.2 Design goals

Establish an online course selection system for students to maintain the basic information of courses, as well as the information of students' course selection and teachers' class attendance. The system provides personal information management, course selection management, and management of students' selected courses for student roles. The system provides teachers with information about viewing the class schedule of the courses they are in charge of and the students who choose the courses. The system also provides administrators with the following functions: view all majors, courses, students, and teachers' information and manage them (add, edit, delete). And realize the release and modification of news. Improve the speed and accuracy of information processing, and be able to query and modify course selection in a timely, accurate and effective manner.

3.3 System related technology introduction

3.3.1 Technical solution adopted in system development - B/S mode

The rapid development of information technology makes the network computing model constantly updated. From the host/terminal mode in the stand-alone era, the shared data mode in the file server era, the Client/Server (client/server) mode in the client/server era, to the Browser/Server (browser/server) in the network computer era today mode, computing mode has undergone tremendous changes. At the same time, the continuous progress of the computing model has greatly changed the architecture of the management software.

The system synthesis also applies the B/S mode, that is, the Browser/Server (browser/server) structure, which is an improvement on the C/S structure. The advantage of the B/S mode is that the operation and maintenance are relatively simple, and different personnel can access and operate common data in different access methods from different locations, which solves geographical restrictions.

The Internet-based application systems all adopt the Browser/Server (browser/server) model structure. In addition to the Web browser, the software to be installed on the client side is some plug-ins and controls. These plug-ins are designed on the server side and downloaded to the client side through the network, while the controls are downloaded and registered for the first time. This is a minimal client installation and client mode, which is the development direction of the current client server architecture.

3.3.2 Introduction to JSP Technology

JSP is a dynamic web technology standard initiated by Sun Microsystems and established by many companies. This technology provides an easy and fast way to create Web pages that display dynamically generated content. JSP technology is designed to make it easier and faster to construct web-based applications that can work with various web servers, application servers, browsers, and development tools. The JSP specification is the result of extensive collaboration among Web server, application server, transaction system, and development tool vendors. Adding Java program fragments (Scriptlet) and JSP tags (tag) to traditional web page HTML files (*htm, *.html) constitutes a JSP web page (*.jsp). When the web server encounters a request to access a JSP web page, it first executes the program fragments in it, and then returns the execution result to the client in HTML format. Program fragments can manipulate databases, redirect web pages, send emails, etc., which are the functions needed to build dynamic websites. All program operations are executed on the server side, and only the results are sent to the client on the network. The requirements for the client's browser are the lowest, and no Plugin, ActiveX, Java Applet, or even Frame can be realized.

JSP technology accelerates the development of dynamic Web pages in several ways:

1. Separation of content generation and display

Using JSP technology, Web page developers can use HTML or XML tags to design and format the final page. Use JSP tags or small scripts to generate dynamic content on the page (content that changes based on a request, such as requesting account information or the price of a specific bottle of wine). The logic for generating content is encapsulated in the logo and JavaBeans components, and bundled in small scripts, all scripts run on the server side. If the core logic is encapsulated in the logo and Beans, then other people, such as Web managers and page designers, can edit and use JSP pages without affecting the generation of content. On the server side, the JSP engine interprets JSP tags and scriptlets, generates the requested content (for example, by accessing JavaBeans components, accessing databases using JDBCTM technology, or including files), and sends the results as HTML (or XML) pages back to the browser. This helps authors protect their code while ensuring full usability in any HTML-based Web browser.

2. Emphasize reusable components

As a good dynamic web page development language, JSP has been used more and more widely. Among various JSP applications, the combination of JSP+JavaBean has become the most common JSP program standard in fact. JavaBean is a software component model that describes Java, which is somewhat similar to Microsoft's COM component concept. In the Java model, the functions of Java programs can be infinitely expanded through JavaBean, and new application programs can be quickly generated through JavaBean components. For programmers, the best thing is that JavaBean can realize code reuse.

A JavaBean is a Java-based software component. JSP provides perfect support for integrating JavaBean components in Web applications. This support not only reduces development time (it can directly use tested and trusted existing components, avoiding repeated development), but also brings more scalability to JSP applications. JavaBean components can be used to perform complex computing tasks, or be responsible for interaction with the database and data extraction. If we have three JavaBeans, which have the functions of displaying news, stock prices, and weather conditions, then creating a Web page containing all these three functions only needs to instantiate these three Beans, and use HTML tables to position them in turn. . With JavaBean components that run across platforms, JSP provides an excellent solution for separating processing logic from display styles.

3.3.3 SQL 2000 SERVE database introduction

With the development of information technology, the way of computer processing data is also changing, file management system - database management system. Microsoft SQL Server 2000 is a distributed relational database management system with a client/server architecture, which uses the Transact-sql sql language to transmit the client's request and the server's processing results between the client and the server. It is a widely used database management system with many significant advantages: ease of use, scalability suitable for distributed organizations, data warehouse functions for decision support, integration with many other server software, good cost performance etc.

3.4 Database analysis and design

3.4.1 Database requirements analysis

The requirement of the student course selection management system is to manage student information accurately and quickly. Students belong to classes, colleges; students need courses, credits, grades, and these are added by teachers or administrators. This concludes the following requirement information:

  • Users are divided into administrator users, teacher users and student users.
  • A student has multiple courses, and a course corresponds to multiple students.
  • A teacher can teach multiple courses, and a course can be taught by multiple professors.
  • Admins can post news

After analyzing the above system functions and summarizing the requirements, the following data items are designed:

  • Administrator information: username, password.
  • Student information: student ID, name, gender, class, age, college, department
  • Teacher information: teacher ID, name, gender, age
  • Course information: course ID, name, class time, class location, credits, class teacher
  • Class information: class ID, name, class teacher
  • News information: news ID, news title, news content

3.4.2 Database conceptual structure design

From the above data items, various entities that can meet the needs of users and the relationship between them can be designed, laying the foundation for the subsequent logical structure design. These entities contain various specific information, and form the flow of data through mutual interaction. The entities designed in this system are: student entity, teacher entity, course entity and class entity.

Figure 3-1 shows the ER diagram of the relationship between entities

Figure 3-2 is the student information entity ER diagram

Figure 3-3 is the ER diagram of the administrator information entity

Figure 3-4 is the teacher information entity ER diagram

Figure 3-5 is the course information entity ER diagram

3-1 shows the ER diagram of the relationship between entities

3-2 ER diagram for student information

system user

Figure 3-3 is the administrator information ER diagram

Figure 3-4 is the teacher information ER diagram

3-5 is the ER diagram of the course information entity

3.4.3 Design and creation of database tables

According to the above analysis and ER diagram, the design results of each table in the system database are shown in Table 3-7 to Table 1. Each table represents a table in the database.

The user table admin (as shown in Table 3-8) records the username and password of the administrator. Administrators can add users with various permissions, modify, and delete users.

Figure 3-8 Administrator table

The student table student is used to record student information. The information of this record will be displayed in detail on the page after the student logs in. This information does not allow students to update themselves.

Figure 3-9 Student Information Form

The teacher table teacher is used to record teacher information.

Figure 3-10 Teacher Information Form

Curriculum course is used to record the course information table

Figure 3-11 Course information table

Course selection form sc records student course selection information

Figure 3-12 Course Selection Information Form

News table article records news information

Figure 3-13 News information table

Class table class records class information

Figure 3-14 Class information table

3.5 System module design

The system includes 3 management modules: user management module, course management module, and course selection management module. The user module is divided into 3 types of users, administrators, students, and teachers. The administrator implements course management, student and teacher management, and news release management. This system mainly implements the student management module, and the main modules related to administrators and students are the student management module, course management module, and course selection management module.

Figure 3-17 and Figure 3-18 show the module functions from the perspective of administrators and student users.

Figure 3-17 Administrator function module

Figure 3-27 Student user function module diagram

Chapter 4 Detailed Design and Implementation of the System

4.1 Main interface design

Page framing. The interface of this system adopts a frame structure, and the page header, left navigation, and right text are placed in different frames. When the user selects a different function menu in the left navigation, the content is only refreshed in the right text area, which makes the page structure clear. Easy for users to operate.

The index.jsp of the first page of the system displays links to log in with three identities on the left side of the page. It is convenient for different users to clearly see the login location. The user names and passwords submitted by users with different identities to log in are submitted to the database authentication pages of different identities. Such as student user login submitted to login.jsp. When the verification is passed, jump to the page of the student user. And save the information into the session for other pages to determine whether the user has logged in.

The system home page is shown in Figure 4-1.

Figure 4-1 System home page

4.2 Head and tail design of the interface

In order to realize the reuse of the interface, the system makes the header and tail of the interface into a public interface, so that other pages can be referenced. In this example, the head and tail design is relatively simple. Design the head and tail as head.html and tail.html files under the inc folder

4.3 Login interface

The login interface is relatively simple, providing different login pages for users with different identities, and finally submitting different authentication pages. When the verification is passed, jump to the user usage page.

The following is an example of logging in as a student. The login pages for teachers and administrators are similar.

Figure 4-2 Login page

4.4 Student User Interface Design

The student user function module consists of four parts: personal information, online platform, system announcement and others.

  • Personal information: display all personal information of the user and provide password modification function
  • Online platform: Provide student users to view all course selection information, users can query the courses they want, and search through two methods: course name and class time. When the user clicks to select a course, the course will be added to my class schedule, and a record will be added to the class list in the database. Users can unselect courses in my class schedule
  • System announcements: Users can browse system announcements.
  • Other functions: exit the system

Student user interface design is implemented with the framework. The page header is placed on the upper frame, the functional navigation is placed on the left frame, and the specific functions are placed on the right frame. All pages of student function design are placed in the student folder, so the pages mentioned below are all in the student folder. Set the student interface frame structure home page index.htm. The functional navigation page in the left frame is student_left.jsp, and the functional page in the right frame is student_body.jsp.

The system saves the user's student number in session.

Figure 4-3 Student User Interface

The code of the frame is:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">

<html>

<head>

<link href="../style.css" rel="stylesheet" type="text/css">

<meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<title>Student Course Selection System</title>

</head>

<frameset align="center" rows="129,*" cols="*" frameborder="NO" border="0" framespacing="0">

<frame src="../inc/head.htm" name="topFrame" scrolling="NO" noresize >

<frameset align="center" rows="*" cols="153,*" framespacing="0" frameborder="NO" border="0">

<frame align="center" src="student_left.jsp" name="leftFrame" scrolling="NO" noresize>

<frame align="center" src="student_body.jsp" name="mainFrame">

</frameset>

</frameset><noframes></noframes>

<frameset align="center" rows="5,*" cols="*" frameborder="NO" border="0" framespacing="0">

</frameset>

<body>

</body>

</html>

4.4.1 Functional module design of personal information module

The personal information module includes two parts: personal data and password modification. The personal information displays all the information of the student, including the student number, name, college, department, and class. Password modification part: users can modify the password according to their own needs, which is convenient for user management.

As shown in Figure 4-4 personal information display page, 4-5 password modification page.

Figure 4-4 Personal information display page

Figure 4-5 Password modification page

4.4.2 Functional design of online platform modules

The online platform consists of two parts: course selection information and my class schedule

  • Course selection information: student users can view all course selection information, and provide users with fuzzy query, so that users can query the courses they want. Fuzzy query can be searched by two ways: course name and class time. When the user clicks on the course column in the course list, the course will be added to my class schedule, and a record will be added to the class list in the database.
  • My class schedule: After selecting a course, students can clearly see their course selection, as well as the time, place, credits and other information of their class by viewing my class schedule. When the student user finds that the revision needs to be modified, he can choose the option to withdraw and cancel the selection.

Course selection information: courseInfo.jsp My class schedule: noticeList.jsp

As shown in Figure 4-6 Course selection information page 4-7 My class schedule page

Figure 4-6 Course selection information page

Figure 4-7 My class schedule display page

Among the course selection items shown in Figure 4-7, click Select Course to select the course, and realize the paging display and fuzzy query functions on the course information page.

Figure 4-8 shows the course information selected by the student user. In the Delete option, click Delete to unselect the course.

code show as below:

<%@ page import="java.sql.*" %>

<%@ page import="Bean.*" %>

<head>

<style type="text/css">

A:link{color: 006699;font-size:9pt;text-decoration:none}

A:visited{color: #006699;font-size:9pt;text-decoration:none}

A:hover{color: #FF6600;font-size:9pt;text-decoration:underline}

</style>

<title></title>

<script language="JavaScript">

<!--

function part(id)

{

if (confirm("Are you sure you want to delete?") )

top.location="del.jsp?id="+id

}

</script>

</head>

<body background="../images/BKGRD9.jpg">

<center>

<br>

<p>My schedule</p>

<%//Prevent some users from logging in and directly want to enter this page

if (session.getAttribute("s1")==null){

response.sendRedirect("../index.jsp");

}%>

<%

useBean2 enroll=new useBean2();

enroll.useBean();

String id=(String)session.getAttribute("s1");

String strSQL="select * from course,sc where sc.num='"+id+"'and sc.cno=course.cno";

ResultSet rs= enroll.executeQuery(strSQL);

if(rs.next()){%><table gcolor="#CCCCFF" border="1" width="500" align="center">

<tr><td>Deselect</td><td>Course Name</td><td>Time</td><td>Location</td><td>Teacher</td><td >Credit</td></tr>

<%

while(rs.next())

{%>

<tr><td> <a href="del.jsp?id=<%=rs.getString("cno")%>">删除</a></td>

<td ><%=rs.getString("cname")%></td>

<td ><%=rs.getString("ctime")%></td>

<td ><%=rs.getString("cadress")%></td>

<td ><%=rs.getString("ctea")%></td>

<td ><%=rs.getShort("csc")%></td>

</tr>

<%} }

else out.print("You have not selected any courses!");

enroll.close();%>

</table>

<table width="650">

</table>

</center>

</body>

4.4.3 System announcement

Users can browse the recent news page: news.jsp.

Figure 4-8 Browse the news page

Click the link of the news title to jump to the specific content page of the news: article.jsp

Figure 4-9 News content page

4.4.4 Design of other functional modules

When the user logs out of the system, when the user clicks to log out, the system calls logout.jsp to clear the user information from the session.

code show as below:

<%session.invalidate();

response.sendRedirect("index.jsp");

%>

4.5 Administrator User Interface Design

The administrator user function module consists of four parts: user management, online platform, system announcement and others.

  • User management: manage students and teachers users. Implement addition and deletion. Query student and teacher information at the same time. Admins can add admin users.
  • Online platform: The administrator manages courses, publishes courses, and modifies and deletes them. You can inquire about courses.
  • System announcements: administrators manage announcements, release, add, and modify news.
  • Other functions: exit the system

Both administrator and student user interfaces are implemented with the same frame, and all pages of administrator function design are placed in the admin folder, so the pages mentioned below are all in the admin folder. Set the administrator interface frame structure home page index.htm. The function navigation page in the left frame is admin_left.jsp, and the function page in the right frame is admin_body.jsp.

4.5.1 User management module function design

Manage students and teacher users. Add and delete student and teacher users as needed. Administrators can query student and teacher information, and administrators can add administrator users as needed. Administrators can also change passwords.

The implementation of modifying the password is the same page reset.jsp as the student user. Admin user addition: addUser.jsp

Add student information: addstudent.jsp

View student information: studentInfo.jsp

View teacher information: teacherInfo.jsp

Add teacher information: addteacher.jsp

Figure 4-10 Student user addition

Figure 4-11 Student Information Query

The student can be deleted when clicking Delete in the above picture, and the administrator should delete it as needed.

The addition and deletion of teachers is like the addition and deletion of students. The administrator can delete the teacher and his information as needed.

4.5.2 Functional design of online platform modules

The online platform consists of two parts: viewing course selection information and posting new courses

  • View course selection information: administrator users can view all course selection information, and provide users with fuzzy query when viewing. Administrators can query the courses they are looking for according to their needs, and fuzzy query can be searched by course name. At the same time, the administrator can make necessary changes in the modify course selection information column and delete column in the course list, such as modifying course information or deleting the course.
  • Publish new courses: administrators can release courses on time according to the syllabus, and add necessary elective courses for students to choose courses.

The specific page is shown below.

Figure 4-12 View course selection information

4.5.3 System Announcement Module Design

The system bulletin module design is divided into two parts: browse news, release news

  • Browsing news: administrators can browse news, and make necessary modification and deletion of multiple news at the same time
  • Publish news: Publish news as needed to tell students and teachers about the latest developments of users

Figure 4-13 Browse the news page

Figure 4-14 News modification page

Figure 4-15 Press release page

4.5.4 Design of other functional modules

The administrator logout is the same as the design of the student information module, call logout.jsp to clear the user information from the session.

4.6 Teacher User Interface Design

The teacher user function module is also composed of four parts: personal information, online platform, system announcement and others.

Since many functional modules of teacher user and student user are similar, only part of the design is written below.

  • Personal information: display all personal information of the user and provide password modification function
  • Online platform: Teachers can view all the student information who choose their courses, and can query student information
  • System announcements: Users can browse system announcements.
  • Other functions: exit the system

The teacher, student user, and administrator user interfaces are all implemented in the same framework. All pages of teacher function design are placed in the teacher folder, so the pages mentioned below are all in the teacher folder. Set the administrator interface frame structure home page index.htm. The function navigation page in the left frame is teacher_left.jsp, and the function page in the right frame is teacher_body.jsp.

The online platform consists of two parts: view student information and my class schedule

  • View student information: Teachers can view all the student information of their own courses, so that teachers can better understand students. Teachers can search for a student according to the actual situation. This system provides fuzzy query, which can be searched by student's name.
  • My class schedule: Teachers can view their own class information, so that teachers and users can understand their work arrangements

Figure 4-16 Check the student list

4.7 System background module

The system uses JavaBean to connect to the database by calling JavaBean

The relevant code is as follows:

package Bean;

import java.sql.*;

import java.io.*;

import javax.servlet.*;

import javax.servlet.jsp.*;

import java.util.*;

import javax.servlet.http.*;

public class useBean2{

//ServletRequest request;

//ServletResponse response;

//JspWriter out;

String Sd="sun.jdbc.odbc.JdbcOdbcDriver"; //Build a connection machine

String Sc="jdbc:odbc:xxx"; //Create an Odbc source

Connection con=null; //Connection object

ResultSet rs=null; //Create a record set

public void useBean(){

try{

Class.forName(Sd); //Load the driver class with the classforname method

}catch(java.lang.ClassNotFoundException e){

//The exception thrown when this class is not found to be loaded

System.err.println(e); //Execute system error printing

}

}

public ResultSet executeQuery(String sql){ //Can perform operations such as adding and deleting

try{

con=DriverManager.getConnection(Sc);

Statement stmt = con.createStatement(

ResultSet.TYPE_SCROLL_SENSITIVE,

ResultSet.CONCUR_READ_ONLY);

rs=stmt.executeQuery(sql);

}catch(SQLException er){

System.err.println(er.getMessage());

}

return rs;

}

public int executeUpdate(String sql){ //database update operation

int result=0;

try{

con=DriverManager.getConnection(Sc);

Statement stmt=con.createStatement();

result=stmt.executeUpdate(sql);

}catch(SQLException ex){

System.err.println(ex.getMessage());

}

return result;

}

public void close(){

try{

if(con!=null)

con.close();

}catch(Exception e){

System.out.print(e);

}try{

if(rs!=null)

rs.close();

}catch(Exception e){

System.out.println(e);

}

}

}

Chapter 6 Summary and Acknowledgments

references

[1] Sun Weiqin, Li Hongcheng. Detailed Explanation of Tomcat and Java Web Development Technology [M]. Electronic Industry Press, 2005.8.

[2] Shi Zhiguo, Xue Weimin, Dong Jie. JSP Application Tutorial [M]. Tsinghua University Press, Beijing Jiaotong University Press,

2004.9.

[3] Wang Xiaoyi, Liu Zhongbing, Xu Jiajing. The essence of JSP database development examples [M]. Beijing: Electronic Industry Press, 2005.1.

[4] Bruce Ecke. JAVA programming thought (Thinking in Java) [M]. Mechanical Industry Press, 2002.9.

[5] Geng Xiangyi, Zhang Yueping. JSP Practical Course [M]. Beijing: Tsinghua University Press, 2003.

Guess you like

Origin blog.csdn.net/m0_66999594/article/details/128678570