AuthServiceFacade.php 751 B

1234567891011121314151617181920212223
  1. <?php
  2. namespace app\service\admin;
  3. use think\Facade;
  4. /**
  5. * 后台权限服务门面
  6. * @package app\service\admin
  7. * @method static mixed setNoNeedLogin($noNeedLogin) 设置不需要登录的方法名数组
  8. * @method static mixed setNoNeedAuth($noNeedAuth) 设置不需要鉴权的方法名数组
  9. * @method static mixed needLogin() 当前节点是否需要登录
  10. * @method static mixed needAuth() 当前节点是否需要鉴权
  11. * @method static mixed getAuthList($userId) 获取某后台管理员拥有的权限列表
  12. * @method static mixed hasAuth($userId, $node) 某用户是否拥有某个节点的权限
  13. */
  14. class AuthServiceFacade extends Facade
  15. {
  16. protected static function getFacadeClass()
  17. {
  18. return Auth::class;
  19. }
  20. }