Controller中注解:
@RequiresAuthentication
@RequiresGuest
@RequiresPermissions("account:create")
@RequiresRoles("administrator")
@RequiresUser
Themleaf标签:
<shiro:principal />
<shiro:principal property="username" />
<shiro:hasRole name="admin"></shiro:hasRole>
原文地址:https://www.cnblogs.com/jack-zou/p/8508175.html
时间: 2024-10-22 15:52:31