Файловый менеджер - Редактировать - /home/clickysoft/public_html/charliapp-v2.clickysoft.net/app/Http/Resources/Admin/ChaptersCardResource.php
Назад
<?php namespace App\Http\Resources\Admin; use Illuminate\Http\Resources\Json\JsonResource; use App\Http\Resources\TaskResource; class ChaptersCardResource extends JsonResource { public function toArray($request) { // return parent::toArray($request); // $tasks = $this->task; // $tasks = $this->whenLoaded('taskShow') return [ 'id' => $this->id, 'card_title' => $this->card_title, 'card_description' => $this->card_description, 'created_at' => (new \Carbon\Carbon($this->created_at))->format('F d, Y'), 'updated_at' => (new \Carbon\Carbon($this->updated_at))->format('F d, Y'), 'image' => $this->image, 'attachment' => $this->attachment, 'collabrator'=>$this->collaborators, 'commments' =>$this->comments, 'tasks' => $this->task->map(function ($task) { return [ 'title' => $task->title, 'due_date' => $task->due_date, 'task_type' => $task->task_type, 'type_id' => $task->type_id, 'task_id' => $task->id, 'status' => $task->status, 'chapter_cards_id' => $task->chapter_cards_id, 'comments'=>$task->comments, 'collabrator' => $task->collaboration, ]; }), 'color_id' => $this->color->id, 'color' => $this->color->color, 'color_code' => $this->color->color_code, 'foreground_color' => $this->color->foreground_color, ]; } }
| ver. 1.4 |
Github
|
.
| PHP 8.1.29 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка