• 大小: 27.61MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-07-15
  • 语言: 其他
  • 标签:

资源简介

课堂教学质量评价系统

资源截图

代码片段和文件信息

package com.controller;

import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.servlet.ModelAndView;

import com.entity.ClassAndUser;
import com.entity.ClassEvaluation;
import com.entity.ClassInfo;
import com.entity.Department;
import com.entity.EvaItems;
import com.entity.UploadVo;
import com.entity.User;
import com.entity.UserRole;
import com.service.ClassService;
import com.service.DepartmentService;
import com.service.UserService;
import com.util.ExcelMultipartFile;


/**
 * 用户请求处理层
 */
@Controller
@RequestMapping(“/user“)
public class ALLController {
@Autowired
private UserService userService;
@Autowired
private ClassService classService; 
@Autowired 
private DepartmentService departmentService;

@RequestMapping(“/user“)
public String user() throws Exception {
return “user/admin_login“;
}

/**
 * 用户登录
 */
@RequestMapping(“/login.action“)
@ResponseBody
public void login(HttpServletRequest request HttpServletResponse response String username String password) throws Exception {
response.setCharacterEncoding(“UTF-8“);
response.setHeader(“content-type“ “text/html;charset=UTF-8“);
User user = userService.getUserByLogin(username password);
String info = ““;
HttpSession session = request.getSession();
if (user != null) {
session.setAttribute(“username“ user.getUsername());
session.setAttribute(“userId“ user.getId());
info = “登录成功“;
// request.setAttribute(“user“ user);
// request.getRequestDispatcher(“/user/userlist.action“).forward(request response);
response.getWriter().print(user.getId());
} else {
info = “登录失败,请确认帐号或密码是否正确!“;
response.getWriter().print(info);
}
}

/**
 * 显示用户操作界面
 */
@RequestMapping(“/userlist.action“)
@ResponseBody
public ModelAndView userlist(Model model HttpServletRequest request HttpServletResponse response Long userIdString btn) throws Exception {
User user = userService.getUserById(userId);
model.addAttribute(“user“ user);
//获取教师对应课程(id)列表,供获取二维码使用
User userQuery = new User();
userQuery.setId(userId);
List classList = new ArrayList();
classList = classService.getClassInfoByUserId(userQuery);
model.addAttribute(“classLis

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       6158  2017-04-26 10:34  EvaluationSystem\.classpath

     文件       1049  2017-04-22 02:32  EvaluationSystem\.project

     文件        500  2016-09-03 14:00  EvaluationSystem\.settings\.jsdtscope

     文件         57  2016-09-03 14:34  EvaluationSystem\.settings\org.eclipse.core.resources.prefs

     文件        364  2016-09-03 14:00  EvaluationSystem\.settings\org.eclipse.jdt.core.prefs

     文件        584  2017-04-22 02:32  EvaluationSystem\.settings\org.eclipse.wst.common.component

     文件        345  2016-09-03 14:00  EvaluationSystem\.settings\org.eclipse.wst.common.project.facet.core.xml

     文件         49  2016-09-03 14:00  EvaluationSystem\.settings\org.eclipse.wst.jsdt.ui.superType.container

     文件          6  2016-09-03 14:00  EvaluationSystem\.settings\org.eclipse.wst.jsdt.ui.superType.name

     文件        119  2017-04-24 01:56  EvaluationSystem\config\db.properties

     文件        234  2016-09-03 14:02  EvaluationSystem\config\log4j.properties

     文件        369  2016-09-03 14:30  EvaluationSystem\config\mybatis\sqlMapConfig.xml

     文件       2243  2016-11-11 14:12  EvaluationSystem\config\spring\applicationContext-dao.xml

     文件       1166  2017-04-24 10:34  EvaluationSystem\config\spring\applicationContext-service.xml

     文件       2036  2016-09-03 14:30  EvaluationSystem\config\spring\applicationContext-transaction.xml

     文件       2297  2017-04-24 10:59  EvaluationSystem\config\spring\springmvc.xml

     文件      14136  2017-06-16 09:58  EvaluationSystem\config\zcx.sql

     文件      25337  2017-04-29 12:43  EvaluationSystem\src\com\controller\ALLController.java

     文件        658  2017-04-26 22:00  EvaluationSystem\src\com\entity\ClassAndUser.java

     文件       1761  2017-04-26 19:34  EvaluationSystem\src\com\entity\ClassEvaluation.java

     文件       2177  2017-04-25 14:29  EvaluationSystem\src\com\entity\ClassInfo.java

     文件        441  2017-04-22 18:55  EvaluationSystem\src\com\entity\Department.java

     文件       1272  2017-04-26 17:47  EvaluationSystem\src\com\entity\EvaItems.java

     文件        451  2017-04-24 14:29  EvaluationSystem\src\com\entity\UploadVo.java

     文件       4085  2017-04-26 19:01  EvaluationSystem\src\com\entity\User.java

     文件        303  2017-04-23 20:21  EvaluationSystem\src\com\entity\UserRole.java

     文件       1459  2017-04-26 22:10  EvaluationSystem\src\com\mapper\ClassMapper.java

     文件       4077  2017-04-26 22:17  EvaluationSystem\src\com\mapper\ClassMapper.xml

     文件        219  2017-04-22 18:54  EvaluationSystem\src\com\mapper\DepartmentMapper.java

     文件        318  2017-04-22 18:56  EvaluationSystem\src\com\mapper\DepartmentMapper.xml

............此处省略204个文件信息

评论

共有 条评论

相关资源