- Add Sanctum auth flow (store, composables, login, axios interceptors) - Add dashboard, organisation list/detail, events CRUD dialogs - Wire router guards, navigation, organisation switcher in layout - Replace Vuexy @db types in NavSearchBar; add @iconify/types; themeConfig title typing - Vuetify settings.scss + resolve configFile via fileURLToPath; drop dead path aliases - Root index redirects to dashboard; fix events table route name - API: DevSeeder + DatabaseSeeder updates; docs TEST_SCENARIO; corporate identity assets Made-with: Cursor
40 lines
922 B
PHP
40 lines
922 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Database\Seeders;
|
|
|
|
use App\Models\Organisation;
|
|
use App\Models\User;
|
|
use Illuminate\Database\Seeder;
|
|
use Illuminate\Support\Facades\Hash;
|
|
|
|
class DatabaseSeeder extends Seeder
|
|
{
|
|
public function run(): void
|
|
{
|
|
$this->call(RoleSeeder::class);
|
|
|
|
$admin = User::create([
|
|
'name' => 'Super Admin',
|
|
'email' => 'admin@crewli.app',
|
|
'password' => Hash::make('password'),
|
|
]);
|
|
|
|
$admin->assignRole('super_admin');
|
|
|
|
$organisation = Organisation::query()->create([
|
|
'name' => 'Demo Organisation',
|
|
'slug' => 'demo',
|
|
'billing_status' => 'active',
|
|
'settings' => [],
|
|
]);
|
|
|
|
$admin->organisations()->attach($organisation->id, ['role' => 'org_admin']);
|
|
|
|
if (app()->environment('local')) {
|
|
$this->call(DevSeeder::class);
|
|
}
|
|
}
|
|
}
|