ZooFlow: Switch to new database
This commit is contained in:
@@ -148,7 +148,6 @@ Public Class ClassDetailForm
|
||||
Public Property Entity As String
|
||||
Public Property Scope As String
|
||||
Public Property PrimaryKey As String
|
||||
Public Property ForeignKey As String
|
||||
Public Property SQLCommand As String
|
||||
Public Property SQLResult As DataTable
|
||||
End Class
|
||||
|
||||
@@ -39,18 +39,18 @@ Public Class ClassDetailPages
|
||||
End Class
|
||||
|
||||
Public Class DetailPage
|
||||
Public IsPrimary As Boolean = False
|
||||
Public IsInsert As Boolean = False
|
||||
Public TabPage As XtraTabPage
|
||||
Public Name As String
|
||||
Public Property IsPrimary As Boolean = False
|
||||
Public Property IsInsert As Boolean = False
|
||||
Public Property TabPage As XtraTabPage
|
||||
Public Property Name As String
|
||||
<Description("The Binding Source for the Form")>
|
||||
Public BindingSource As BindingSource
|
||||
Public Property BindingSource As BindingSource
|
||||
<Description("The Bound Datatable in the Dataset (eg. MyDataset.TB_FOO_TABLE)")>
|
||||
Public DataTable As DataTable
|
||||
Public Property DataTable As DataTable
|
||||
<Description("The TextEdit Control containing the AddedWho value")>
|
||||
Public AddedWhoEdit As TextEdit
|
||||
Public Property AddedWhoEdit As TextEdit
|
||||
<Description("The TextEdit Control containing the ChangedWhoEdit value")>
|
||||
Public ChangedWhoEdit As TextEdit
|
||||
Public Property ChangedWhoEdit As TextEdit
|
||||
End Class
|
||||
|
||||
''' <summary>
|
||||
@@ -100,7 +100,11 @@ Public Class ClassDetailPages
|
||||
''' Add a new DetailPage or a new PrimaryPage
|
||||
''' </summary>
|
||||
Public Sub Add(Page As DetailPage)
|
||||
Items.Add(Page.TabPage.Name, Page)
|
||||
If Page.TabPage Is Nothing Then
|
||||
Items.Add("Primary", Page)
|
||||
Else
|
||||
Items.Add(Page.TabPage.Name, Page)
|
||||
End If
|
||||
|
||||
AddHandler Page.BindingSource.AddingNew, Sub(sender As Object, e As EventArgs)
|
||||
RaiseChangedEvents = False
|
||||
|
||||
@@ -73,10 +73,6 @@ Public Class frmAdmin_Globix
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Sub SimpleButton2_Click(sender As Object, e As EventArgs) Handles SimpleButton2.Click
|
||||
|
||||
End Sub
|
||||
|
||||
Public Function DeleteData() As Boolean Implements IAdminForm.DeleteData
|
||||
Throw New NotImplementedException()
|
||||
End Function
|
||||
|
||||
@@ -139,7 +139,7 @@ Partial Class frmAdmin_Start
|
||||
Me.RibbonControl1.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1})
|
||||
Me.RibbonControl1.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False]
|
||||
Me.RibbonControl1.ShowToolbarCustomizeItem = False
|
||||
Me.RibbonControl1.Size = New System.Drawing.Size(1077, 158)
|
||||
Me.RibbonControl1.Size = New System.Drawing.Size(1077, 159)
|
||||
Me.RibbonControl1.StatusBar = Me.RibbonStatusBar1
|
||||
Me.RibbonControl1.Toolbar.ShowCustomizeItem = False
|
||||
'
|
||||
@@ -381,10 +381,10 @@ Partial Class frmAdmin_Start
|
||||
'
|
||||
Me.RibbonStatusBar1.ItemLinks.Add(Me.labelStatus)
|
||||
Me.RibbonStatusBar1.ItemLinks.Add(Me.labelError)
|
||||
Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 652)
|
||||
Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 654)
|
||||
Me.RibbonStatusBar1.Name = "RibbonStatusBar1"
|
||||
Me.RibbonStatusBar1.Ribbon = Me.RibbonControl1
|
||||
Me.RibbonStatusBar1.Size = New System.Drawing.Size(1077, 24)
|
||||
Me.RibbonStatusBar1.Size = New System.Drawing.Size(1077, 22)
|
||||
'
|
||||
'RibbonPage2
|
||||
'
|
||||
@@ -406,9 +406,9 @@ Partial Class frmAdmin_Start
|
||||
Me.TreeListMenu.AppendNode(New Object() {"IDB"}, -1, "")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Attribute"}, 0, 2, 2, -1, "IDB_ATTRIBUTES")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Business Entities"}, 0, 1, 1, -1, "IDB_BUSINESS_ENTITIES")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Global Indexer"}, -1, "")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Global Indexer"}, -1, 6, 6, -1, "")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Profiles"}, 3, 4, 4, -1, "GLOBIX_PROFILES")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Clipboard Watcher"}, -1, "")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Clipboard Watcher"}, -1, 7, 7, -1, "")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Profiles"}, 5, 4, 4, -1, "CW_PROFILES")
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Administration"}, -1)
|
||||
Me.TreeListMenu.AppendNode(New Object() {"Source SQL"}, 7, 3, 3, -1, "META_SOURCE_SQL")
|
||||
@@ -419,7 +419,7 @@ Partial Class frmAdmin_Start
|
||||
Me.TreeListMenu.OptionsView.ShowIndicator = False
|
||||
Me.TreeListMenu.OptionsView.ShowVertLines = False
|
||||
Me.TreeListMenu.SelectImageList = Me.MainTreeImages
|
||||
Me.TreeListMenu.Size = New System.Drawing.Size(193, 465)
|
||||
Me.TreeListMenu.Size = New System.Drawing.Size(193, 446)
|
||||
Me.TreeListMenu.TabIndex = 8
|
||||
'
|
||||
'TreeListColumn1
|
||||
@@ -438,6 +438,8 @@ Partial Class frmAdmin_Start
|
||||
Me.MainTreeImages.Add("managedatasource", "image://svgimages/spreadsheet/managedatasource.svg")
|
||||
Me.MainTreeImages.Add("grandtotals", "image://svgimages/dashboards/grandtotals.svg")
|
||||
Me.MainTreeImages.Add("allowuserstoeditranges", "image://svgimages/spreadsheet/allowuserstoeditranges.svg")
|
||||
Me.MainTreeImages.Add("ZooFlow_G_DevExpress", "ZooFlow_G_DevExpress", GetType(DigitalData.GUIs.ZooFlow.My.Resources.Resources))
|
||||
Me.MainTreeImages.Add("ZooFlow_CW_DevExpress", "ZooFlow_CW_DevExpress", GetType(DigitalData.GUIs.ZooFlow.My.Resources.Resources))
|
||||
'
|
||||
'DockManager1
|
||||
'
|
||||
@@ -450,18 +452,18 @@ Partial Class frmAdmin_Start
|
||||
Me.DockPanel1.Controls.Add(Me.DockPanel1_Container)
|
||||
Me.DockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Left
|
||||
Me.DockPanel1.ID = New System.Guid("ce81b5b5-eff5-4006-8018-548aa8413799")
|
||||
Me.DockPanel1.Location = New System.Drawing.Point(0, 158)
|
||||
Me.DockPanel1.Location = New System.Drawing.Point(0, 159)
|
||||
Me.DockPanel1.Name = "DockPanel1"
|
||||
Me.DockPanel1.OriginalSize = New System.Drawing.Size(200, 200)
|
||||
Me.DockPanel1.Size = New System.Drawing.Size(200, 494)
|
||||
Me.DockPanel1.Size = New System.Drawing.Size(200, 495)
|
||||
Me.DockPanel1.Text = "Übersicht"
|
||||
'
|
||||
'DockPanel1_Container
|
||||
'
|
||||
Me.DockPanel1_Container.Controls.Add(Me.TreeListMenu)
|
||||
Me.DockPanel1_Container.Location = New System.Drawing.Point(3, 26)
|
||||
Me.DockPanel1_Container.Location = New System.Drawing.Point(3, 46)
|
||||
Me.DockPanel1_Container.Name = "DockPanel1_Container"
|
||||
Me.DockPanel1_Container.Size = New System.Drawing.Size(193, 465)
|
||||
Me.DockPanel1_Container.Size = New System.Drawing.Size(193, 446)
|
||||
Me.DockPanel1_Container.TabIndex = 0
|
||||
'
|
||||
'TBIDB_ATTRIBUTEBindingSource
|
||||
@@ -511,7 +513,7 @@ Partial Class frmAdmin_Start
|
||||
'
|
||||
Me.Panel1.Controls.Add(Me.labelTitle)
|
||||
Me.Panel1.Dock = System.Windows.Forms.DockStyle.Top
|
||||
Me.Panel1.Location = New System.Drawing.Point(200, 158)
|
||||
Me.Panel1.Location = New System.Drawing.Point(200, 159)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(877, 40)
|
||||
Me.Panel1.TabIndex = 8
|
||||
@@ -714,11 +716,11 @@ Partial Class frmAdmin_Start
|
||||
'GridControl1
|
||||
'
|
||||
Me.GridControl1.Dock = System.Windows.Forms.DockStyle.Fill
|
||||
Me.GridControl1.Location = New System.Drawing.Point(200, 198)
|
||||
Me.GridControl1.Location = New System.Drawing.Point(200, 199)
|
||||
Me.GridControl1.MainView = Me.GridView1
|
||||
Me.GridControl1.MenuManager = Me.RibbonControl1
|
||||
Me.GridControl1.Name = "GridControl1"
|
||||
Me.GridControl1.Size = New System.Drawing.Size(877, 454)
|
||||
Me.GridControl1.Size = New System.Drawing.Size(877, 455)
|
||||
Me.GridControl1.TabIndex = 12
|
||||
Me.GridControl1.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.GridView1})
|
||||
'
|
||||
|
||||
@@ -32,6 +32,8 @@ Public Class frmAdmin_Start
|
||||
End Sub
|
||||
|
||||
Private Function Handle_LoadPage(Page As String) As Boolean
|
||||
Dim oKey = $"{Page}-OVERVIEW"
|
||||
|
||||
If DetailForm.DetailSettingsList.ContainsKey(Page) Then
|
||||
Dim oNode = DetailForm.DetailSettingsList.Item(Page)
|
||||
CurrentModule = oNode.Module
|
||||
@@ -43,8 +45,11 @@ Public Class frmAdmin_Start
|
||||
Return False
|
||||
End If
|
||||
|
||||
If DetailForm.DetailDataList.ContainsKey(Page) Then
|
||||
Dim oItem = DetailForm.DetailDataList.Item(Page)
|
||||
' This dictionary can contain the same entity multiple times to save
|
||||
' OVERVIEW, INSERT, UPDATE, etc. data records, so we specifically look for the overview key
|
||||
If DetailForm.DetailDataList.ContainsKey(oKey) Then
|
||||
|
||||
Dim oItem = DetailForm.DetailDataList.Item(oKey)
|
||||
Load_GridData(oItem)
|
||||
CurrentItem = oItem
|
||||
Else
|
||||
@@ -68,8 +73,7 @@ Public Class frmAdmin_Start
|
||||
.Entity = oRow.Item("ENTITY_TITLE").ToString,
|
||||
.Scope = oRow.Item("SCOPE").ToString,
|
||||
.SQLCommand = oRow.Item("SQL_COMMAND").ToString,
|
||||
.PrimaryKey = NotNull(oRow.Item("PK_COLUMN"), String.Empty),
|
||||
.ForeignKey = NotNull(oRow.Item("FK_COLUMN"), String.Empty)
|
||||
.PrimaryKey = NotNull(oRow.Item("PK_COLUMN"), String.Empty)
|
||||
}
|
||||
|
||||
Try
|
||||
@@ -79,12 +83,13 @@ Public Class frmAdmin_Start
|
||||
Logger.Error(ex)
|
||||
End Try
|
||||
|
||||
DetailForm.DetailDataList.Add(oItem.Entity, oItem)
|
||||
Dim oKey As String = oItem.Entity & "-" & oItem.Scope
|
||||
DetailForm.DetailDataList.Add(oKey, oItem)
|
||||
Next
|
||||
|
||||
Return True
|
||||
Catch ex As Exception
|
||||
Logger.Error(ex)
|
||||
ShowErrorMessage(ex)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Reference in New Issue
Block a user