feat: add endpoints to update payment and attendance status of training date attendee
This commit is contained in:
parent
140ec493bf
commit
f5e632a46f
3 changed files with 555 additions and 37 deletions
|
|
@ -386,6 +386,66 @@ paths:
|
|||
"500":
|
||||
$ref: "#/components/responses/InternalError"
|
||||
|
||||
/v1/trainings/{trainingID}/dates/{trainingDateID}/attendees/{trainingDateAttendeeID}/paid:
|
||||
put:
|
||||
summary: Update status of a training date attendee payment
|
||||
operationId: updateTrainingDateAttendeePayment
|
||||
tags:
|
||||
- Trainings
|
||||
parameters:
|
||||
- $ref: "#/components/parameters/TrainingID"
|
||||
- $ref: "#/components/parameters/TrainingDateID"
|
||||
- $ref: "#/components/parameters/TrainingDateAttendeeID"
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/TrainingDateAttendeePaymentUpdateRequest"
|
||||
responses:
|
||||
"200":
|
||||
description: Training date attendee payment status updated
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/UpdateTrainingDateAttendeeResponse"
|
||||
"400":
|
||||
$ref: "#/components/responses/InvalidInputError"
|
||||
"404":
|
||||
$ref: "#/components/responses/NotFoundError"
|
||||
"500":
|
||||
$ref: "#/components/responses/InternalError"
|
||||
|
||||
/v1/trainings/{trainingID}/dates/{trainingDateID}/attendees/{trainingDateAttendeeID}/attended:
|
||||
put:
|
||||
summary: Update status of a training date attendee attendance
|
||||
operationId: updateTrainingDateAttendeeAttendance
|
||||
tags:
|
||||
- Trainings
|
||||
parameters:
|
||||
- $ref: "#/components/parameters/TrainingID"
|
||||
- $ref: "#/components/parameters/TrainingDateID"
|
||||
- $ref: "#/components/parameters/TrainingDateAttendeeID"
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/TrainingDateAttendeeAttendanceUpdateRequest"
|
||||
responses:
|
||||
"200":
|
||||
description: Training date attendee attendance status updated
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/UpdateTrainingDateAttendeeResponse"
|
||||
"400":
|
||||
$ref: "#/components/responses/InvalidInputError"
|
||||
"404":
|
||||
$ref: "#/components/responses/NotFoundError"
|
||||
"500":
|
||||
$ref: "#/components/responses/InternalError"
|
||||
|
||||
/v1/trainings/{trainingID}/dates/{trainingDateID}/attendees/count:
|
||||
get:
|
||||
summary: Get a training date attendee count
|
||||
|
|
@ -630,6 +690,22 @@ components:
|
|||
required:
|
||||
- count
|
||||
|
||||
TrainingDateAttendeePaymentUpdateRequest:
|
||||
type: object
|
||||
properties:
|
||||
paid:
|
||||
type: boolean
|
||||
required:
|
||||
- paid
|
||||
|
||||
TrainingDateAttendeeAttendanceUpdateRequest:
|
||||
type: object
|
||||
properties:
|
||||
attended:
|
||||
type: boolean
|
||||
required:
|
||||
- attended
|
||||
|
||||
TrainingDateAttendeeID:
|
||||
type: string
|
||||
format: uuid
|
||||
|
|
|
|||
Reference in a new issue