2ef24de3f9
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
29 lines
871 B
PHP
29 lines
871 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Http\Resources\Autopodbor;
|
|
|
|
use Illuminate\Http\Request;
|
|
use Illuminate\Http\Resources\Json\JsonResource;
|
|
|
|
class CompetitorResource extends JsonResource
|
|
{
|
|
public function toArray(Request $request): array
|
|
{
|
|
return [
|
|
'id' => $this->id,
|
|
'name' => $this->name,
|
|
'description' => $this->description,
|
|
'is_federal' => $this->is_federal,
|
|
'relevance_pct' => $this->relevance_pct,
|
|
'origin' => $this->origin,
|
|
'site_url' => $this->site_url,
|
|
'directory_urls' => $this->directory_urls,
|
|
'studied_at' => $this->studied_at?->toIso8601String(),
|
|
'study_run_id' => $this->study_run_id,
|
|
'search_run_id' => $this->search_run_id,
|
|
];
|
|
}
|
|
}
|