使用的是什么网站模板,刷神马网站优化排名,wordpress 子站点函数,wordpress实现积分文章目录 项目介绍主要功能截图#xff1a;部分代码展示设计总结项目获取方式 #x1f345; 作者主页#xff1a;超级无敌暴龙战士塔塔开 #x1f345; 简介#xff1a;Java领域优质创作者#x1f3c6;、 简历模板、学习资料、面试题库【关注我#xff0c;都给你】 部分代码展示设计总结项目获取方式 作者主页超级无敌暴龙战士塔塔开 简介Java领域优质创作者、 简历模板、学习资料、面试题库【关注我都给你】 文末获取源码联系 项目介绍
基于ssm和微信小程序的健身房私教预约管理系统,java项目。 eclipse和idea都能打开运行。 推荐环境配置eclipse/idea jdk1.8 maven mysql 前端技术vueAjaxJson 后端技术SpringBootMyBatis 本系统共分为两个角色管理员、会员、教练。 主要功能有: 后台登录、首页、个人中心、会员管理、教练管理、健身课程管理、订单信息管理、课程分类管理、总结算统计管理、月结算统计管理、轮播图管理等。
前台登录注册、首页展示、健身课程列表、预约、订单信息查看等。
提供远程部署、代码讲解等服务 更多精品项目请查看主页
主要功能截图 部分代码展示 控制层ClockInNewController对登录用户信息的查询基于Cookie从cookie中提取用户信息并根据提取的用户字段在数据库中查询相关信息。 RequestMapping(/queryClockInAll2)public JsonObject queryClockInAll2(Clockinnew clockinnew, HttpServletRequest request,RequestParam(defaultValue 1) Integer pageNum,RequestParam(defaultValue 15) Integer pageSize){//获取当前得登录用户Userinfo userinfo (Userinfo) request.getSession().getAttribute(user);String usernameuserinfo.getUsername();//根据username获取登录账号得业主idOwner ownerownerService.queryOwnerByName(username);clockinnew.setOwnerId(owner.getId());PageInfoClockinnew pageInfo clockinnewService.queryClockInAll(pageNum,pageSize,clockinnew);return new JsonObject(0,ok,pageInfo.getTotal(),pageInfo.getList());}核心接口封装具体方法方便对象的注入
package com.yx.service;import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.github.pagehelper.PageInfo;
import com.yx.model.Clockinnew;import java.util.Date;/*** p* 服务类* /p** author yx* since 2021-04-27*/
public interface IClockInNewService extends IServiceClockinnew {PageInfoClockinnew queryClockInAll(int pageNum, int pageSize, Clockinnew clockinnew);/*** 查询分页数据** param page 页码* param pageCount 每页条数* return IPageClockinnew*/IPageClockinnew findListByPage(Integer page, Integer pageCount);/*** 添加** param clockinnew * return int*/int add(Clockinnew clockinnew);/*** 删除** param id 主键* return int*/int delete(Long id);/*** 修改** param clockinnew * return int*/int updateData(Clockinnew clockinnew);/*** id查询数据** param id id* return Clockinnew*/Clockinnew findById(Long id);Date queryCountByOwnId(Integer ownerId);
} 针对登录接口进行讲解 首先是controller层 涉及登录自然是分不开session需要从session中提取用户判断该用户是否处于登录状态。其中密码是经过md5加密的固定的盐值加入到数据库中提高系统的安全行。 RequestMapping(value/login,method RequestMethod.POST)public String login(Model model, String name, String password){//throws ParseExceptionSubject subject SecurityUtils.getSubject();UsernamePasswordToken token new UsernamePasswordToken(name,password);try {subject.login(token);User us userService.getByName(name);String lastLoginTime ;if(us!null){SimpleDateFormat sdf new SimpleDateFormat(yyyy-MM-dd HH:mm:ss);//上次时间Date time us.getLasttime();lastLoginTime sdf.format(time);//新时间String format sdf.format(new Date());//string转date 不处理时间格式会不理想ParsePosition pos new ParsePosition(0);Date strtodate sdf.parse(format, pos);us.setLasttime(strtodate);userService.update(us);}if (us.getStatus()1){Session sessionsubject.getSession();session.setAttribute(subject, subject);session.setAttribute(lastLoginTime,lastLoginTime);return redirect:index;}else {model.addAttribute(error, 账号已被停用);return /login;}} catch (AuthenticationException e) {model.addAttribute(error, 验证失败);return /login;}}接下来就是impl实现类可根据获得的参数进行条件查询。 当然具体的查询语句一般都不会直接在implement类中写而是将其写在封装好的mapper的xml文件中xml文件又映射对应的mapper文件。 而真正起作用的是mapper中的sql语句在implement实现类中只是对mapper进行注入。 Overridepublic User getByName(String name) {UserExample example new UserExample();example.createCriteria().andNameEqualTo(name);ListUser users userMapper.selectByExample(example);if (users.isEmpty()) return null;return users.get(0);}UserMapper.java package com.byh.biyesheji.dao;import com.byh.biyesheji.pojo.User;
import com.byh.biyesheji.pojo.UserExample;import java.util.List;public interface UserMapper extends SysDaoUser{ListUser selectByExample(UserExample example);/*** 停用管理员账号* param name*/void enableStatus(String name);/*** 开启管理员账号* param name*/void stopStatus(String name);
}UserMapper.xml select idselectByExample resultMapBaseResultMap parameterTypecom.byh.biyesheji.pojo.UserExample selectif testdistinct distinct/ifinclude refidBase_Column_List /from userif test_parameter ! null include refidExample_Where_Clause //ifif testorderByClause ! null order by ${orderByClause}/if/select设计总结 通过对校园点餐系统的开发让我深刻明白开发一个程序软件需要经历的流程当确定要开发一个程序时我在开发期间对其功能进行合理的需求分析然后才是程序软件的功能的框架设计数据库的实体与数据表设计程序软件的功能详细界面实现以及程序的功能测试等进行全方位的细致考虑虽然在此过程中各个环节都遇到了大大小小的困难但是通过对这些问题进行反复的分析深入的思考借助各种相关文献资料提供的方法与解决思路成功解决面临的各个问题最后成功的让我开发的系统得以正常运行。在功能上面是基本可以满足用户对系统的操作但是这个程序软件也有许多方面是不足的因此在下一个时间阶段有几点需要改进的地方需要提出来它们分别是 1操作页面可以满足用户简易操作的要求但是在页面多样化设计层面上需要把一些比较丰富的设计结构考虑进来。 2程序软件的总体安全性能需要优化例如程序的退出安全性以及程序的并发性等问题都需要进行安全性升级让开发的产品与现实中的相关网站更贴合。 3需要对程序的数据结构方面程序的代码方面等进行优化让运行起来的程序可以保持稳定运行也让程序能够保证短时间内处理相关事务节省处理事务的时间提高事务处理的效率同时对服务器上资源占用的比例进行降低。 平台的开发一方面是对自身专业知识技能进行最终考核另一方面也是让自己学会独立解决程序开发过程中所遇到的问题掌握将理论知识运用于程序开发实践的方法。最终目标就是让系统更具人性化同时在逻辑设计上让系统能够更加的严谨。 获取源码联系 大家点赞、收藏、关注、评论啦 项目获取方式
精彩专栏推荐订阅在下方专栏 Java精品项目100套