当前位置: 首页 > news >正文

网站开发 js网站建设中期怎么入账

网站开发 js,网站建设中期怎么入账,网页设计制作教程题库,企业展厅建设的原则末尾获取源码 开发语言#xff1a;Java Java开发工具#xff1a;JDK1.8 后端框架#xff1a;SSM 前端#xff1a;采用Vue技术开发 数据库#xff1a;MySQL5.7和Navicat管理工具结合 服务器#xff1a;Tomcat8.5 开发软件#xff1a;IDEA / Eclipse 是否Maven项目#x… 末尾获取源码 开发语言Java Java开发工具JDK1.8 后端框架SSM 前端采用Vue技术开发 数据库MySQL5.7和Navicat管理工具结合 服务器Tomcat8.5 开发软件IDEA / Eclipse 是否Maven项目是 目录 一、项目简介 二、系统功能 三、系统项目截图 管理员功能实现 作业信息管理 作业统计管理 作业批阅管理 教师功能实现 新增作业 新增教学资源 学生留言管理 学生功能实现 作业信息 教学资源 通知公告 四、核心代码 登录相关 文件上传 封装 一、项目简介 网络技术和计算机技术发展至今已经拥有了深厚的理论基础并在现实中进行了充分运用尤其是基于计算机运行的软件更是受到各界的关注。加上现在人们已经步入信息时代所以对于信息的宣传和管理就很关键。因此学生作业信息的管理计算机化系统化是必要的。设计开发在线作业管理系统不仅会节约人力和管理成本还会安全保存庞大的数据量对于学生作业信息的维护和检索也不需要花费很多时间非常的便利。 在线作业管理系统是在MySQL中建立数据表保存信息运用SSM框架和Java语言编写。并按照软件设计开发流程进行设计实现。系统具备友好性且功能完善。本系统实现了作业管理作业答案管理作业批阅管理教学资源管理作业提交管理以及作业统计等功能。 在线作业管理系统在让学生作业信息规范化的同时也能及时通过数据输入的有效性规则检测出错误数据让数据的录入达到准确性的目的进而提升在线作业管理系统提供的数据的可靠性让系统数据的错误率降至最低。 二、系统功能 前面所做的功能分析只是本系统的一个大概功能这部分需要在此基础上进行各个模块的详细设计。 设计的管理员的详细功能见下图管理员登录进入本人后台之后管理作业作业答案作业批阅统计作业信息管理教师和学生。 设计的教师的详细功能见下图教师回复学生留言新增作业和教学资源管理作业提交作业答案以及作业批阅信息。 设计的学生的详细功能见下图学生在前台下载教师布置的作业提交已完成的作业播放教学资源视频查看通知公告。 三、系统项目截图 管理员功能实现 作业信息管理 管理员权限中的作业信息管理其运行效果见下图。管理员查看教师发布的作业可以修改作业信息查询作业。 作业统计管理 管理员权限中的作业统计管理其运行效果见下图。管理员查看作业提交人数以及合格人数导出作业统计信息。 作业批阅管理 管理员权限中的作业批阅管理其运行效果见下图。管理员查看学生作业批阅信息查看各位学生的作业成绩和是否及格信息可以根据作业是否及格查询作业批阅信息。 教师功能实现 新增作业 教师权限中的新增作业其运行效果见下图。教师新增作业需要描述作业信息上传作业文件。 新增教学资源 教师权限中的新增教学资源其运行效果见下图。教师分享教学资源需要上传教学资源的文件或视频描述教学资源信息即可提交。 学生留言管理 教师权限中的学生留言管理其运行效果见下图。学生选择教师进行留言内容的提交该教师在自己的操作后台会查看并且还能回复。 学生功能实现 作业信息 学生权限中的作业信息其运行效果见下图。学生下载作业文件完成作业之后在本页面上交作业。 教学资源 学生权限中的教学资源其运行效果见下图。学生收藏教学资源播放教学资源视频。 通知公告 学生权限中的通知公告其运行效果见下图。学生点击公告标题即可查看公告内容。 四、核心代码 登录相关 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{Autowiredprivate UserService userService;Autowiredprivate TokenService tokenService;/*** 登录*/IgnoreAuthPostMapping(value /login)public R login(String username, String password, String captcha, HttpServletRequest request) {UserEntity user userService.selectOne(new EntityWrapperUserEntity().eq(username, username));if(usernull || !user.getPassword().equals(password)) {return R.error(账号或密码不正确);}String token tokenService.generateToken(user.getId(),username, users, user.getRole());return R.ok().put(token, token);}/*** 注册*/IgnoreAuthPostMapping(value /register)public R register(RequestBody UserEntity user){ // ValidatorUtils.validateEntity(user);if(userService.selectOne(new EntityWrapperUserEntity().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(退出成功);}/*** 密码重置*/IgnoreAuthRequestMapping(value /resetPass)public R resetPass(String username, HttpServletRequest request){UserEntity user userService.selectOne(new EntityWrapperUserEntity().eq(username, username));if(usernull) {return R.error(账号不存在);}user.setPassword(123456);userService.update(user,null);return R.ok(密码已重置为123456);}/*** 列表*/RequestMapping(/page)public R page(RequestParam MapString, Object params,UserEntity user){EntityWrapperUserEntity ew new EntityWrapperUserEntity();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){EntityWrapperUserEntity ew new EntityWrapperUserEntity();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 EntityWrapperUserEntity().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);userService.updateById(user);//全部更新return R.ok();}/*** 删除*/RequestMapping(/delete)public R delete(RequestBody Long[] ids){userService.deleteBatchIds(Arrays.asList(ids));return R.ok();} }文件上传 package com.controller;import java.io.File; import java.io.FileNotFoundException; import java.io.IOException; import java.util.Arrays; import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.Random; import java.util.UUID;import org.apache.commons.io.FileUtils; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpHeaders; import org.springframework.http.HttpStatus; import org.springframework.http.MediaType; import org.springframework.http.ResponseEntity; import org.springframework.util.ResourceUtils; 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 org.springframework.web.multipart.MultipartFile;import com.annotation.IgnoreAuth; import com.baomidou.mybatisplus.mapper.EntityWrapper; import com.entity.ConfigEntity; import com.entity.EIException; import com.service.ConfigService; import com.utils.R;/*** 上传文件映射表*/ RestController RequestMapping(file) SuppressWarnings({unchecked,rawtypes}) public class FileController{Autowiredprivate ConfigService configService;/*** 上传文件*/RequestMapping(/upload)public R upload(RequestParam(file) MultipartFile file,String type) throws Exception {if (file.isEmpty()) {throw new EIException(上传文件不能为空);}String fileExt file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(.)1);File path new File(ResourceUtils.getURL(classpath:static).getPath());if(!path.exists()) {path new File();}File upload new File(path.getAbsolutePath(),/upload/);if(!upload.exists()) {upload.mkdirs();}String fileName new Date().getTime().fileExt;File dest new File(upload.getAbsolutePath()/fileName);file.transferTo(dest);FileUtils.copyFile(dest, new File(C:\\Users\\Desktop\\jiadian\\springbootl7own\\src\\main\\resources\\static\\upload/fileName));if(StringUtils.isNotBlank(type) type.equals(1)) {ConfigEntity configEntity configService.selectOne(new EntityWrapperConfigEntity().eq(name, faceFile));if(configEntitynull) {configEntity new ConfigEntity();configEntity.setName(faceFile);configEntity.setValue(fileName);} else {configEntity.setValue(fileName);}configService.insertOrUpdate(configEntity);}return R.ok().put(file, fileName);}/*** 下载文件*/IgnoreAuthRequestMapping(/download)public ResponseEntitybyte[] download(RequestParam String fileName) {try {File path new File(ResourceUtils.getURL(classpath:static).getPath());if(!path.exists()) {path new File();}File upload new File(path.getAbsolutePath(),/upload/);if(!upload.exists()) {upload.mkdirs();}File file new File(upload.getAbsolutePath()/fileName);if(file.exists()){/*if(!fileService.canRead(file, SessionManager.getSessionUser())){getResponse().sendError(403);}*/HttpHeaders headers new HttpHeaders();headers.setContentType(MediaType.APPLICATION_OCTET_STREAM); headers.setContentDispositionFormData(attachment, fileName); return new ResponseEntitybyte[](FileUtils.readFileToByteArray(file),headers, HttpStatus.CREATED);}} catch (IOException e) {e.printStackTrace();}return new ResponseEntitybyte[](HttpStatus.INTERNAL_SERVER_ERROR);}}封装 package com.utils;import java.util.HashMap; import java.util.Map;/*** 返回数据*/ public class R extends HashMapString, Object {private static final long serialVersionUID 1L;public R() {put(code, 0);}public static R error() {return error(500, 未知异常请联系管理员);}public static R error(String msg) {return error(500, msg);}public static R error(int code, String msg) {R r new R();r.put(code, code);r.put(msg, msg);return r;}public static R ok(String msg) {R r new R();r.put(msg, msg);return r;}public static R ok(MapString, Object map) {R r new R();r.putAll(map);return r;}public static R ok() {return new R();}public R put(String key, Object value) {super.put(key, value);return this;} }
http://www.hkea.cn/news/14577316/

