mirror of https://github.com/halo-dev/halo
Change journal to journals.
parent
2d64b5c329
commit
1a1d3a152d
|
@ -28,7 +28,7 @@ import static org.springframework.data.domain.Sort.Direction.DESC;
|
||||||
*/
|
*/
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@Controller
|
@Controller
|
||||||
@RequestMapping(value = "/journal")
|
@RequestMapping(value = "/journals")
|
||||||
public class ContentJournalController {
|
public class ContentJournalController {
|
||||||
|
|
||||||
private final JournalService journalService;
|
private final JournalService journalService;
|
||||||
|
@ -56,8 +56,8 @@ public class ContentJournalController {
|
||||||
* @return template path: theme/{theme}/journal.ftl
|
* @return template path: theme/{theme}/journal.ftl
|
||||||
*/
|
*/
|
||||||
@GetMapping
|
@GetMapping
|
||||||
public String journal(Model model) {
|
public String journals(Model model) {
|
||||||
return this.journal(model, 1, Sort.by(DESC, "createTime"));
|
return this.journals(model, 1, Sort.by(DESC, "createTime"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ public class ContentJournalController {
|
||||||
* @return template path: theme/{theme}/journal.ftl
|
* @return template path: theme/{theme}/journal.ftl
|
||||||
*/
|
*/
|
||||||
@GetMapping(value = "page/{page}")
|
@GetMapping(value = "page/{page}")
|
||||||
public String journal(Model model,
|
public String journals(Model model,
|
||||||
@PathVariable(value = "page") Integer page,
|
@PathVariable(value = "page") Integer page,
|
||||||
@SortDefault(sort = "createTime", direction = DESC) Sort sort) {
|
@SortDefault(sort = "createTime", direction = DESC) Sort sort) {
|
||||||
log.debug("Requested journal page, sort info: [{}]", sort);
|
log.debug("Requested journal page, sort info: [{}]", sort);
|
||||||
|
@ -85,6 +85,6 @@ public class ContentJournalController {
|
||||||
model.addAttribute("is_journal", true);
|
model.addAttribute("is_journal", true);
|
||||||
model.addAttribute("journals", journals);
|
model.addAttribute("journals", journals);
|
||||||
model.addAttribute("rainbow", rainbow);
|
model.addAttribute("rainbow", rainbow);
|
||||||
return themeService.render("journal");
|
return themeService.render("journals");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue