AssetGroupFactory.php 590 B

1234567891011121314151617181920212223242526
  1. <?php
  2. namespace Database\Factories;
  3. use Illuminate\Database\Eloquent\Factories\Factory;
  4. use Illuminate\Support\Facades\Auth;
  5. /**
  6. * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\AssetGroup>
  7. */
  8. class AssetGroupFactory extends Factory
  9. {
  10. /**
  11. * Define the model's default state.
  12. *
  13. * @return array<string, mixed>
  14. */
  15. public function definition(): array
  16. {
  17. return [
  18. 'name' => fake()->name(),
  19. 'sequence' => fake()->randomNumber(1, 9),
  20. 'company_id' => Auth::user()->company_id,
  21. ];
  22. }
  23. }