mirror of
https://github.com/201206030/novel-plus.git
synced 2025-07-04 16:26:40 +00:00
上传后台管理系统代码
This commit is contained in:
@ -0,0 +1,21 @@
|
||||
package com.java2nb.common.controller;
|
||||
|
||||
import com.java2nb.system.domain.UserToken;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import com.java2nb.common.utils.ShiroUtils;
|
||||
import com.java2nb.system.domain.UserDO;
|
||||
|
||||
@Controller
|
||||
public class BaseController {
|
||||
public UserDO getUser() {
|
||||
return ShiroUtils.getUser();
|
||||
}
|
||||
|
||||
public Long getUserId() {
|
||||
return getUser().getUserId();
|
||||
}
|
||||
|
||||
public String getUsername() {
|
||||
return getUser().getUsername();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user