Move AdditionalData to AppBaseData

This commit is contained in:
nicolas.dorier 2024-07-11 21:43:30 +09:00
parent 66d8dda0f5
commit 10977e6750
No known key found for this signature in database
GPG key ID: 6618763EF09186FE
2 changed files with 4 additions and 2 deletions

View file

@ -1,5 +1,7 @@
using System; using System;
using System.Collections.Generic;
using Newtonsoft.Json; using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace BTCPayServer.Client.Models; namespace BTCPayServer.Client.Models;
@ -13,6 +15,8 @@ public class AppBaseData
public bool? Archived { get; set; } public bool? Archived { get; set; }
[JsonConverter(typeof(NBitcoin.JsonConverters.DateTimeToUnixTimeConverter))] [JsonConverter(typeof(NBitcoin.JsonConverters.DateTimeToUnixTimeConverter))]
public DateTimeOffset Created { get; set; } public DateTimeOffset Created { get; set; }
[JsonExtensionData]
public IDictionary<string, JToken> AdditionalData { get; set; } = new Dictionary<string, JToken>();
} }
public interface IAppRequest public interface IAppRequest

View file

@ -27,8 +27,6 @@ public abstract class PointOfSaleBaseData : AppBaseData
public bool? RedirectAutomatically { get; set; } public bool? RedirectAutomatically { get; set; }
public int[]? CustomTipPercentages { get; set; } public int[]? CustomTipPercentages { get; set; }
public string? FormId { get; set; } public string? FormId { get; set; }
[JsonExtensionData]
public IDictionary<string, JToken> AdditionalData { get; set; } = new Dictionary<string, JToken>();
} }
public class PointOfSaleAppData : PointOfSaleBaseData public class PointOfSaleAppData : PointOfSaleBaseData