feat(#5): Add title-body control element that can be added dynamically, refactored sectionIndex/create

This commit is contained in:
2025-11-02 10:32:46 +01:00
parent 4d371be2e3
commit 736cd17789
12 changed files with 407 additions and 88 deletions

View File

@@ -224,6 +224,57 @@ paths:
"503":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/ServiceUnavailable"
/application-forms/{applicationFormId}/sections/{sectionId}/form-elements:
post:
summary: Add a new form element to a specific section
operationId: addFormElementToSection
tags:
- application-form
parameters:
- name: applicationFormId
in: path
required: true
schema:
type: string
format: uuid
description: The ID of the application form
- name: sectionId
in: path
required: true
schema:
type: string
format: uuid
description: The ID of the form element section
- name: position
in: query
required: true
schema:
type: integer
description: The position to insert the form element
requestBody:
required: true
content:
application/json:
schema:
$ref: "#/components/schemas/CreateFormElementDto"
responses:
"201":
description: Form element successfully added
content:
application/json:
schema:
$ref: "#/components/schemas/ApplicationFormDto"
"400":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/BadRequest"
"401":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/Unauthorized"
"404":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/NotFound"
"500":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/ServerError"
"503":
$ref: "https://api.swaggerhub.com/domains/smartbear-public/ProblemDetails/1.0.0#/components/responses/ServiceUnavailable"
####### Application Form Templates #######
/application-form-templates:
get:
@@ -1080,6 +1131,7 @@ components:
- RADIOBUTTON
- TEXTFIELD
- SWITCH
- TITLE_BODY_TEXTFIELDS
####### UserDto #######
UserDto: