30 lines
801 B
PHP
30 lines
801 B
PHP
<?php
|
|
|
|
namespace Database\Factories;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
/**
|
|
* @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Account>
|
|
*/
|
|
class AccountFactory extends Factory
|
|
{
|
|
/**
|
|
* Define the model's default state.
|
|
*
|
|
* @return array<string, mixed>
|
|
*/
|
|
public function definition(): array
|
|
{
|
|
return [
|
|
'name' => fake()->name(),
|
|
'code' => fake()->name(),
|
|
'sheet' => fake()->randomElement(["balance","income"]),
|
|
'type' => fake()->randomElement(["header","posting","begin-total","end-total"]),
|
|
'category' => fake()->name(),
|
|
'subcategory' => fake()->name(),
|
|
'structure' => str_replace(" ",".",strtolower(fake()->name())),
|
|
];
|
|
}
|
|
}
|