Make EmailTemplateDto mutable, add LangCode property
Changed EmailTemplateDto properties from init-only to mutable (get/set), removed 'required' from Name, and added a new LangCode property with a default value. Also updated using directives and added conditional compilation in EmailTemplate.cs for .NET Framework compatibility. No functional changes to EmailTemplate class.
This commit is contained in:
@@ -13,25 +13,30 @@ public record EmailTemplateDto
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public required string Name { get; init; }
|
||||
public string Name { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// Das Datum und die Uhrzeit, wann die Vorlage hinzugefügt wurde.
|
||||
/// </summary>
|
||||
public DateTime AddedWhen { get; init; }
|
||||
public DateTime AddedWhen { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Der Inhalt (Body) der E-Mail-Vorlage. Kann null sein.
|
||||
/// </summary>
|
||||
public string? Body { get; init; }
|
||||
public string? Body { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Der Betreff der E-Mail-Vorlage. Kann null sein.
|
||||
/// </summary>
|
||||
public string? Subject { get; init; }
|
||||
public string? Subject { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Der Sprachcode der E-Mail-Vorlage.
|
||||
/// </summary>
|
||||
public string LangCode { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// Das Datum und die Uhrzeit, wann die Vorlage zuletzt geändert wurde. Kann null sein.
|
||||
/// </summary>
|
||||
public DateTime? ChangedWhen { get; init; }
|
||||
public DateTime? ChangedWhen { get; set; }
|
||||
};
|
||||
@@ -1,9 +1,11 @@
|
||||
using System;
|
||||
using DigitalData.Core.Abstractions.Interfaces;
|
||||
using DigitalData.Core.Abstractions.Interfaces;
|
||||
using System.ComponentModel;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using EnvelopeGenerator.Domain.Interfaces.Auditing;
|
||||
#if NETFRAMEWORK
|
||||
using System;
|
||||
#endif
|
||||
|
||||
namespace EnvelopeGenerator.Domain.Entities
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user