* - directory refactor * - readme.md update * Update readme.md Co-authored-by: Adrian Hopek <adrian.hopek@blumilk.pl> * Update readme.md Co-authored-by: Ewelina Lasowy <56546832+EwelinaLasowy@users.noreply.github.com> * Update readme.md Co-authored-by: Ewelina Lasowy <56546832+EwelinaLasowy@users.noreply.github.com> * Update readme.md Co-authored-by: Ewelina Lasowy <56546832+EwelinaLasowy@users.noreply.github.com> * Update readme.md Co-authored-by: Adrian Hopek <adrian.hopek@blumilk.pl> Co-authored-by: Ewelina Lasowy <56546832+EwelinaLasowy@users.noreply.github.com>
		
			
				
	
	
		
			27 lines
		
	
	
		
			627 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			27 lines
		
	
	
		
			627 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
<?php
 | 
						|
 | 
						|
declare(strict_types=1);
 | 
						|
 | 
						|
namespace Database\Factories;
 | 
						|
 | 
						|
use Illuminate\Database\Eloquent\Factories\Factory;
 | 
						|
use Toby\Eloquent\Models\User;
 | 
						|
use Toby\Eloquent\Models\VacationLimit;
 | 
						|
use Toby\Eloquent\Models\YearPeriod;
 | 
						|
 | 
						|
class VacationLimitFactory extends Factory
 | 
						|
{
 | 
						|
    protected $model = VacationLimit::class;
 | 
						|
 | 
						|
    public function definition(): array
 | 
						|
    {
 | 
						|
        $hasVacation = $this->faker->boolean(75);
 | 
						|
 | 
						|
        return [
 | 
						|
            "user_id" => User::factory(),
 | 
						|
            "year_period_id" => YearPeriod::factory(),
 | 
						|
            "days" => $hasVacation ? $this->faker->numberBetween(20, 26) : null,
 | 
						|
        ];
 | 
						|
    }
 | 
						|
}
 |