Postgraduate entrance examination information platform with the separation of front and back ends of Springboot+vue

Get the source code at the end of the article

Development language: Java

Development tools: IDEA/Eclipse

Database: MYSQL5.7

Application service:Tomcat7/Tomcat8

Use framework: springboot+vue

JDK version: jdk1.8

System functions include student front desk: home page, postgraduate entrance examination information, application guide, data information, forum information, my, jump to the background, shopping cart, customer service, administrator: homepage, personal center, postgraduate entrance examination information management, student management, application guide Management, data information management, data classification management, forum management, system management, order management, student background: home page, personal center, my collection management, order management and other functions.

System functional requirements analysis

When we carry out the development of any new website, it is necessary to carry out a complete requirements analysis, because we can only find out the quality of the system during the analysis process, and then decide whether to develop the system. For this postgraduate entrance examination information platform, its pre-analysis is very important, and we are conducting a demand analysis for developing this system to make students more satisfied in the use process, and finally convenient for everyone to use.

Demand analysis is an important part of a system, because it can take into account any problems in the system, and it also determines whether the system can run normally and whether students can be satisfied. The analysis determines the framework, functions and requirements of the entire system. And change the real design into objects and complete the modeling.

This subject requires the realization of a set of postgraduate entrance examination information platform, the system is mainly divided into front and back. It mainly includes the student front desk: home page, postgraduate entrance examination information, application guide, data information, forum information, mine, jump to the background, shopping cart, customer service,

Administrator: Home page, personal center, postgraduate entrance examination information management, student management, application guide management, data information management, data classification management, forum management, system management, order management,

Student background: home page, personal center, my collection management, order management and other functions.

Student front desk use case requirements are shown in the figure

Admin use case requirements are shown in the figure

 

The specific function structure diagram is as follows 

Database ER diagram

Student Information Entity Diagram

Data information management entity diagram

 

Application Guide Management Entity Diagram

 

Admin entity diagram

 

System implementation 

Student front desk function module

On the home page of the system, you can view the home page, postgraduate entrance examination information, application guide, data information, forum information, mine, jump to the background, shopping cart, customer service, etc., as shown in the figure

 

 

 

student registration

On the student registration page, complete the student registration by filling in the student number, password, student name, major, class, mobile phone, email and other information, as shown in the figure.

 

 

 Postgraduate entrance examination information

 

 Application Guide

 Data information

 

 mine

 

 

 

shopping cart 

Login design and implementation

Students and administrators enter their personal account and password to log in to the system. At this time, we search for some relevant information in the database of this system. If we enter an incorrect account and password, the database will automatically prompt an error. information, while prompting the user to re-enter the correct information. Website login renderings are shown in the figure 

admin module

The administrator mainly manages: home page, personal center, postgraduate entrance examination information management, student management, application guide management, data information management, data classification management, forum management, system management, order management, etc. The specific administrator management effect is as follows 

Research Information Management

After logging in to the system background, the administrator can modify, delete, and view the information management of the postgraduate entrance examination. The specific operation effect is shown in the figure below. 

student management 

The administrator enters the background to view, modify, and delete the student management information. The effect diagram of the student management function is shown in the figure.

 

Application Guide Management 

The administrator can modify, view, delete and other operations on the management information of the application guide. The management effect diagram of the application guide is as follows

 

Data information management 

The administrator can delete, modify, add and other specific operations to the data information management information. The effect diagram of data information management is as follows

 

Data classification management 

The administrator can add, view, delete, modify and other operations on the data classification management information. The effect of data classification management is as follows

 

Forum management 

Administrators can add, view, delete, and modify forum management information. Forum management renderings such as

 

System Management 

Administrators can add, view, delete, and modify system management information. The system management effect diagram is as follows

 

Order management 

 Administrators can add, view, delete, modify and other operations on order management. The order management effect diagram is as follows

Student background function module

Order management

Students enter the system to view the home page, personal center, my collection management, order management and other operations. Students can add and view order management information. The order management effect diagram is as follows 

My collection management 

After entering the system, students can view and delete my collections management. The effect of my collection management is as follows 

 

Personal information 

After entering the system, students can view and delete personal information. The effect of personal information is as follows

 

Part of the code:  

package com.controller;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Date;
import java.util.List;
import javax.servlet.http.HttpServletRequest;

import com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.annotation.IgnoreAuth;

import com.entity.BaokaozhinanEntity;
import com.entity.view.BaokaozhinanView;

import com.service.BaokaozhinanService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MPUtil;
import com.utils.CommonUtil;


/**
 * 报考指南
 * 后端接口
 * @author 
 * @email 
 * @date 2020-11-30 11:35:10
 */
@RestController
@RequestMapping("/baokaozhinan")
public class BaokaozhinanController {
    @Autowired
    private BaokaozhinanService baokaozhinanService;
    


