实现对特定角色和特定路径拦截
This commit is contained in:
@@ -2,9 +2,11 @@ package top.fjy8018.shiro.controller;
|
||||
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
/**
|
||||
* 页面导航
|
||||
*
|
||||
* @author F嘉阳
|
||||
* @date 2018/7/6 10:57
|
||||
*/
|
||||
@@ -12,7 +14,14 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
public class NavController {
|
||||
|
||||
@RequestMapping("/index")
|
||||
public String index(){
|
||||
public String index() {
|
||||
return "index";
|
||||
}
|
||||
|
||||
@RequestMapping("/admin")
|
||||
@ResponseBody
|
||||
public String admin() {
|
||||
return "admin success";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user