AdminRoleInterface.php 708 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. namespace App\Models\Interfaces;
  3. interface AdminRoleInterface
  4. {
  5. /**
  6. * 与用户的多对多关系
  7. *
  8. * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
  9. */
  10. public function users();
  11. /**
  12. * 与权限的多对多关系
  13. *
  14. * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
  15. */
  16. public function perms();
  17. /**
  18. * 与菜单的多对多关系
  19. *
  20. * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
  21. */
  22. public function menus();
  23. /**
  24. * 保存权限
  25. *
  26. * @param mixed $inputPermissions
  27. *
  28. * @return void
  29. */
  30. public function savePermissions($inputPermissions);
  31. }