MS
This commit is contained in:
@@ -40,6 +40,7 @@ Public Class ClassInit
|
||||
_Loader.AddStep("Initializing EDMI Service", AddressOf InitializeService, True)
|
||||
_Loader.AddStep("Initializing Database", AddressOf InitializeDatabaseWithFallback, True)
|
||||
_Loader.AddStep("Initializing User", AddressOf InitializeUser, True)
|
||||
_Loader.AddStep("Initializing BasicCatalogues", AddressOf InitializeBasicsfromDB, True)
|
||||
_Loader.AddStep("Initializing Language", AddressOf InitializeLanguage, False)
|
||||
_Loader.AddStep("Initializing 3rd-party licenses", AddressOf Initialize3rdParty, False)
|
||||
_Loader.AddStep("Initializing Basic Config", AddressOf InitBasicConfig, False)
|
||||
@@ -193,6 +194,31 @@ Public Class ClassInit
|
||||
Throw New InitException($"Unexpected error while initializing user!", ex)
|
||||
End Try
|
||||
End Sub
|
||||
Private Sub InitializeBasicsfromDB(MyApplication As My.MyApplication)
|
||||
Try
|
||||
Dim oSql As String = My.Queries.Common.IDB_CATALOG()
|
||||
Dim oDatatable As DataTable = My.Database.GetDatatableIDB(oSql)
|
||||
For Each oRow As DataRow In oDatatable.Rows
|
||||
Dim oCAT_TITLE As String = oRow.Item("CAT_TITLE")
|
||||
|
||||
Select Case oCAT_TITLE
|
||||
Case "AHWF_CMD_USR_SELECT"
|
||||
AHWF_CMD_USR_SELECT = oRow.Item("CAT_STRING")
|
||||
Case "AHWF_CMD_LAYOUT_SELECT"
|
||||
AHWF_CMD_LAYOUT_SELECT = oRow.Item("CAT_STRING")
|
||||
|
||||
End Select
|
||||
Next
|
||||
|
||||
Catch ex As InitException
|
||||
Logger.Error(ex)
|
||||
Throw ex
|
||||
|
||||
Catch ex As Exception
|
||||
Logger.Error(ex)
|
||||
Throw New InitException($"Unexpected error while initializing basics from DB!", ex)
|
||||
End Try
|
||||
End Sub
|
||||
Private Sub InitializeLanguage(MyApplication As My.MyApplication)
|
||||
Dim oLanguage = MyApplication.User.Language
|
||||
Dim oDateFormat = MyApplication.User.DateFormat
|
||||
|
||||
Reference in New Issue
Block a user