基于javaweb的SpringBoot+MyBatis电影院售票购票电影票管理系统(前台、后台)(java+springboot+ssm+thymeleaf+html+mysql+maven)

运行环境

Java≥8、MySQL≥5.7

开发工具

eclipse/idea/myeclipse/sts等均可配置运行

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

功能说明

前台用户:查看电影列表、查看排版、选座购票、查看个人信息

后台管理员:管理电影排版,活动,会员,退票,影院,统计等

200123242502

192024513108

前台:

120123242502

130123242502

140123242502

150123242502

160123242502

170123242502

180123242502

后台:

030123242502

040123242502

050123242502

060123242502

070123242502

090123242502

100123242502

110123242502

技术框架

SpringBoot SpringMVC MyBatis Thymeleaf HTML JavaScript Ajax

基于javaweb的SpringBoot+MyBatis电影院售票购票电影票管理系统(前台、后台)(java+springboot+ssm+thymeleaf+html+mysql+maven)

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
    @RequestMapping(value = "/user/member")
public String getUserMember() {
return "userMember";
}

@RequestMapping(value = "/admin/vip/manage")
public String getAdminVipManage() { return "adminVipManage"; }

@RequestMapping(value = "/admin/refund/manage")
public String getAdminRefundManage() { return "adminRefundManage"; }

@RequestMapping(value="/user/info")
public String getUserInfo(){return "userInfo";}

@RequestMapping(value="/boss/manage")
public String getBossManage(){return "bossManage";}
}
package com.demo.controller.management;



