feat(tickets): add TicketFormController, TicketFormService, and TicketFormResource with related routes and tests
This commit is contained in:
18
app/Domains/Forms/Resources/TicketFormResource.php
Normal file
18
app/Domains/Forms/Resources/TicketFormResource.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Domains\Forms\Resources;
|
||||
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Http\Resources\Json\JsonResource;
|
||||
|
||||
class TicketFormResource extends JsonResource
|
||||
{
|
||||
/** @return array<string, mixed> */
|
||||
public function toArray(Request $request): array
|
||||
{
|
||||
return [
|
||||
'statuses' => $this->resource['statuses'],
|
||||
'categories' => $this->resource['categories'],
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user