feat(Config): Erstellen, Lesen und Aktualisieren von DTOs unter Verwendung von Basis-DTOs zum Aktualisieren und Erstellen.

This commit is contained in:
Developer 02
2024-10-23 14:57:15 +02:00
parent 5ce6958122
commit adc33bfee1
4 changed files with 20 additions and 0 deletions

View File

@@ -4,6 +4,8 @@ namespace WorkFlow.Application.DTO
{
public record BaseUpdateDto
{
public required int Id { get; init; }
[JsonIgnore]
public required string ChangedWho { get; set; } = "UNKNOWN";

View File

@@ -0,0 +1,4 @@
namespace WorkFlow.Application.DTO.Config
{
public record ConfigCreateDto(string Title, string String);
}

View File

@@ -0,0 +1,10 @@
namespace WorkFlow.Application.DTO.Config
{
public record ConfigDto(int Id,
string Title,
string String,
string AddedWho,
DateTime AddedWhen,
string? ChangedWho = null,
DateTime? ChangedWhen = null);
}

View File

@@ -0,0 +1,4 @@
namespace WorkFlow.Application.DTO.Config
{
public record ConfigUpdateDto(string Title, string String) : BaseUpdateDto;
}