基于微信小程序的教学质量评价系统
摘要
随着信息技术在管理上越来越深入而广泛的应用,管理信息系统的实施在技术上已逐步成熟。本文介绍了基于微信小程序的教学质量评价系统的开发全过程。通过分析基于微信小程序的教学质量评价系统管理的不足,创建了一个计算机管理基于微信小程序的教学质量评价系统的方案。文章介绍了基于微信小程序的教学质量评价系统的系统分析部分,包括可行性分析等,系统设计部分主要介绍了系统功能设计和数据库设计。
本基于微信小程序的教学质量评价系统有管理员,教师,学生三个角色。管理员功能有个人中心,学生管理,教师管理,课程类别管理,课程信息管理,教学评价管理,系统管理。微信小程序部分教师和学生都可以注册登录,教师可以查看课程信息并且可以查看学生的评价,学生可以查看课程信息,教师信息,并且可以对教师的教学质量进行评价操作,还可以查看校园资讯。。因而具有一定的实用性。
本站后台采用Java的SSM框架进行后台管理开发,可以在浏览器上登录进行后台数据方面的管理,MySQL作为本地数据库,微信小程序用到了微信开发者工具,充分保证系统的稳定性。系统具有界面清晰、操作简单,功能齐全的特点,使得基于微信小程序的教学质量评价系统管理工作系统化、规范化。
关键词:基于微信小程序的教学质量评价系统;SSM框架;MYSQL数据库
基于微信小程序的教学质量评价系统+ssm后端源码和论文weixin174
演示视频:
基于微信小程序的教学质量评价系统+ssm后端源码和论文
Abstract
With the more and more in-depth and extensive application of information technology in management, the implementation of management information system has gradually matured in technology. This paper introduces the whole development process of teaching quality evaluation system based on wechat applet. By analyzing the shortcomings of teaching quality evaluation system management based on wechat applet, a scheme of computer management of teaching quality evaluation system based on wechat applet is created. This paper introduces the system analysis part of the teaching quality evaluation system based on wechat applet, including feasibility analysis. The system design part mainly introduces the system function design and database design.
The teaching quality evaluation system based on wechat applet has three roles: administrator, teacher and student. Administrator functions include personal center, student management, teacher management, course category management, course information management, teaching evaluation management and system management. Some teachers and students of wechat applet can register and log in. Teachers can view course information and students' evaluation. Students can view course information and teachers' information, evaluate teachers' teaching quality, and view campus information.. Therefore, it has certain practicability.
The background of this site adopts the SSM framework of Java for background management and development, which can log in on the browser for background data management. MySQL is a local database, and wechat applet uses wechat developer tools to fully ensure the stability of the system. The system has the characteristics of clear interface, simple operation and complete functions, which makes the management of teaching quality evaluation system based on wechat applet systematic and standardized.
Keywords:Teaching quality evaluation system based on wechat applet; SSM framework; Mysql database
文章来源:https://www.toymoban.com/news/detail-812931.html
文章来源地址https://www.toymoban.com/news/detail-812931.html
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 java.io.IOException;
import com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.format.annotation.DateTimeFormat;
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.JiaoxuepingjiaEntity;
import com.entity.view.JiaoxuepingjiaView;
import com.service.JiaoxuepingjiaService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;
/**
* 教学评价
* 后端接口
* @author
* @email
* @date 2022-02-06 14:26:56
*/
@RestController
@RequestMapping("/jiaoxuepingjia")
public class JiaoxuepingjiaController {
@Autowired
private JiaoxuepingjiaService jiaoxuepingjiaService;
/**
* 后端列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map<String, Object> params,JiaoxuepingjiaEntity jiaoxuepingjia,
HttpServletRequest request){
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
jiaoxuepingjia.setShoukejiaoshi((String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
jiaoxuepingjia.setXuehao((String)request.getSession().getAttribute("username"));
}
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
PageUtils page = jiaoxuepingjiaService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiaoxuepingjia), params), params));
return R.ok().put("data", page);
}
/**
* 前端列表
*/
@RequestMapping("/list")
public R list(@RequestParam Map<String, Object> params,JiaoxuepingjiaEntity jiaoxuepingjia,
HttpServletRequest request){
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
jiaoxuepingjia.setShoukejiaoshi((String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
jiaoxuepingjia.setXuehao((String)request.getSession().getAttribute("username"));
}
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
PageUtils page = jiaoxuepingjiaService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, jiaoxuepingjia), params), params));
return R.ok().put("data", page);
}
/**
* 列表
*/
@RequestMapping("/lists")
public R list( JiaoxuepingjiaEntity jiaoxuepingjia){
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
ew.allEq(MPUtil.allEQMapPre( jiaoxuepingjia, "jiaoxuepingjia"));
return R.ok().put("data", jiaoxuepingjiaService.selectListView(ew));
}
/**
* 查询
*/
@RequestMapping("/query")
public R query(JiaoxuepingjiaEntity jiaoxuepingjia){
EntityWrapper< JiaoxuepingjiaEntity> ew = new EntityWrapper< JiaoxuepingjiaEntity>();
ew.allEq(MPUtil.allEQMapPre( jiaoxuepingjia, "jiaoxuepingjia"));
JiaoxuepingjiaView jiaoxuepingjiaView = jiaoxuepingjiaService.selectView(ew);
return R.ok("查询教学评价成功").put("data", jiaoxuepingjiaView);
}
/**
* 后端详情
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id){
JiaoxuepingjiaEntity jiaoxuepingjia = jiaoxuepingjiaService.selectById(id);
return R.ok().put("data", jiaoxuepingjia);
}
/**
* 前端详情
*/
@IgnoreAuth
@RequestMapping("/detail/{id}")
public R detail(@PathVariable("id") Long id){
JiaoxuepingjiaEntity jiaoxuepingjia = jiaoxuepingjiaService.selectById(id);
return R.ok().put("data", jiaoxuepingjia);
}
/**
* 后端保存
*/
@RequestMapping("/save")
public R save(@RequestBody JiaoxuepingjiaEntity jiaoxuepingjia, HttpServletRequest request){
jiaoxuepingjia.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(jiaoxuepingjia);
jiaoxuepingjiaService.insert(jiaoxuepingjia);
return R.ok();
}
/**
* 前端保存
*/
@RequestMapping("/add")
public R add(@RequestBody JiaoxuepingjiaEntity jiaoxuepingjia, HttpServletRequest request){
jiaoxuepingjia.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(jiaoxuepingjia);
jiaoxuepingjia.setUserid((Long)request.getSession().getAttribute("userId"));
jiaoxuepingjiaService.insert(jiaoxuepingjia);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
public R update(@RequestBody JiaoxuepingjiaEntity jiaoxuepingjia, HttpServletRequest request){
//ValidatorUtils.validateEntity(jiaoxuepingjia);
jiaoxuepingjiaService.updateById(jiaoxuepingjia);//全部更新
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
jiaoxuepingjiaService.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<JiaoxuepingjiaEntity> wrapper = new EntityWrapper<JiaoxuepingjiaEntity>();
if(map.get("remindstart")!=null) {
wrapper.ge(columnName, map.get("remindstart"));
}
if(map.get("remindend")!=null) {
wrapper.le(columnName, map.get("remindend"));
}
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
wrapper.eq("shoukejiaoshi", (String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
wrapper.eq("xuehao", (String)request.getSession().getAttribute("username"));
}
int count = jiaoxuepingjiaService.selectCount(wrapper);
return R.ok().put("count", count);
}
/**
* (按值统计)
*/
@RequestMapping("/value/{xColumnName}/{yColumnName}")
public R value(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName,HttpServletRequest request) {
Map<String, Object> params = new HashMap<String, Object>();
params.put("xColumn", xColumnName);
params.put("yColumn", yColumnName);
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
ew.eq("shoukejiaoshi", (String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
ew.eq("xuehao", (String)request.getSession().getAttribute("username"));
}
List<Map<String, Object>> result = jiaoxuepingjiaService.selectValue(params, ew);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
for(Map<String, Object> m : result) {
for(String k : m.keySet()) {
if(m.get(k) instanceof Date) {
m.put(k, sdf.format((Date)m.get(k)));
}
}
}
return R.ok().put("data", result);
}
/**
* (按值统计)时间统计类型
*/
@RequestMapping("/value/{xColumnName}/{yColumnName}/{timeStatType}")
public R valueDay(@PathVariable("yColumnName") String yColumnName, @PathVariable("xColumnName") String xColumnName, @PathVariable("timeStatType") String timeStatType,HttpServletRequest request) {
Map<String, Object> params = new HashMap<String, Object>();
params.put("xColumn", xColumnName);
params.put("yColumn", yColumnName);
params.put("timeStatType", timeStatType);
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
ew.eq("shoukejiaoshi", (String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
ew.eq("xuehao", (String)request.getSession().getAttribute("username"));
}
List<Map<String, Object>> result = jiaoxuepingjiaService.selectTimeStatValue(params, ew);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
for(Map<String, Object> m : result) {
for(String k : m.keySet()) {
if(m.get(k) instanceof Date) {
m.put(k, sdf.format((Date)m.get(k)));
}
}
}
return R.ok().put("data", result);
}
/**
* 分组统计
*/
@RequestMapping("/group/{columnName}")
public R group(@PathVariable("columnName") String columnName,HttpServletRequest request) {
Map<String, Object> params = new HashMap<String, Object>();
params.put("column", columnName);
EntityWrapper<JiaoxuepingjiaEntity> ew = new EntityWrapper<JiaoxuepingjiaEntity>();
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("jiaoshi")) {
ew.eq("shoukejiaoshi", (String)request.getSession().getAttribute("username"));
}
if(tableName.equals("xuesheng")) {
ew.eq("xuehao", (String)request.getSession().getAttribute("username"));
}
List<Map<String, Object>> result = jiaoxuepingjiaService.selectGroup(params, ew);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
for(Map<String, Object> m : result) {
for(String k : m.keySet()) {
if(m.get(k) instanceof Date) {
m.put(k, sdf.format((Date)m.get(k)));
}
}
}
return R.ok().put("data", result);
}
}
package com.controller;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Date;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
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.ResponseBody;
import org.springframework.web.bind.annotation.RestController;
import com.annotation.IgnoreAuth;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.entity.TokenEntity;
import com.entity.UserEntity;
import com.service.TokenService;
import com.service.UserService;
import com.utils.CommonUtil;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.ValidatorUtils;
/**
* 登录相关
*/
@RequestMapping("users")
@RestController
public class UserController{
@Autowired
private UserService userService;
@Autowired
private TokenService tokenService;
/**
* 登录
*/
@IgnoreAuth
@PostMapping(value = "/login")
public R login(String username, String password, String captcha, HttpServletRequest request) {
UserEntity user = userService.selectOne(new EntityWrapper<UserEntity>().eq("username", username));
if(user==null || !user.getPassword().equals(password)) {
return R.error("账号或密码不正确");
}
String token = tokenService.generateToken(user.getId(),username, "users", user.getRole());
return R.ok().put("token", token);
}
/**
* 注册
*/
@IgnoreAuth
@PostMapping(value = "/register")
public R register(@RequestBody UserEntity user){
// ValidatorUtils.validateEntity(user);
if(userService.selectOne(new EntityWrapper<UserEntity>().eq("username", user.getUsername())) !=null) {
return R.error("用户已存在");
}
userService.insert(user);
return R.ok();
}
/**
* 退出
*/
@GetMapping(value = "logout")
public R logout(HttpServletRequest request) {
request.getSession().invalidate();
return R.ok("退出成功");
}
/**
* 密码重置
*/
@IgnoreAuth
@RequestMapping(value = "/resetPass")
public R resetPass(String username, HttpServletRequest request){
UserEntity user = userService.selectOne(new EntityWrapper<UserEntity>().eq("username", username));
if(user==null) {
return R.error("账号不存在");
}
user.setPassword("123456");
userService.update(user,null);
return R.ok("密码已重置为:123456");
}
/**
* 列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map<String, Object> params,UserEntity user){
EntityWrapper<UserEntity> ew = new EntityWrapper<UserEntity>();
PageUtils page = userService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.allLike(ew, user), params), params));
return R.ok().put("data", page);
}
/**
* 列表
*/
@RequestMapping("/list")
public R list( UserEntity user){
EntityWrapper<UserEntity> ew = new EntityWrapper<UserEntity>();
ew.allEq(MPUtil.allEQMapPre( user, "user"));
return R.ok().put("data", userService.selectListView(ew));
}
/**
* 信息
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") String id){
UserEntity user = userService.selectById(id);
return R.ok().put("data", user);
}
/**
* 获取用户的session用户信息
*/
@RequestMapping("/session")
public R getCurrUser(HttpServletRequest request){
Long id = (Long)request.getSession().getAttribute("userId");
UserEntity user = userService.selectById(id);
return R.ok().put("data", user);
}
/**
* 保存
*/
@PostMapping("/save")
public R save(@RequestBody UserEntity user){
// ValidatorUtils.validateEntity(user);
if(userService.selectOne(new EntityWrapper<UserEntity>().eq("username", user.getUsername())) !=null) {
return R.error("用户已存在");
}
userService.insert(user);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
public R update(@RequestBody UserEntity user){
// ValidatorUtils.validateEntity(user);
UserEntity u = userService.selectOne(new EntityWrapper<UserEntity>().eq("username", user.getUsername()));
if(u!=null && u.getId()!=user.getId() && u.getUsername().equals(user.getUsername())) {
return R.error("用户名已存在。");
}
userService.updateById(user);//全部更新
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
userService.deleteBatchIds(Arrays.asList(ids));
return R.ok();
}
}
到了这里,关于基于微信小程序的教学质量评价系统+ssm后端源码和论文的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!