// ========================================================================== // Squidex Headless CMS // ========================================================================== // Copyright (c) Squidex UG (haftungsbeschränkt) // All rights reserved. Licensed under the MIT license. // ========================================================================== using Squidex.Infrastructure.Validation; namespace Squidex.Areas.Api.Controllers.Schemas.Models { public sealed class UpsertSchemaFieldDto { /// /// The name of the field. Must be unique within the schema. /// [LocalizedRequired] [LocalizedRegularExpression("^[a-zA-Z0-9]+(\\-[a-zA-Z0-9]+)*$")] public string Name { get; set; } /// /// Defines if the field is hidden. /// public bool IsHidden { get; set; } /// /// Defines if the field is locked. /// public bool IsLocked { get; set; } /// /// Defines if the field is disabled. /// public bool IsDisabled { get; set; } /// /// Determines the optional partitioning of the field. /// public string? Partitioning { get; set; } /// /// The field properties. /// [LocalizedRequired] public FieldPropertiesDto Properties { get; set; } /// /// The nested fields. /// public UpsertSchemaNestedFieldDto[]? Nested { get; set; } } }