28 lines
526 B
PHP
28 lines
526 B
PHP
<?php
|
|
|
|
namespace Database\Factories;
|
|
|
|
use App\Models\Category;
|
|
use App\Models\CategoryNews;
|
|
use App\Models\News;
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
/**
|
|
* @extends Factory<CategoryNews>
|
|
*/
|
|
class CategoryNewsFactory extends Factory
|
|
{
|
|
/**
|
|
* Define the model's default state.
|
|
*
|
|
* @return array<string, mixed>
|
|
*/
|
|
public function definition(): array
|
|
{
|
|
return [
|
|
'category_id' => Category::factory(),
|
|
'news_id' => News::factory(),
|
|
];
|
|
}
|
|
}
|