/**排片管理
*/
@RestController
public class ScheduleController {
@Autowired
private ScheduleService scheduleService;

@RequestMapping(value = "/schedule/add", method = RequestMethod.POST)
public ResponseVO addSchedule(@RequestBody ScheduleForm scheduleForm){
return scheduleService.addSchedule(scheduleForm);
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
    public ResponseVO updateStrategy(@RequestParam int id,int chargeLimit ,int giftAmount)
{return vipService.changeVIP_Strategy(id,chargeLimit,giftAmount);}

@PostMapping("delete/strategy")
public ResponseVO deleteStrategy(@RequestParam int id){return vipService.deleteVIP_Strategy(id);}

@PostMapping("insert/history")
public ResponseVO insertHistory(@RequestBody historyItem history){return accountService.insertHistory(history); }

@GetMapping("get/by/money")
public ResponseVO getByMoney(@RequestParam int target){return vipService.getVipByMoney(target);}
}
package com.demo.controller.sales;


/**
*/
@RestController
@RequestMapping("/ticket")
public class TicketController {
@Autowired
TicketService ticketService;
@Autowired
AccountService accountService;
@PostMapping("/vip/buy")
public ResponseVO buyTicketByVIPCard(@RequestParam List<Integer> ticketId, @RequestParam int couponId){
return ticketService.completeByVIPCard(ticketId,couponId);
}

@PostMapping("/lockSeat")
public ResponseVO lockSeat(@RequestBody TicketForm ticketForm){
return ticketService.addTicket(ticketForm);
}
@PostMapping("/buy")
public ResponseVO buyTicket(@RequestParam List<Integer> ticketId,@RequestParam int couponId){
return ticketService.completeTicket(ticketId,couponId);
}
@GetMapping("/get/{userId}")
public ResponseVO getTicketByUserId(@PathVariable int userId){
return ticketService.getTicketByUser(userId);
}

@GetMapping("/get/occupiedSeats")
public ResponseVO getOccupiedSeats(@RequestParam int scheduleId){
return ticketService.getBySchedule(scheduleId);
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
    }
@RequestMapping(value = "/movie/{movieId}/unlike", method = RequestMethod.POST)
public ResponseVO unlikeMovie(@PathVariable int movieId,@RequestParam int userId){
return movieLikeService.unLikeMovie(userId,movieId);
}
@RequestMapping(value = "/movie/{movieId}/like/count", method = RequestMethod.GET)
public ResponseVO getMovieLikeCounts(@PathVariable int movieId){
return movieLikeService.getCountOfLikes(movieId);
}

@RequestMapping(value = "/movie/{movieId}/like/date", method = RequestMethod.GET)
public ResponseVO getMovieLikeCountByDate(@PathVariable int movieId){
return movieLikeService.getLikeNumsGroupByDate(movieId);
}

@RequestMapping(value = "/movie/search",method = RequestMethod.GET)
public ResponseVO getMovieByKeyword(@RequestParam String keyword){
return movieService.getMovieByKeyword(keyword);
}

@RequestMapping(value = "/movie/off/batch",method = RequestMethod.POST)
public ResponseVO pullOfBatchOfMovie(@RequestBody MovieBatchOffForm movieBatchOffForm){
return movieService.pullOfBatchOfMovie(movieBatchOffForm);
}

@RequestMapping(value = "/movie/update",method = RequestMethod.POST)
public ResponseVO updateMovie(@RequestBody MovieForm updateMovieForm){
return movieService.updateMovie(updateMovieForm);
}




}
package com.demo.controller.router;


/**
*/
@Controller
public class ViewController {
@RequestMapping(value = "/index")
public String getIndex() {
return "index";
}

@RequestMapping(value = "/signUp")
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
@RestController
public class ScheduleController {
@Autowired
private ScheduleService scheduleService;

@RequestMapping(value = "/schedule/add", method = RequestMethod.POST)
public ResponseVO addSchedule(@RequestBody ScheduleForm scheduleForm){
return scheduleService.addSchedule(scheduleForm);
}

@RequestMapping(value = "/schedule/update", method = RequestMethod.POST)
public ResponseVO updateSchedule(@RequestBody ScheduleForm scheduleForm){
return scheduleService.updateSchedule(scheduleForm);
}

@RequestMapping(value = "/schedule/search", method = RequestMethod.GET)
public ResponseVO searchSchedule(@RequestParam int hallId, @RequestParam Date startDate){
return scheduleService.searchScheduleSevenDays(hallId, startDate);
}

@RequestMapping(value = "/schedule/search/audience", method = RequestMethod.GET)
public ResponseVO searchAudienceSchedule(@RequestParam int movieId){
return scheduleService.searchAudienceSchedule(movieId);
}

@RequestMapping(value = "/schedule/view/set", method = RequestMethod.POST)
public ResponseVO setScheduleView(@RequestBody ScheduleViewForm scheduleViewForm){
return scheduleService.setScheduleView(scheduleViewForm);
}

@RequestMapping(value = "/schedule/view", method = RequestMethod.GET)
public ResponseVO getScheduleView(){
return scheduleService.getScheduleView();
}



@RequestMapping(value = "/schedule/delete/batch", method = RequestMethod.DELETE)
public ResponseVO deleteBatchOfSchedule(@RequestBody ScheduleBatchDeleteForm scheduleBatchDeleteForm){
return scheduleService.deleteBatchOfSchedule(scheduleBatchDeleteForm);
}

@RequestMapping(value = "/schedule/{id}", method = RequestMethod.GET)
public ResponseVO getScheduleById(@PathVariable int id){
return scheduleService.getScheduleById(id);
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

/**
*/
public class SessionInterceptor extends HandlerInterceptorAdapter {
@Override
public boolean preHandle(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, Object handler) throws Exception{
HttpSession session=httpServletRequest.getSession();
if(null!=session && null!=session.getAttribute(InterceptorConfiguration.SESSION_KEY)){
return true;
}
httpServletResponse.sendRedirect("/index");
return false;
}
}
package com.demo.controller.promotion;


/**
*/
@RestController
@RequestMapping("/coupon")
public class CouponController {

@Autowired
CouponService couponService;

@GetMapping("{userId}/get")
public ResponseVO getCoupons(@PathVariable int userId){
return couponService.getCouponsByUser(userId);
}

@GetMapping("/get/all")
public ResponseVO getAllCoupon(){return couponService.getAllCoupon();}

@PostMapping("/send")
public ResponseVO sendCoupon(@RequestParam int couponId,@RequestParam int[] userId){return couponService.sendCoupon(couponId,userId);}

}
package com.demo.controller.promotion;


项目链接:
https://javayms.github.io?id=400022511505106al
https://javayms.pages.dev?id=400022511505106al