Skip to content

Commit 3689ca1

Browse files
fix: Move schema to the new file
1 parent dc99caf commit 3689ca1

2 files changed

Lines changed: 30 additions & 1 deletion

File tree

app/Http/Controllers/Apis/Protected/Summit/OAuth2SpeakerActiveInvolvementApiController.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
use Illuminate\Support\Facades\Log;
1717
use models\exceptions\EntityNotFoundException;
1818
use models\exceptions\ValidationException;
19+
use Symfony\Component\HttpFoundation\Response;
1920
use utils\PagingResponse;
2021
use Illuminate\Support\Facades\Request;
2122
use OpenApi\Attributes as OA;

app/Swagger/SummitSpeakersSchemas.php

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,32 @@
44

55
use OpenApi\Attributes as OA;
66

7-
//
7+
#[OA\Schema(
8+
schema: 'SpeakerActiveInvolvement',
9+
type: 'object',
10+
properties: [
11+
new OA\Property(property: 'id', type: 'integer', example: 1),
12+
new OA\Property(property: 'created', type: 'integer', format: 'int64', example: 1633024800),
13+
new OA\Property(property: 'last_edited', type: 'integer', format: 'int64', example: 1633024800),
14+
new OA\Property(property: 'involvement', type: 'string', example: 'Active Contributor'),
15+
new OA\Property(property: 'is_default', type: 'boolean', example: true),
16+
]
17+
)]
18+
class SpeakerActiveInvolvementSchema {}
19+
20+
#[OA\Schema(
21+
schema: 'SpeakerActiveInvolvementsResponse',
22+
type: 'object',
23+
properties: [
24+
new OA\Property(property: 'total', type: 'integer', example: 5),
25+
new OA\Property(property: 'per_page', type: 'integer', example: 5),
26+
new OA\Property(property: 'current_page', type: 'integer', example: 1),
27+
new OA\Property(property: 'last_page', type: 'integer', example: 1),
28+
new OA\Property(
29+
property: 'data',
30+
type: 'array',
31+
items: new OA\Items(ref: '#/components/schemas/SpeakerActiveInvolvement')
32+
),
33+
]
34+
)]
35+
class SpeakerActiveInvolvementsResponseSchema {}

0 commit comments

Comments
 (0)