|
@@ -36,12 +36,13 @@ public class ArticleController extends BaseController {
|
|
/**
|
|
/**
|
|
* 文章列表【旧center】
|
|
* 文章列表【旧center】
|
|
*/
|
|
*/
|
|
- @GetMapping("/info/center-{id}-1.html")
|
|
|
|
- public String toArticleList(@PathVariable("id") Integer id, final Model model) {
|
|
|
|
|
|
+ @GetMapping("/info/center-{id}-{pageNum}.html")
|
|
|
|
+ public String toArticleList(@PathVariable("id") Integer id, @PathVariable("id") Integer pageNum, final Model model) {
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("typeId", id);
|
|
model.addAttribute("typeId", id);
|
|
model.addAttribute("labelId", 0);
|
|
model.addAttribute("labelId", 0);
|
|
|
|
+ model.addAttribute("pageNum", pageNum);
|
|
//model.addAttribute("pagePath", String.format("/info/center-%s-1.html", id));
|
|
//model.addAttribute("pagePath", String.format("/info/center-%s-1.html", id));
|
|
return ARTICLE_LIST_PATH;
|
|
return ARTICLE_LIST_PATH;
|
|
}
|
|
}
|
|
@@ -49,12 +50,13 @@ public class ArticleController extends BaseController {
|
|
/**
|
|
/**
|
|
* 文章列表【旧label】
|
|
* 文章列表【旧label】
|
|
*/
|
|
*/
|
|
- @GetMapping("/info/label-{id}-1.html")
|
|
|
|
- public String toArticleLabel(@PathVariable("id") Integer id, final Model model) {
|
|
|
|
|
|
+ @GetMapping("/info/label-{id}-{pageNum}.html")
|
|
|
|
+ public String toArticleLabel(@PathVariable("id") Integer id, @PathVariable("id") Integer pageNum, final Model model) {
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("typeId", 0);
|
|
model.addAttribute("typeId", 0);
|
|
model.addAttribute("labelId", id);
|
|
model.addAttribute("labelId", id);
|
|
|
|
+ model.addAttribute("pageNum", pageNum);
|
|
//model.addAttribute("pagePath", String.format("/info/label-%s-1.html", id));
|
|
//model.addAttribute("pagePath", String.format("/info/label-%s-1.html", id));
|
|
return ARTICLE_LIST_PATH;
|
|
return ARTICLE_LIST_PATH;
|
|
}
|
|
}
|
|
@@ -62,12 +64,13 @@ public class ArticleController extends BaseController {
|
|
/**
|
|
/**
|
|
* 文章搜索结果
|
|
* 文章搜索结果
|
|
*/
|
|
*/
|
|
- @GetMapping("/info/search.html")
|
|
|
|
- public String toArticleSearch(final Model model) {
|
|
|
|
|
|
+ @GetMapping("/info/search-{pageNum}.html")
|
|
|
|
+ public String toArticleSearch(@PathVariable("id") Integer pageNum, final Model model) {
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
List<BaseLink> typeList = articleService.getArticleTypes();
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("articleType", typeList);
|
|
model.addAttribute("typeId", 0);
|
|
model.addAttribute("typeId", 0);
|
|
model.addAttribute("labelId", 0);
|
|
model.addAttribute("labelId", 0);
|
|
|
|
+ model.addAttribute("pageNum", pageNum);
|
|
//model.addAttribute("pagePath", "/info/search.html");
|
|
//model.addAttribute("pagePath", "/info/search.html");
|
|
return ARTICLE_LIST_PATH;
|
|
return ARTICLE_LIST_PATH;
|
|
}
|
|
}
|