10.April 2026

This commit is contained in:
Kevin Adametz 2026-04-10 17:15:27 +02:00
parent a00c42e770
commit f58c709945
208 changed files with 19280 additions and 2914 deletions

View file

@ -0,0 +1,44 @@
<?php
namespace Database\Factories;
use App\Models\Incentive;
use Illuminate\Database\Eloquent\Factories\Factory;
class IncentiveFactory extends Factory
{
protected $model = Incentive::class;
public function definition(): array
{
return [
'name' => 'Incentive '.$this->faker->city().' '.$this->faker->year(),
'description' => $this->faker->sentence(),
'terms' => $this->faker->paragraph(),
'qualification_start' => '2026-04-01',
'qualification_end' => '2026-07-31',
'calculation_end' => '2026-08-31',
'points_partner_onetime' => 600,
'points_abo_onetime' => 400,
'min_direct_partners' => 4,
'min_customer_abos' => 6,
'max_winners' => 30,
'status' => 1, // active
];
}
public function draft(): static
{
return $this->state(['status' => 0]);
}
public function active(): static
{
return $this->state(['status' => 1]);
}
public function closed(): static
{
return $this->state(['status' => 2]);
}
}