    /**
     * 后端列表
     */
    @RequestMapping("/page")
    public R page(@RequestParam Map<String, Object> params,BaokaozhinanEntity baokaozhinan, HttpServletRequest request){
        EntityWrapper<BaokaozhinanEntity> ew = new EntityWrapper<BaokaozhinanEntity>();
		PageUtils page = baokaozhinanService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, baokaozhinan), params), params));

        return R.ok().put("data", page);
    }
    
    /**
     * 前端列表
     */
	@IgnoreAuth
    @RequestMapping("/list")
    public R list(@RequestParam Map<String, Object> params,BaokaozhinanEntity baokaozhinan, HttpServletRequest request){
        EntityWrapper<BaokaozhinanEntity> ew = new EntityWrapper<BaokaozhinanEntity>();
		PageUtils page = baokaozhinanService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, baokaozhinan), params), params));
        return R.ok().put("data", page);
    }

	/**
     * 列表
     */
    @RequestMapping("/lists")
    public R list( BaokaozhinanEntity baokaozhinan){
       	EntityWrapper<BaokaozhinanEntity> ew = new EntityWrapper<BaokaozhinanEntity>();
      	ew.allEq(MPUtil.allEQMapPre( baokaozhinan, "baokaozhinan")); 
        return R.ok().put("data", baokaozhinanService.selectListView(ew));
    }

	 /**
     * 查询
     */
    @RequestMapping("/query")
    public R query(BaokaozhinanEntity baokaozhinan){
        EntityWrapper< BaokaozhinanEntity> ew = new EntityWrapper< BaokaozhinanEntity>();
 		ew.allEq(MPUtil.allEQMapPre( baokaozhinan, "baokaozhinan")); 
		BaokaozhinanView baokaozhinanView =  baokaozhinanService.selectView(ew);
		return R.ok("查询报考指南成功").put("data", baokaozhinanView);
    }
	
    /**
     * 后端详情
     */
    @RequestMapping("/info/{id}")
    public R info(@PathVariable("id") String id){
        BaokaozhinanEntity baokaozhinan = baokaozhinanService.selectById(id);
        return R.ok().put("data", baokaozhinan);
    }

    /**
     * 前端详情
     */
	@IgnoreAuth
    @RequestMapping("/detail/{id}")
    public R detail(@PathVariable("id") String id){
        BaokaozhinanEntity baokaozhinan = baokaozhinanService.selectById(id);
        return R.ok().put("data", baokaozhinan);
    }
    



    /**
     * 后端保存
     */
    @RequestMapping("/save")
    public R save(@RequestBody BaokaozhinanEntity baokaozhinan, HttpServletRequest request){
    	baokaozhinan.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(baokaozhinan);
        baokaozhinanService.insert(baokaozhinan);
        return R.ok();
    }
    
    /**
     * 前端保存
     */
    @RequestMapping("/add")
    public R add(@RequestBody BaokaozhinanEntity baokaozhinan, HttpServletRequest request){
    	baokaozhinan.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
    	//ValidatorUtils.validateEntity(baokaozhinan);
        baokaozhinanService.insert(baokaozhinan);
        return R.ok();
    }

    /**
     * 修改
     */
    @RequestMapping("/update")
    public R update(@RequestBody BaokaozhinanEntity baokaozhinan, HttpServletRequest request){
        //ValidatorUtils.validateEntity(baokaozhinan);
        baokaozhinanService.updateById(baokaozhinan);//全部更新
        return R.ok();
    }
    

    /**
     * 删除
     */
    @RequestMapping("/delete")
    public R delete(@RequestBody Long[] ids){
        baokaozhinanService.deleteBatchIds(Arrays.asList(ids));
        return R.ok();
    }
    
    /**
     * 提醒接口
     */
	@RequestMapping("/remind/{columnName}/{type}")
	public R remindCount(@PathVariable("columnName") String columnName, HttpServletRequest request, 
						 @PathVariable("type") String type,@RequestParam Map<String, Object> map) {
		map.put("column", columnName);
		map.put("type", type);
		
		if(type.equals("2")) {
			SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
			Calendar c = Calendar.getInstance();
			Date remindStartDate = null;
			Date remindEndDate = null;
			if(map.get("remindstart")!=null) {
				Integer remindStart = Integer.parseInt(map.get("remindstart").toString());
				c.setTime(new Date()); 
				c.add(Calendar.DAY_OF_MONTH,remindStart);
				remindStartDate = c.getTime();
				map.put("remindstart", sdf.format(remindStartDate));
			}
			if(map.get("remindend")!=null) {
				Integer remindEnd = Integer.parseInt(map.get("remindend").toString());
				c.setTime(new Date());
				c.add(Calendar.DAY_OF_MONTH,remindEnd);
				remindEndDate = c.getTime();
				map.put("remindend", sdf.format(remindEndDate));
			}
		}
		
		Wrapper<BaokaozhinanEntity> wrapper = new EntityWrapper<BaokaozhinanEntity>();
		if(map.get("remindstart")!=null) {
			wrapper.ge(columnName, map.get("remindstart"));
		}
		if(map.get("remindend")!=null) {
			wrapper.le(columnName, map.get("remindend"));
		}


		int count = baokaozhinanService.selectCount(wrapper);
		return R.ok().put("count", count);
	}
	


}

 

Guess you like

Origin blog.csdn.net/m0_49113107/article/details/123931379