2022-09-20 19:59:52 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Http\Resources;
|
|
|
|
|
|
|
|
use Illuminate\Http\Resources\Json\JsonResource;
|
|
|
|
|
|
|
|
class WorkspaceResource extends JsonResource
|
|
|
|
{
|
2024-01-22 13:28:22 +00:00
|
|
|
public static $wrap = null;
|
|
|
|
|
2022-09-20 19:59:52 +00:00
|
|
|
/**
|
|
|
|
* Transform the resource into an array.
|
|
|
|
*
|
2024-02-23 10:54:12 +00:00
|
|
|
* @param \Illuminate\Http\Request $request
|
2022-09-20 19:59:52 +00:00
|
|
|
* @return array
|
|
|
|
*/
|
|
|
|
public function toArray($request)
|
|
|
|
{
|
2024-01-22 13:28:22 +00:00
|
|
|
return array_merge(parent::toArray($request), [
|
|
|
|
'max_file_size' => $this->max_file_size / 1000000,
|
|
|
|
]);
|
2022-09-20 19:59:52 +00:00
|
|
|
}
|
|
|
|
}
|