Beheerroutes zonder /admin-segment op contact-messages (lijst met spam apart en ongelezen-teller zonder spam, detail, status, verwijderen, opnieuw versturen met eigen limiet) en contact-settings voor de CMS-schakelaar, allemaal AdminOnly. Het formulier is alleen open als de hostvlag EN de CMS-schakelaar (standaard uit) aan staan; de hostvlag wordt eerst gecontroleerd zodat de database niet wordt aangeraakt. Bij uitgeschakelde host antwoorden de beheerroutes 404. OpenAPI-document bijgewerkt. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
135 lines
4.6 KiB
C#
135 lines
4.6 KiB
C#
// <auto-generated />
|
|
using System;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
using SlpModularCms.Modules.Contact.Data;
|
|
|
|
#nullable disable
|
|
|
|
namespace SlpModularCms.Modules.Contact.Migrations
|
|
{
|
|
[DbContext(typeof(ContactDbContext))]
|
|
[Migration("20261109202158_AddContactSettings")]
|
|
partial class AddContactSettings
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
{
|
|
#pragma warning disable 612, 618
|
|
modelBuilder
|
|
.HasAnnotation("ProductVersion", "10.0.9")
|
|
.HasAnnotation("Relational:MaxIdentifierLength", 64);
|
|
|
|
modelBuilder.Entity("SlpModularCms.Modules.Contact.Data.Entities.ContactMessage", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("char(36)");
|
|
|
|
b.Property<string>("Email")
|
|
.IsRequired()
|
|
.HasMaxLength(254)
|
|
.HasColumnType("varchar(254)");
|
|
|
|
b.Property<int>("MailAttempts")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<string>("MailError")
|
|
.HasMaxLength(100)
|
|
.HasColumnType("varchar(100)");
|
|
|
|
b.Property<string>("MailStatus")
|
|
.IsRequired()
|
|
.HasMaxLength(20)
|
|
.HasColumnType("varchar(20)");
|
|
|
|
b.Property<string>("Message")
|
|
.IsRequired()
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("varchar(2000)");
|
|
|
|
b.Property<string>("Name")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("varchar(100)");
|
|
|
|
b.Property<DateTimeOffset?>("NextMailAttemptAt")
|
|
.HasColumnType("datetime");
|
|
|
|
b.Property<DateTimeOffset>("ReceivedAt")
|
|
.HasColumnType("datetime");
|
|
|
|
b.Property<DateTimeOffset>("RetentionUntil")
|
|
.HasColumnType("datetime");
|
|
|
|
b.Property<string>("SiteId")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("varchar(100)");
|
|
|
|
b.Property<string>("Status")
|
|
.IsRequired()
|
|
.HasMaxLength(20)
|
|
.HasColumnType("varchar(20)");
|
|
|
|
b.Property<string>("Subject")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("varchar(100)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("RetentionUntil");
|
|
|
|
b.HasIndex("SiteId", "Status", "ReceivedAt");
|
|
|
|
b.ToTable("ContactMessages", (string)null);
|
|
});
|
|
|
|
modelBuilder.Entity("SlpModularCms.Modules.Contact.Data.Entities.ContactSettings", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<bool>("Enabled")
|
|
.HasColumnType("tinyint(1)");
|
|
|
|
b.Property<DateTimeOffset>("UpdatedAt")
|
|
.HasColumnType("datetime");
|
|
|
|
b.Property<Guid>("UpdatedByUserId")
|
|
.HasColumnType("char(36)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("ContactSettings", (string)null);
|
|
});
|
|
|
|
modelBuilder.Entity("SlpModularCms.Modules.Contact.Data.Entities.IdempotencyRecord", b =>
|
|
{
|
|
b.Property<string>("SiteId")
|
|
.HasMaxLength(100)
|
|
.HasColumnType("varchar(100)");
|
|
|
|
b.Property<Guid>("Key")
|
|
.HasColumnType("char(36)");
|
|
|
|
b.Property<DateTimeOffset>("CreatedAt")
|
|
.HasColumnType("datetime");
|
|
|
|
b.Property<int>("StatusCode")
|
|
.HasColumnType("int");
|
|
|
|
b.HasKey("SiteId", "Key");
|
|
|
|
b.HasIndex("CreatedAt");
|
|
|
|
b.ToTable("ContactIdempotency", (string)null);
|
|
});
|
|
#pragma warning restore 612, 618
|
|
}
|
|
}
|
|
}
|