| | |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | |
| | | /** |
| | | * @author wzy |
| | |
| | | return FebsUtil.view("modules/news/newsInfoList"); |
| | | } |
| | | |
| | | |
| | | @GetMapping("knowledge") |
| | | @RequiresPermissions("newsInfoList:view") |
| | | public String knowledge() { |
| | | return FebsUtil.view("modules/news/knowledgeList"); |
| | | } |
| | | |
| | | /** |
| | | * 新闻中心-新增 |
| | | * @return |
| | | */ |
| | | @GetMapping("newsInfoAdd") |
| | | @GetMapping("newsInfoAdd/{code}") |
| | | @RequiresPermissions("newsInfoAdd:add") |
| | | public String newsInfoAdd() { |
| | | public String newsInfoAdd(@PathVariable("code") String code, Model model) { |
| | | model.addAttribute("code", code); |
| | | return FebsUtil.view("modules/news/newsInfoAdd"); |
| | | } |
| | | |
| | |
| | | * @param model |
| | | * @return |
| | | */ |
| | | @GetMapping("newsInfoUpdate/{id}") |
| | | @GetMapping("newsInfoUpdate/{id}/{code}") |
| | | @RequiresPermissions("newsInfoUpdate:update") |
| | | public String newsInfoUpdate(@PathVariable long id, Model model) { |
| | | public String newsInfoUpdate(@PathVariable("id") long id, @PathVariable("code") String code, Model model) { |
| | | MallNewsInfo data = mallNewsInfoService.getNewsInfoById(id); |
| | | model.addAttribute("code", code); |
| | | model.addAttribute("newsInfo", data); |
| | | return FebsUtil.view("modules/news/newsInfoUpdate"); |
| | | } |