Namespace seeders

This commit is contained in:
Laravel Shift
2021-06-10 20:18:00 +00:00
parent 104b441e0d
commit c90b1c6a43
20 changed files with 47 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
<?php
namespace Database\Seeders;
use App\Models\Depreciation;
use Illuminate\Database\Seeder;
class DepreciationSeeder extends Seeder
{
public function run()
{
Depreciation::truncate();
Depreciation::factory()->count(1)->computer()->create(); // 1
Depreciation::factory()->count(1)->display()->create(); // 2
Depreciation::factory()->count(1)->mobilePhones()->create(); // 3
}
}