SeemGen/Models/SiteInfo.cs

40 lines
1.3 KiB
C#

using Microsoft.AspNetCore.Identity;
using System.ComponentModel.DataAnnotations;
namespace BLAIzor.Models
{
public class SiteInfo
{
[Key]
public int Id { get; set; }
public string? SiteName { get; set; }
public string? SiteDescription { get; set; }
public string? BrandLogoUrl { get; set; }
public string? DefaultColor { get; set; }
// Foreign key for IdentityUser
public string UserId { get; set; }
[Url(ErrorMessage = "The DomainUrl field must be a valid URL.")]
public string DomainUrl { get; set; } // For custom domains
[Url(ErrorMessage = "The DefaultUrl field must be a valid URL.")]
public string DefaultUrl { get; set; } // For generated subdomains
public bool IsPublished { get; set; } // For generated subdomains
public int? TemplateId { get; set; }
public bool TTSActive { get; set; } = false;
public bool STTActive { get; set; } = false;
// Navigation property for IdentityUser
public IdentityUser User { get; set; }
// Navigation property for Menu items
public ICollection<MenuItem> MenuItems { get; set; } = new List<MenuItem>();
public DesignTemplate Template { get; set; }
public List<FormDefinition> FormDefinitions { get; set; } = new();
}
}