More changes to use form.select component. Re-engineered user BBS registration
This commit is contained in:
@@ -25,6 +25,13 @@ class SystemPolicy
|
||||
{
|
||||
use HandlesAuthorization;
|
||||
|
||||
public function admin(User $user, System $system): bool
|
||||
{
|
||||
// Site Admins can always create
|
||||
// If it doesnt exist, then a user can create it.
|
||||
return ($user->isAdmin() || (! $system->exists));
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine whether the user can create the model.
|
||||
*
|
||||
@@ -70,9 +77,9 @@ class SystemPolicy
|
||||
if ($user->isAdmin())
|
||||
return TRUE;
|
||||
|
||||
// If it doesnt exist, then its a false.
|
||||
// If it doesnt exist, then its a true (they are creating it).
|
||||
if (! $system->exists)
|
||||
return FALSE;
|
||||
return TRUE;
|
||||
|
||||
// @todo Permit ZC, RC, NC, HUB user
|
||||
|
||||
|
Reference in New Issue
Block a user