Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -247,4 +247,4 @@ public function serialize($expand = null, array $fields = [], array $relations =

return $values;
}
}
}
36 changes: 36 additions & 0 deletions app/Swagger/Models/PresentationCategoryGroupSchema.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?php

namespace App\Swagger\schemas;

use OpenApi\Attributes as OA;


#[OA\Schema(
schema: 'PresentationCategoryGroup',
type: 'object',
required: ['id', 'created', 'last_edited', 'name', 'class_name', 'summit_id', 'max_attendee_votes'],
properties: [
new OA\Property(property: 'id', type: 'integer', example: 1),
new OA\Property(property: 'created', type: 'integer', example: 1634567890),
new OA\Property(property: 'last_edited', type: 'integer', example: 1634567890),
new OA\Property(property: 'name', type: 'string', example: 'Track Group Name'),
new OA\Property(property: 'color', type: 'string', example: '#FF5733'),
new OA\Property(property: 'description', type: 'string', example: 'Group description'),
new OA\Property(property: 'class_name', type: 'string', example: 'PresentationCategoryGroup'),
new OA\Property(property: 'summit_id', type: 'integer', example: 1),
new OA\Property(property: 'begin_attendee_voting_period_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'end_attendee_voting_period_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'max_attendee_votes', type: 'integer', example: 3),
new OA\Property(
property: 'tracks',
type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
new OA\Schema(ref: '#/components/schemas/PresentationCategory')
]
)
),
]
)]
class PresentationCategoryGroupSchema {}
84 changes: 84 additions & 0 deletions app/Swagger/Models/PresentationCategorySchema.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
<?php

namespace App\Swagger\schemas;

use OpenApi\Attributes as OA;


#[OA\Schema(
schema: 'PresentationCategory',
type: 'object',
properties: [
new OA\Property(property: 'id', type: 'integer', example: 1),
new OA\Property(property: 'created', type: 'integer', example: 1, format: "time_epoch"),
new OA\Property(property: 'last_edited', type: 'integer', example: 1, format: "time_epoch"),
new OA\Property(property: 'name', type: 'string'),
new OA\Property(property: 'description', type: 'string'),
new OA\Property(property: 'code', type: 'string'),
new OA\Property(property: 'slug', type: 'string'),
new OA\Property(property: 'session_count', type: 'integer'),
new OA\Property(property: 'alternate_count', type: 'integer'),
new OA\Property(property: 'lightning_count', type: 'integer'),
new OA\Property(property: 'lightning_alternate_count', type: 'integer'),
new OA\Property(property: 'voting_visible', type: 'boolean'),
new OA\Property(property: 'chair_visible', type: 'boolean'),
new OA\Property(property: 'summit_id', type: 'integer'),
new OA\Property(property: 'color', type: 'string'),
new OA\Property(property: 'text_color', type: 'string'),
new OA\Property(property: 'icon_url', type: 'string'),
new OA\Property(property: 'order', type: 'integer'),
new OA\Property(property: 'proposed_schedule_transition_time', type: 'integer'),
new OA\Property(property: 'parent_id', type: 'integer'),
new OA\Property(property: 'track_groups', type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
new OA\Schema(ref: '#/components/schemas/PresentationCategoryGroup')
]
),
description: 'PresentationCategoryGroup full objects if expanded'
),
new OA\Property(property: 'allowed_tags', type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
// new OA\Schema(ref: '#/components/schemas/Tag')
]
),
description: 'Tag full objects if expanded'
),
new OA\Property(property: 'extra_questions', type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
// new OA\Schema(ref: '#/components/schemas/TrackQuestionTemplate')
]
),
description: 'TrackQuestionTemplate full objects if expanded'
),
new OA\Property(property: 'selection_lists', type: 'array', items: new OA\Items(type: 'integer'),),
new OA\Property(property: 'allowed_access_levels', type: 'array', items: new OA\Items(type: 'integer'), description: 'SummitAccessLevelType IDs, or full objects if expanded'),
new OA\Property(property: 'proposed_schedule_allowed_locations', type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
// new OA\Schema(ref: '#/components/schemas/SummitProposedScheduleAllowedLocation')
]
),
description: 'SummitProposedScheduleAllowedLocation full objects if expanded'
),
new OA\Property(property: 'parent', ref: '#/components/schemas/PresentationCategory', description: 'PresentationCategory full object if expanded'),
new OA\Property(property: 'subtracks', type: 'array',
items: new OA\Items(
anyOf: [
new OA\Schema(type: 'integer'),
new OA\Schema(ref: '#/components/schemas/PresentationCategory')
]
),
description: 'PresentationCategory full object if expanded'
),
])
]
class PresentationCategorySchema
{
}
28 changes: 28 additions & 0 deletions app/Swagger/Security/TrackGroupsAuthSchema.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php

namespace App\Swagger\schemas;

use App\Security\SummitScopes;
use OpenApi\Attributes as OA;

#[OA\SecurityScheme(
type: 'oauth2',
securityScheme: 'track_groups_oauth2',
flows: [
new OA\Flow(
authorizationUrl: L5_SWAGGER_CONST_AUTH_URL,
tokenUrl: L5_SWAGGER_CONST_TOKEN_URL,
flow: 'authorizationCode',
scopes: [
SummitScopes::ReadSummitData => 'Read Summit Data',
SummitScopes::ReadAllSummitData => 'Read All Summit Data',
SummitScopes::WriteSummitData => 'Write Summit Data',
SummitScopes::WriteTrackGroupsData => 'Write Track Groups Data',
],
),
],
)
]
class TrackGroupsAuthSchema
{
}
39 changes: 39 additions & 0 deletions app/Swagger/SummitPresentationSchemas.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,3 +145,42 @@ class PresentationTrackChairScoreTypeCreateRequest {}
class PresentationTrackChairScoreTypeUpdateRequest {}

// End Track Chair Score Types

#[OA\Schema(
schema: 'PaginatedPresentationCategoryGroupsResponse',
allOf: [
new OA\Schema(ref: '#/components/schemas/PaginateDataSchemaResponse'),
new OA\Schema(
type: 'object',
properties: [
new OA\Property(
property: 'data',
type: 'array',
items: new OA\Items(ref: '#/components/schemas/PresentationCategoryGroup')
)
]
)
]
)]
class PaginatedPresentationCategoryGroupsResponse {}

#[OA\Schema(
schema: 'PresentationCategoryGroupRequest',
type: 'object',
required: ['name', 'class_name'],
properties: [
new OA\Property(property: 'name', type: 'string', example: 'Track Group Name'),
new OA\Property(property: 'class_name', type: 'string', example: 'PresentationCategoryGroup'),
new OA\Property(property: 'description', type: 'string', example: 'Group description'),
new OA\Property(property: 'color', type: 'string', example: '#FF5733'),
new OA\Property(property: 'max_attendee_votes', type: 'integer', example: 3),
new OA\Property(property: 'begin_attendee_voting_period_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'end_attendee_voting_period_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'submission_begin_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'submission_end_date', type: 'integer', example: 1634567890),
new OA\Property(property: 'max_submission_allowed_per_user', type: 'integer', example: 5),
]
)]
class PresentationCategoryGroupRequest {}

//