基于javaweb的SSM旅游景点门票管理系统(java+ssm+jsp+mysql)

运行环境

Java≥8、MySQL≥5.7、Tomcat≥8

开发工具

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

适用

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

功能说明

390023282402

400023282402

410023282402

420023282402

430023282402

基于javaweb的SSM旅游景点门票管理系统(java+ssm+jsp+mysql)

jsp+ssm(spring+springMVC+mybatis)+MySQL实现的在线旅游景点信息管理系统,系统主要实现的功能有:用户浏览搜索景点游玩路线、用户注册登录、下单预定旅游产品等。后台管理员可对旅游产品进行管理、包括旅游的主题、产品、用户、定制、订单等。

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
    @RequestMapping("/nav")
public String navigation(){
return "backend/nav";
}

@RequestMapping("userupdate")
public String userupdate(){
return "backend/user_update";
}

@RequestMapping("cuslist")
public String cuslist(){
return "backend/customization_list";
}

@RequestMapping("/themelist")
public String thememlist(){
return "backend/theme_list";
}

@RequestMapping("/fileupload")
public String fileupload(){
return "backend/fileupload";
}


}
package com.zzh.controller;



/**
* <p>
* 前端控制器
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
    @RequestMapping("/Searchtheme/{id}")
public String SearchTheme(@PathVariable("id") String id,Model model) {
//根据主题id找到主题列表
List<ThemeProduct> themeList = ithemeProductService.findBytid(id);
String pids="";
for(ThemeProduct theme:themeList) {
pids+=theme.getProductId()+",";
}
String ids = pids.substring(0,pids.length()-1);
List<Product> findInProductList = productService.findInProductList(ids.toString());
model.addAttribute("productListT",findInProductList);
System.out.println(findInProductList);
return "/index/themelist";
}
}
package com.zzh.service.impl;






@Service
public class PictureServiceImpl implements PictureService {

private static final Logger logging = LoggerFactory.getLogger(PictureServiceImpl.class);


@Value("${IMAGE_BASE_URL}")
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
@RequestMapping("/save")
@ResponseBody
public ServerResponse create(ProductSell productSell){
productSell.setCreateTime(new Date());
return ServerResponse.createBySuccess(productSell.insert());
}

/**
*修改
* @param id
* @param productSell
* @return
*/
@ResponseBody
@RequestMapping("/update/{id}")
public ServerResponse update(@PathVariable String id, ProductSell productSell){
productSell.setId(id);
productSell.setUpdateTime(new Date());
return ServerResponse.createByResult(productSell.updateById());
}

/**
* 删除
* @param id
* @return
*/
@ResponseBody
@RequestMapping("/delete/{id}")
public ServerResponse delete(@PathVariable String id){
ProductSell productSell=new ProductSell();
productSell.setId(id);
return ServerResponse.createByResult(productSell.deleteById());
}

/**
* 批量删除
* @param ids
* @return
*/
@ResponseBody
@RequestMapping("/delete")
public ServerResponse delete(String[] ids){
return ServerResponse.createByResult(productSellService.deleteBatchIds(Arrays.asList(ids)));
}

/**
* 批量新增
* @param productSells
* @return
*/
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
    public String navigation(){
return "backend/nav";
}

@RequestMapping("userupdate")
public String userupdate(){
return "backend/user_update";
}

@RequestMapping("cuslist")
public String cuslist(){
return "backend/customization_list";
}

@RequestMapping("/themelist")
public String thememlist(){
return "backend/theme_list";
}

@RequestMapping("/fileupload")
public String fileupload(){
return "backend/fileupload";
}


}
package com.zzh.controller;



/**
* <p>
* 前端控制器
* </p>
*
*/
@Controller
@RequestMapping("/theme")
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
    @Override
public boolean preHandle(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, Object o) throws Exception {
StringBuffer requestURL = httpServletRequest.getRequestURL();
System.out.println(requestURL);
User user = (User) httpServletRequest.getSession().getAttribute(Const.ADMIN_USER);
if (user==null){
System.out.println("尚未登录,调到登录页面");
httpServletResponse.sendRedirect("${pageContext.request.contextPath}/adminLoginView");
return false;
}
return true;
}

@Override
public void postHandle(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, Object o, ModelAndView modelAndView) throws Exception {
System.out.println("postHandle");
}

@Override
public void afterCompletion(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, Object o, Exception e) throws Exception {
System.out.println("afterCompletion");
}
}
package com.zzh.controller.backend;


/**
*/
@Controller
@RequestMapping("/admin")
public class BackendController {



@RequestMapping("/index")
public String indexView(Model model){

int usernum=new User().selectCount(null);
int pnum=new Product().selectCount(null);
int onum= new ProductOrder().selectCount(null);
int cusnum= new Customization().selectCount(null);
model.addAttribute("usernum",usernum);
model.addAttribute("pnum",pnum);
model.addAttribute("onum",onum);
model.addAttribute("cusnum",cusnum);


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