From d913790dc2b105c503a2c24d7cd376dc749f87ff Mon Sep 17 00:00:00 2001 From: Jeremy van Lier Date: Tue, 6 Aug 2024 11:44:16 +0200 Subject: [PATCH] MultiCore Enhancement --- PAYNLFormsApp/Form2.cs | 1 + PAYNLSDK/API/RequestBase.cs | 12 ++++++++---- PAYNLSDK/API/Transaction/Start/Request.cs | 2 +- PAYNLSDK/Converters/DMYConverter.cs | 4 ---- 4 files changed, 10 insertions(+), 9 deletions(-) diff --git a/PAYNLFormsApp/Form2.cs b/PAYNLFormsApp/Form2.cs index 76a6bb0..aa409f9 100644 --- a/PAYNLFormsApp/Form2.cs +++ b/PAYNLFormsApp/Form2.cs @@ -19,6 +19,7 @@ private void Form2_Load(object sender, EventArgs e) cores.Add(PAYNLSDK.API.RequestBase.Core1, PAYNLSDK.API.RequestBase.Core1Label); cores.Add(PAYNLSDK.API.RequestBase.Core2, PAYNLSDK.API.RequestBase.Core2Label); cores.Add(PAYNLSDK.API.RequestBase.Core3, PAYNLSDK.API.RequestBase.Core3Label); + cores.Add(PAYNLSDK.API.RequestBase.Core4, PAYNLSDK.API.RequestBase.Core4Label); comboBox1.DataSource = new BindingSource(cores, null); comboBox1.DisplayMember = "Value"; comboBox1.ValueMember = "Key"; diff --git a/PAYNLSDK/API/RequestBase.cs b/PAYNLSDK/API/RequestBase.cs index 21cd5ff..1614f85 100644 --- a/PAYNLSDK/API/RequestBase.cs +++ b/PAYNLSDK/API/RequestBase.cs @@ -27,18 +27,22 @@ public static Dictionary GetCores() cores.Add("Core1 (" + PAYNLSDK.API.RequestBase.Core1 + ")", PAYNLSDK.API.RequestBase.Core1Label); cores.Add("Core2 (" + PAYNLSDK.API.RequestBase.Core2 + ")", PAYNLSDK.API.RequestBase.Core2Label); cores.Add("Core3 (" + PAYNLSDK.API.RequestBase.Core3 + ")", PAYNLSDK.API.RequestBase.Core3Label); + cores.Add("Core4 (" + PAYNLSDK.API.RequestBase.Core4 + ")", PAYNLSDK.API.RequestBase.Core4Label); return cores; } /// /// PAYNL Cores /// - public static readonly string Core1 = "https://rest-api.pay.nl"; - public static readonly string Core1Label = "Pay.nl (Default)"; - public static readonly string Core2 = "https://rest.achterelkebetaling.nl"; + public static readonly string Core1 = "https://connect.pay.nl"; + public static readonly string Core1Label = "Connect.pay.nl (Default)"; + public static readonly string Core2 = "https://connect.achterelkebetaling.nl"; public static readonly string Core2Label = "Achterelkebetaling.nl"; - public static readonly string Core3 = "https://rest.payments.nl"; + public static readonly string Core3 = "https://connect.payments.nl"; public static readonly string Core3Label = "Payments.nl"; + public static readonly string Core4 = "https://rest-api.pay.nl"; + public static readonly string Core4Label = "Pay.nl"; + /// /// Indicator stating whether or not a Service ID is required for a specific request diff --git a/PAYNLSDK/API/Transaction/Start/Request.cs b/PAYNLSDK/API/Transaction/Start/Request.cs index 9738bb2..84d6b8f 100644 --- a/PAYNLSDK/API/Transaction/Start/Request.cs +++ b/PAYNLSDK/API/Transaction/Start/Request.cs @@ -68,7 +68,7 @@ public void SetServiceId(string value) public override int Version { - get { return 5; } + get { return 19; } } public override string Controller diff --git a/PAYNLSDK/Converters/DMYConverter.cs b/PAYNLSDK/Converters/DMYConverter.cs index 133d5c0..832b81f 100644 --- a/PAYNLSDK/Converters/DMYConverter.cs +++ b/PAYNLSDK/Converters/DMYConverter.cs @@ -18,10 +18,6 @@ public override void WriteJson(JsonWriter writer, object value, JsonSerializer s if (value is DateTime) { var dateTime = (DateTime)value; - if (dateTime.Kind == DateTimeKind.Unspecified) - { - throw new JsonSerializationException("Cannot convert date time with an unspecified kind"); - } string convertedDateTime = dateTime.ToString(Format); writer.WriteValue(convertedDateTime); }