fix(Annotation): JsonIgnore-Attribut zu HorBoundAnnot und VerBoundAnnot hinzufügen

This commit is contained in:
Developer 02 2025-03-20 12:46:57 +01:00
parent 353f7698f4
commit 43db4e275b
3 changed files with 11 additions and 7 deletions

View File

@ -1,4 +1,6 @@
namespace EnvelopeGenerator.Web.Models;
using System.Text.Json.Serialization;
namespace EnvelopeGenerator.Web.Models;
public class Annotation
{
@ -55,8 +57,10 @@ public class Annotation
#endregion
#region BoundAnnot
[JsonIgnore]
public Annotation? HorBoundAnnot { get; set; }
[JsonIgnore]
public Annotation? VerBoundAnnot { get; set; }
#endregion
};

View File

@ -2,11 +2,11 @@
public class AnnotationParams
{
private Annotation? DefaultAnnotation { get; init; }
public Annotation? DefaultAnnotation { get; init; }
private readonly Dictionary<string, Annotation> _annots = new();
public required Dictionary<string, Annotation> Annots
public required Dictionary<string, Annotation> Annotations
{
get => _annots;
init

View File

@ -152,17 +152,17 @@
"MainPageTitle": null,
"AnnotationParams": {
"DefaultAnnotation": {
"Width": 1,
"Height": 0.5
},
"Annotations": {
"Signature": {
},
"City": {
"VerBoundAnnotName": "Signature"
},
"Date": {
"VerBoundAnnotName": "City"
}
}
}