- Added services (`RoleService`, `AppRoleService`, `AppsPermissionService`) to handle role creation, app assignments, and permissions. - Introduced new Livewire forms for creating roles and assigning apps (`CreateRoleForm`, `AssignAppToRoleForm`). - Built dynamic Blade views for role and app management, including modals and reusable components. - Removed outdated `fluxui-development` skill documentation.
28 lines
570 B
PHP
28 lines
570 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Livewire\Forms;
|
|
|
|
use Livewire\Attributes\Validate;
|
|
use Livewire\Form;
|
|
|
|
class AssignAppToRoleForm extends Form
|
|
{
|
|
#[Validate([
|
|
'appIds' => 'required|array|min:1',
|
|
'appIds.*' => 'integer|exists:connected_apps,id',
|
|
])]
|
|
public array $appIds = [];
|
|
|
|
#[Validate('required|integer|min:1|max:3650')]
|
|
public int $duration = 30;
|
|
|
|
public function reset(mixed ...$properties): void
|
|
{
|
|
$this->resetErrorBag();
|
|
parent::reset(...$properties);
|
|
$this->duration = 30;
|
|
}
|
|
}
|