메소드 | 설명 | |
---|---|---|
findByName ( string $name ) | Find a role by its name. | |
hasPermissionTo ( string | Spatie\Permission\Contracts\Permission $permission ) : boolean | Determine if the user may perform the given permission. | |
permissions ( ) : Illuminate\Database\Eloquent\Relations\BelongsToMany | A role may be given various permissions. | |
users ( ) : Illuminate\Database\Eloquent\Relations\BelongsToMany | A role may be assigned to various users. |
public static findByName ( string $name ) | ||
$name | string |
public hasPermissionTo ( string | Spatie\Permission\Contracts\Permission $permission ) : boolean | ||
$permission | string | Spatie\Permission\Contracts\Permission | |
리턴 | boolean |
public permissions ( ) : Illuminate\Database\Eloquent\Relations\BelongsToMany | ||
리턴 | Illuminate\Database\Eloquent\Relations\BelongsToMany |
public users ( ) : Illuminate\Database\Eloquent\Relations\BelongsToMany | ||
리턴 | Illuminate\Database\Eloquent\Relations\BelongsToMany |