2023-03-24 16:09:27 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
namespace App\Http\Resources;
|
|
|
|
|
|
|
|
|
|
use Illuminate\Http\Resources\Json\ResourceCollection;
|
|
|
|
|
|
|
|
|
|
class UrlCollection extends ResourceCollection
|
|
|
|
|
{
|
|
|
|
|
/**
|
|
|
|
|
* Transform the resource collection into an array.
|
|
|
|
|
*
|
|
|
|
|
* @param \Illuminate\Http\Request $request
|
|
|
|
|
* @return array|\Illuminate\Contracts\Support\Arrayable|\JsonSerializable
|
2023-11-23 15:33:07 +01:00
|
|
|
*
|
|
|
|
|
* @phpcs:disable Generic.CodeAnalysis.UnusedFunctionParameter.FoundInExtendedClass, Squiz.Commenting.FunctionComment.TypeHintMissing
|
2023-03-24 16:09:27 +00:00
|
|
|
*/
|
|
|
|
|
public function toArray($request)
|
|
|
|
|
{
|
|
|
|
|
return [
|
|
|
|
|
'data' => $this->collection
|
|
|
|
|
];
|
|
|
|
|
}
|
|
|
|
|
}
|