diff --git a/EgtBEAMWALL.DataLayer/App.config b/EgtBEAMWALL.DataLayer/App.config
index 940222da..0c196c0f 100644
--- a/EgtBEAMWALL.DataLayer/App.config
+++ b/EgtBEAMWALL.DataLayer/App.config
@@ -12,7 +12,7 @@
-
+
diff --git a/EgtBEAMWALL.DataLayer/DatabaseContext.cs b/EgtBEAMWALL.DataLayer/DatabaseContext.cs
index 1a5289f8..4e2a60f6 100644
--- a/EgtBEAMWALL.DataLayer/DatabaseContext.cs
+++ b/EgtBEAMWALL.DataLayer/DatabaseContext.cs
@@ -39,9 +39,9 @@ namespace EgtBEAMWALL.DataLayer
public DatabaseContext(string connectionString) : base(connectionString)
{
- Database.CreateIfNotExists();
- //Database.SetInitializer(new MigrateDatabaseToLatestVersion());
- Database.Initialize(false);
+ //Database.CreateIfNotExists();
+ ////Database.SetInitializer(new MigrateDatabaseToLatestVersion());
+ //Database.Initialize(false);
}
#endregion Public Constructors
diff --git a/EgtBEAMWALL.Supervisor/app.config b/EgtBEAMWALL.Supervisor/app.config
index 73906323..8c34ec52 100644
--- a/EgtBEAMWALL.Supervisor/app.config
+++ b/EgtBEAMWALL.Supervisor/app.config
@@ -12,7 +12,7 @@
-
+
diff --git a/EgtBEAMWALL.ViewerOptimizer/App.config b/EgtBEAMWALL.ViewerOptimizer/App.config
index de196b59..a211fcdb 100644
--- a/EgtBEAMWALL.ViewerOptimizer/App.config
+++ b/EgtBEAMWALL.ViewerOptimizer/App.config
@@ -12,7 +12,7 @@
-
+
diff --git a/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb b/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb
index bc91e22b..488ae6e5 100644
--- a/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb
+++ b/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb
@@ -104,6 +104,7 @@ Public Class MainWindowVM
End Sub
Friend Sub ContentRendered()
+ DbControllers.Init()
'' chiamata a caso su Db per inizializzarlo
DbControllers.m_ProjController.FindByProjDbId(0)
' Verifico che l'inizializzazione di tutte le parti del programma sia andata a buon fine
diff --git a/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb b/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb
index 0a961b4a..142ee3d4 100644
--- a/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb
+++ b/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb
@@ -1,6 +1,6 @@
Imports EgtUILib
-Module DbControllers
+Public Module DbControllers
Friend m_SupervisorId As String = "1"
@@ -9,6 +9,27 @@ Module DbControllers
Public m_MachGroupController As DataLayer.Controllers.MachGroupController
Public m_StatusMapController As DataLayer.Controllers.StatusMapController
+ Sub Init()
+
+ ' ' se demo--> server = db.steamware.net, nKey e sKey come le hai...
+
+ ' Dim sKey = "", sUser = "", sPwd = ""
+
+ ' EgtGetKeyInfo(sKey)
+ ' sKey = sKey.Replace(" ", "")
+ ' If Not IsNothing(sKey) AndAlso sKey.Length > 11 Then
+ ' sUser = sKey.Substring(3, 6)
+ ' sPwd = sKey.Substring(10, sKey.Length - 10).Replace("(", "").Replace(")", "")
+ ' End If
+ ' DataLayer.DbConfig.InitDb("127.0.0.1", sUser, sPwd)
+ ' DataLayer.DbConfig.CheckUser(sUser, sPwd)
+
+ ' m_ProjController = New DataLayer.Controllers.ProjController
+ ' m_ProdController = New DataLayer.Controllers.ProdController
+ ' m_MachGroupController = New DataLayer.Controllers.MachGroupController
+ ' m_StatusMapController = New DataLayer.Controllers.StatusMapController
+ End Sub
+
Sub New()
' se demo--> server = db.steamware.net, nKey e sKey come le hai...