From 2ea287cad4a2adb018093d5cfe70dd027bba616e Mon Sep 17 00:00:00 2001 From: Lukas Kytka Date: Thu, 9 Nov 2023 14:13:19 +0100 Subject: [PATCH] fixes an issue where when webapi adapter init db parameter was ingored --- .../WebApiConnectorExtensions.cs | 2 +- .../AXSharp.Connector.S71500.WebAPI/WebApiConnectorFactory.cs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorExtensions.cs b/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorExtensions.cs index d05af13b..70f81227 100644 --- a/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorExtensions.cs +++ b/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorExtensions.cs @@ -31,7 +31,7 @@ public static ConnectorAdapter CreateWebApi(this ConnectorAdapterBuilder adapter string dbName = "\"TGlobalVariablesDB\"") { return new ConnectorAdapter(typeof(WebApiConnectorFactory)) - { Parameters = new object[] { ipAddress, userName, password, ignoreSSLErros } }; + { Parameters = new object[] { ipAddress, userName, password, ignoreSSLErros, dbName } }; } /// diff --git a/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorFactory.cs b/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorFactory.cs index d0719fc4..3f3c833b 100644 --- a/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorFactory.cs +++ b/src/AXSharp.connectors/src/AXSharp.Connector.S71500.WebAPI/WebApiConnectorFactory.cs @@ -18,7 +18,8 @@ public override Connector CreateConnector(object[] parameters) return new WebApiConnector((string)parameters[0], (string)parameters[1], (string)parameters[2], - (bool)parameters[3]); + (bool)parameters[3], + (string)parameters[4]); } ///