<?php

namespace App\Http\Resources\Admin;

use Illuminate\Http\Resources\Json\JsonResource;

class ActiveLoanAndBorrowDetails extends JsonResource
{
    /**
     * Transform the resource into an array.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return array|\Illuminate\Contracts\Support\Arrayable|\JsonSerializable
     */
    public function toArray($request)
    {
        return [
            'id' => $this->id,
            'worker_id' => $this->worker_id,
            'worker_company_id' => $this->worker_company_id,
            'first_name' => $this->first_name,
            'last_name' => $this->last_name,
            'experience_name' => $this->experience_name,
            'work_area_lists' => $this->work_area_lists,
            'zipcode' => $this->zipcode,
            'date_from' => $this->date_from,
            'date_to' => $this->date_to,
            'invoice_no' => $this->invoice_no,
            'loaning_company_name' => $this->loaning_company_name,
            'borrowing_company_name' => $this->borrowing_company_name,
            'rate' => $this->rate,
            'additional_details' => $this->additional_details,
            'days' => $this->days,
            'other_expense' => $this->other_expense,
        ];
    }
}
