API Docs
HomeDocsWebsite
  • Home
  • Introduction
    • Authorization
      • Authorize
      • Get a Token
      • Third-Party Login
    • Field Types and Validation
      • Field Types
      • Validation
    • Query Manipulation
      • Constraints
      • Result Control
      • Value Filters
    • Entity Permissions
      • Restricted Scope
  • API reference
    • Infoboard
      • InfoboardChannels
      • InfoboardPosts
      • InfoboardPostSeenUsers
      • InfoboardPostReadUsers
      • InfoboardComments
      • InfoboardDepartmentSettings
    • Manual
      • ManualChapters
      • ManualEntries
      • ManualEntrySeenUsers
    • Calendar
      • Calendars
      • CalendarEvents
    • Filemanager
      • FilemanagerDirectories
      • FilemanagerFiles
    • Files
    • Forms
      • Forms
      • FormFields
      • FormFieldTypes
      • FormFieldValidations
      • FormFieldValidationTypes
      • FormMessages
      • FormMessageFields
    • Layouts
      • Layouts
      • LayoutRows
      • LayoutColumns
      • LayoutColumnLayoutElements
    • Tasks 2.0
      • TaskTemplates
      • TaskFields
      • TaskAssignments
      • TaskExecutions
      • TaskProgressFields
    • Departments
    • Roles
    • Permissions
    • Users
    • EntityPermissions
    • Notifications
    • Reactions
    • Icons
    • Folders
    • SharedItems
    • UrlContext
  • Resources
    • Release Notes
      • v2.106.0
      • v2.102.0
Powered by GitBook
On this page
  • Introduction
  • Model Definition
  • [Adm.] Create
  • [Adm.] Update
  • [Adm.] Delete
  1. API reference
  2. Forms

FormFieldValidations

PreviousFormFieldTypesNextFormFieldValidationTypes

Last updated 10 months ago

Introduction

FormFieldValidations are related to and describe how input fields should be validated when a enters information or submits the .

How a field should be validated is determined by it's associated by thw key and the config.

Model Definition

Alias

formFieldValidation

Relations

Relation
Key
Type
Relation Field(s)

formField

Belongs to

form_field_id

formFieldValidationType

Belongs to

form_field_validation_type_id

Computed Properties

  • validation_string - The resulting validation string from the configuration

[Adm.] Create

Create a new FormFieldValidation.

Definition

POST /api/administration/forms/fields/validations

Request Keys

Key
Type
Default
Description

form_field_id *

integer

-

form_field_validation_type_id *

integer

-

config

json

The scheme how the data has to be stored to pass the validation

Keys with * are required.

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('POST', '/api/administration/forms/fields/validations', [
    'headers' => ['Authorization' => "Bearer {accessToken}"],
    'json' => [
        'form_field_id' => 7,
        'form_field_validation_type_id' => 'email'
    ]
]);

Example Response

{
  "status": "success",
  "data": {
    "form_field_id": 7,
    "form_field_validation_type_id": "email",
    "config": {},
    "updated_at": "2019-01-25 14:47:40",
    "created_at": "2019-01-25 14:47:40",
    "id": 5,
    "validation_string": "email",
    "form_field_validation_type": {
      "id": "email",
      "default_config": {},
      "sort_number": 2,
      "created_at": "2019-01-21 00:00:00",
      "updated_at": "2019-01-21 00:00:00"
    }
  }
}

[Adm.] Update

Update an existing FormFieldValidation by id.

Definition

PUT /api/administration/forms/fields/validations/{id}

Request Keys

Key
Type
Description

form_field_id

integer

form_field_validation_type_id

integer

config

json

The scheme how the data has to be stored to pass the validation

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('PUT', '/api/administration/forms/fields/validations/5', [
    'headers' => ['Authorization' => "Bearer {accessToken}"],
    'json' => [
        'form_field_id' => 7,
        'form_field_validation_type_id' => 'required'
    ]
]);

Example Response

{
  "status": "success",
  "data": {
    "id": 5,
    "form_field_id": 7,
    "form_field_validation_type_id": "required",
    "config": {},
    "created_at": "2019-01-25 14:47:40",
    "updated_at": "2019-01-25 14:55:21",
    "validation_string": "required",
    "form_field_validation_type": {
      "id": "required",
      "default_config": {},
      "sort_number": 1,
      "created_at": "2019-01-21 00:00:00",
      "updated_at": "2019-01-21 00:00:00"
    }
  }
}

[Adm.] Delete

Delete an existing FormFieldValidation by id.

Definition

DELETE /api/administration/forms/fields/validations/{id}

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('DELETE', '/api/administration/forms/fields/validations/5', [
    'headers' => ['Authorization' => "Bearer {accessToken}"]
]);

Example Response

{
  "status": "success",
  "data": {
    "count": 1
  }
}

The related

The related

Default config

The related

The related

FormFields
User
Form
FormFieldValidationType
FormField
FormFieldValidationType
FormField
FormFieldValidationTyp
FormFieldValidationTyp
FormField
FormFieldValidationTyp