From 99b0dba79f18a1db9f96871980f423fcffdf42d4 Mon Sep 17 00:00:00 2001 From: Developer 02 Date: Thu, 10 Apr 2025 18:50:24 +0200 Subject: [PATCH] Refactor envelope sender handling and update namespaces Changed the namespace for `EnvelopeQuery` and updated the `Sender` parameter type to `SenderQuery?`. Removed `UserQuery.cs` as it is no longer needed. Introduced `SenderQuery.cs` with properties for sender details and added XML documentation for clarity. --- .../Envelopes/EnvelopeQuery.cs | 2 +- .../Envelopes/SenderQuery.cs | 11 +++++++++++ EnvelopeGenerator.Application/Envelopes/UserQuery.cs | 5 ----- 3 files changed, 12 insertions(+), 6 deletions(-) create mode 100644 EnvelopeGenerator.Application/Envelopes/SenderQuery.cs delete mode 100644 EnvelopeGenerator.Application/Envelopes/UserQuery.cs diff --git a/EnvelopeGenerator.Application/Envelopes/EnvelopeQuery.cs b/EnvelopeGenerator.Application/Envelopes/EnvelopeQuery.cs index 8d3bd7fb..fcf6de9d 100644 --- a/EnvelopeGenerator.Application/Envelopes/EnvelopeQuery.cs +++ b/EnvelopeGenerator.Application/Envelopes/EnvelopeQuery.cs @@ -11,7 +11,7 @@ namespace EnvelopeGenerator.Application.Envelopes; /// Die universell eindeutige Kennung des Umschlags. public record EnvelopeQuery( int? Id = null, - UserQuery? Sender = null, + SenderQuery? Sender = null, int? Status = null, string? Uuid = null) : IRequest { diff --git a/EnvelopeGenerator.Application/Envelopes/SenderQuery.cs b/EnvelopeGenerator.Application/Envelopes/SenderQuery.cs new file mode 100644 index 00000000..ca0c70a1 --- /dev/null +++ b/EnvelopeGenerator.Application/Envelopes/SenderQuery.cs @@ -0,0 +1,11 @@ +namespace EnvelopeGenerator.Application.Envelopes; + +/// +/// Repräsentiert eine Abfrage für einen Absender. +/// +/// Die eindeutige Kennung des Absenders. +/// Der Benutzername des Absenders. +/// Die E-Mail-Adresse des Absenders. +public record SenderQuery(int? Id = null, string? Username = null, string? Email = null) +{ +} diff --git a/EnvelopeGenerator.Application/Envelopes/UserQuery.cs b/EnvelopeGenerator.Application/Envelopes/UserQuery.cs deleted file mode 100644 index 0c57327b..00000000 --- a/EnvelopeGenerator.Application/Envelopes/UserQuery.cs +++ /dev/null @@ -1,5 +0,0 @@ -namespace EnvelopeGenerator.Application.Envelopes; - -public record UserQuery(int? Id = null, string? Username = null, string? Email = null) -{ -}