store/database/seeders/CuttingResultSeeder.php
Yoga Pangestu 9539ff7042 refactor: remove StockController and related stock verification logic
- Deleted `data-table-actions.vue` component as it is no longer needed.
- Removed `CuttingResultPriceItem` type and related properties from `cutting.ts`.
- Updated routes in `web.php` to eliminate stock verification routes and permissions.
- Removed `StockTest.php` file and its associated tests for stock verification and management.
- Adjusted `CuttingTest.php` to reflect changes in cutting results handling and removed references to product variants.
2026-07-19 17:29:19 +07:00

28 lines
523 B
PHP

<?php
namespace Database\Seeders;
use App\Models\Cutting;
use App\Models\CuttingResult;
use Illuminate\Database\Seeder;
class CuttingResultSeeder extends Seeder
{
public function run(): void
{
$cutting = Cutting::query()->first();
if ($cutting === null) {
CuttingResult::factory()->count(3)->create();
return;
}
CuttingResult::factory()
->count(2)
->create([
'cutting_id' => $cutting->id,
]);
}
}