shop++采用了Apache shiro安全框架,为系统新添加的模块配置管理权限的方法以下:html
1、在/src/applicationContext-shiro.xml中配置权限路径数据库
<property name="filterChainDefinitions">安全
<value>app
/admin/ = anon框架
/admin/index.jsp = anonjsp
/admin/login.jsp = authcspa
/admin/logout.jsp = logoutxml
/admin/common/captcha.jhtml = anonhtm
/admin/product/** = perms["admin:product"]it
/admin/** = authc
</value>
</property>
/admin/product/** 表示须要进行权限管理的路径,**表明全部下级目录
perms["admin:product"] admin:product权限标识
2、在数据库xx_role_authority表中添加相应权限,也可在/WEB-INF/template/admin/role/edit.ftl中添加相应权限选择项