users and institutions route, tests fixed
This commit is contained in:
29
backend/database/seeders/UserPositionSeeder.php
Normal file
29
backend/database/seeders/UserPositionSeeder.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Seeders;
|
||||
|
||||
use App\Models\Lists\UserPosition;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
class UserPositionSeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
* Run the database seeds.
|
||||
*/
|
||||
public function run(): void
|
||||
{
|
||||
$positions = [
|
||||
UserPosition::PROFESSOR,
|
||||
UserPosition::RESEARCHER,
|
||||
UserPosition::PHD,
|
||||
UserPosition::STUDENT,
|
||||
UserPosition::ADMINISTRATIVE,
|
||||
];
|
||||
|
||||
foreach ($positions as $position) {
|
||||
UserPosition::updateOrCreate(
|
||||
['value' => $position]
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user