| 1 |
<?php |
| 2 |
|
| 3 |
namespace App\Billingo\Factories; |
| 4 |
|
| 5 |
use App\Billingo\Enums\DocumentBlockTypeEnum; |
| 6 |
|
| 7 |
class DocumentBlockFactory extends BaseFactory |
| 8 |
{ |
| 9 |
|
| 10 |
public function definition(): array |
| 11 |
{ |
| 12 |
return [ |
| 13 |
'id' => $this->faker->numberBetween(1,1000), |
| 14 |
'name' =>$this->faker->regexify('[A-Za-z0-9 ]{10}'), |
| 15 |
'prefix' => $this->faker->word(), |
| 16 |
'custom_field1' => $this->faker->optional()->word(), |
| 17 |
'custom_field2' => $this->faker->optional()->word(), |
| 18 |
'type' => $this->faker->randomElement(getEnumValues(DocumentBlockTypeEnum::class)), |
| 19 |
]; |
| 20 |
} |
| 21 |
} |
| 22 |
|