相关文章:

  • 深圳网站设计哪家公司好海南建站中心
  • 专门做孩子早教的网站企业展示网站案例
  • 建行网站用户名是什么大学生兼职网站开发
  • 大连网站开发需要多少钱wordpress首页排序
  • wordpress做的好的网站陕西教育建设信息网站
  • 怎么创建wordpress站点网络推广培训教程
  • 企业网站的劣势下载一个网站
  • 义乌网站建设和制作网站建设前期如何规划
  • 如何开发网站平台有没有免费建站
  • 湖南做网站 就问磐石网络专业网站服务器ip查询
  • 网站页面上的悬浮窗怎么做湖南专业关键词优化
  • 网站建设为什么需要备案网站建设合同付款方式
  • 网站开发研发设计主播网站怎么建设
  • 织梦模板网站源码公共服务平台网站建设方案
  • 洛阳网站改版维护公司wordpress翻页方式
  • 十大免费网站模板网站网页制作的公司选时代创信
  • 中铁建设集团网站作文网址
  • 怎么做网站demo怎么自己制作公众号
  • 网站seo啥意思怎么做西昌手机网
  • 网站设计和策划的步骤是什么武进网站建设方案
  • c 手机版网站开发wordpress照片管理
  • 衡水哪家制作网站好wordpress能恢复数据库吗
  • 高端网站制作技术可以看各种直播平台的软件
  • 网站源码模块网站自己做推广
  • ts431p 做网站网站的建设会计入哪个科目
  • 网站盗号怎么做seo产品是什么意思
  • 东莞网站建设手袋加工手机网站自动跳转怎么解决
  • 济南网站推广服务网页制作软件属于什么软件
  • 网站制作设计报价佛山建网站哪里好
  • 自己做的网站怎么设置文件下载企业cms开源