27 lines
1.1 KiB
C#
27 lines
1.1 KiB
C#
namespace EnvelopeGenerator.ReceiverUI.Client.Models;
|
|
|
|
/// <summary>
|
|
/// Client-seitiges DTO für Umschlag-Daten.
|
|
/// Muss nur die JSON-Properties matchen, die die API zurückgibt
|
|
/// und die der Client tatsächlich braucht.
|
|
///
|
|
/// WARUM eigene DTOs statt die aus EnvelopeGenerator.Application?
|
|
/// - Application hat Server-Abhängigkeiten (SqlClient, JwtBearer, EF Core)
|
|
/// - Diese Pakete existieren nicht für browser-wasm → Build-Fehler
|
|
/// - Der Client braucht nur eine Teilmenge der Felder
|
|
/// - Eigene DTOs machen den Client unabhängig vom Server
|
|
/// </summary>
|
|
public record EnvelopeModel
|
|
{
|
|
public int Id { get; init; }
|
|
public string Uuid { get; init; } = string.Empty;
|
|
public string Title { get; init; } = string.Empty;
|
|
public string Message { get; init; } = string.Empty;
|
|
public bool UseAccessCode { get; init; }
|
|
public bool TFAEnabled { get; init; }
|
|
public bool ReadOnly { get; init; }
|
|
public string Language { get; init; } = "de-DE";
|
|
public DateTime AddedWhen { get; init; }
|
|
public UserModel? User { get; init; }
|
|
public IEnumerable<DocumentModel>? Documents { get; init; }
|
|
} |