master_template/database/seeders/RoleSeeder.php
2024-06-20 16:42:33 +05:45

21 lines
442 B
PHP

<?php
namespace Database\Seeders;
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
use Spatie\Permission\Models\Role;
class RoleSeeder extends Seeder
{
/**
* Run the database seeds.
*/
public function run(): void
{
$role = Role::create(['name' => 'admin']);
$role = Role::create(['name' => 'editor']);
$role = Role::create(['name' => 'user']);
}
}