——————————DescriptionStart——————————
运行环境
Java≥8、MySQL≥5.7、Tomcat≥8
开发工具
eclipse/idea/myeclipse/sts等均可配置运行
适用
课程设计,大作业,毕业设计,项目练习,学习演示等
功能说明







基于javaweb的SSM+Maven酒店管理系统(java+ssm+jsp+js+jquery+layui+mysql)
1 2 3 4 5 6 7 8 9 10 11 12
| 管理员 admin 123456
用户 用户账号1 123456 用户账号2 123456 用户账号3 123456 用户账号4 123456 用户账号5 123456 用户账号6 123456
|
酒店管理网站的主要使用者分为管理员和用户,实现功能包括:
管理员:用户管理、客房类型管理、酒店客房管理、客房预定管理、开放记录管理、退房结账管理、系统管理、系统公告、轮播图管理
用户:首页、个人中心、酒店客房管理、后台管理、修改密码,个人信息;客房预定管理、退房结账管理 ,收藏,评论
——————————CodeStart——————————
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
|
int count = yonghuService.selectCount(wrapper); return R.ok().put("count", count); }
}
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
| if(tableName.equals("yonghu")) { wrapper.eq("yonghuzhanghao", (String)request.getSession().getAttribute("username")); }
int count = kaifangjiluService.selectCount(wrapper); return R.ok().put("count", count); }
}
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
| * 通用接口 */ @RestController public class CommonController{ @Autowired private CommonService commonService;
private static AipFace client = null; @Autowired private ConfigService configService;
@RequestMapping("/option/{tableName}/{columnName}") @IgnoreAuth public R getOption(@PathVariable("tableName") String tableName, @PathVariable("columnName") String columnName,String level,String parent) { Map<String, Object> params = new HashMap<String, Object>(); params.put("table", tableName); params.put("column", columnName); if(StringUtils.isNotBlank(level)) { params.put("level", level); } if(StringUtils.isNotBlank(parent)) { params.put("parent", parent); } List<String> data = commonService.getOption(params); return R.ok().put("data", data); }
@RequestMapping("/follow/{tableName}/{columnName}") @IgnoreAuth public R getFollowByOption(@PathVariable("tableName") String tableName, @PathVariable("columnName") String columnName, @RequestParam String columnValue) { Map<String, Object> params = new HashMap<String, Object>(); params.put("table", tableName); params.put("column", columnName); params.put("columnValue", columnValue); Map<String, Object> result = commonService.getFollowByOption(params); return R.ok().put("data", result); }
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
| */ @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); }
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
| }
@RequestMapping("/lists") public R list( StoreupEntity storeup){ EntityWrapper<StoreupEntity> ew = new EntityWrapper<StoreupEntity>(); ew.allEq(MPUtil.allEQMapPre( storeup, "storeup")); return R.ok().put("data", storeupService.selectListView(ew)); }
@RequestMapping("/query") public R query(StoreupEntity storeup){ EntityWrapper< StoreupEntity> ew = new EntityWrapper< StoreupEntity>(); ew.allEq(MPUtil.allEQMapPre( storeup, "storeup")); StoreupView storeupView = storeupService.selectView(ew); return R.ok("查询收藏表成功").put("data", storeupView); }
@RequestMapping("/info/{id}") public R info(@PathVariable("id") Long id){ StoreupEntity storeup = storeupService.selectById(id); return R.ok().put("data", storeup); }
@IgnoreAuth @RequestMapping("/detail/{id}") public R detail(@PathVariable("id") Long id){ StoreupEntity storeup = storeupService.selectById(id); return R.ok().put("data", storeup); }
|
——————————PayStart——————————
项目链接:
https://javayms.github.io?id=321524190701201ko
https://javayms.pages.dev?id=321524190701201ko