<?php 

namespace App\Http\Resources\Dasboard;

use Illuminate\Http\Resources\Json\JsonResource;
use App\Models\User;
use App\Http\Resources\BaseJsonResource;

class DashboardSectionResource extends BaseJsonResource
{
    public function toArray($request)
    {

        $array = [
            'name' => $this->name,
            'desc' => $this->desc,
            'type' => $this->type,
            'items' => DashboardItemResource::collection($this->items)
        ];
        
        return $array;
    }
}