mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-05-22 22:59:58 +08:00
Rolled out new permissions system throughout application
This commit is contained in:
@ -23,6 +23,7 @@ class AddViewPermissionsToRoles extends Migration
|
||||
$newPermission->name = strtolower($entity) . '-' . strtolower(str_replace(' ', '-', $op));
|
||||
$newPermission->display_name = $op . ' ' . $entity . 's';
|
||||
$newPermission->save();
|
||||
// Assign view permissions to all current roles
|
||||
foreach ($currentRoles as $role) {
|
||||
$role->attachPermission($newPermission);
|
||||
}
|
||||
|
Reference in New Issue
Block a user