*/ class EventPhotoboothSettingFactory extends Factory { /** * Define the model's default state. * * @return array */ public function definition(): array { return [ 'event_id' => Event::factory(), 'enabled' => false, 'mode' => 'ftp', 'status' => 'inactive', 'uploads_last_24h' => 0, 'uploads_total' => 0, ]; } public function activeFtp(): static { return $this->state(fn () => [ 'enabled' => true, 'mode' => 'ftp', 'status' => 'active', ]); } public function activeSparkbooth(): static { return $this->state(fn () => [ 'enabled' => true, 'mode' => 'sparkbooth', 'status' => 'active', ]); } }