From d4c4a4412abfc3798987ebf51c7fb34d4c8e373a Mon Sep 17 00:00:00 2001 From: Jonathan Jenne Date: Wed, 24 Feb 2021 16:41:43 +0100 Subject: [PATCH] ZooFlow: WIP Administration --- .../Administration/frmAdmin_Start.Designer.vb | 299 +++++++++++++----- .../Administration/frmAdmin_Start.resx | 24 +- GUIs.ZooFlow/Administration/frmAdmin_Start.vb | 262 +++++++++------ 3 files changed, 414 insertions(+), 171 deletions(-) diff --git a/GUIs.ZooFlow/Administration/frmAdmin_Start.Designer.vb b/GUIs.ZooFlow/Administration/frmAdmin_Start.Designer.vb index 4816f490..36bd1acd 100644 --- a/GUIs.ZooFlow/Administration/frmAdmin_Start.Designer.vb +++ b/GUIs.ZooFlow/Administration/frmAdmin_Start.Designer.vb @@ -34,7 +34,13 @@ Partial Class frmAdmin_Start Dim VIEW_SEQUENCELabel As System.Windows.Forms.Label Dim TITLELabel As System.Windows.Forms.Label Dim GUIDLabel As System.Windows.Forms.Label + Dim GridLevelNode1 As DevExpress.XtraGrid.GridLevelNode = New DevExpress.XtraGrid.GridLevelNode() + Dim GridLevelNode2 As DevExpress.XtraGrid.GridLevelNode = New DevExpress.XtraGrid.GridLevelNode() + Dim GridLevelNode3 As DevExpress.XtraGrid.GridLevelNode = New DevExpress.XtraGrid.GridLevelNode() Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmAdmin_Start)) + Me.ViewCWProcesses = New DevExpress.XtraGrid.Views.Grid.GridView() + Me.GridCWProfiles = New DevExpress.XtraGrid.GridControl() + Me.WinExplorerView1 = New DevExpress.XtraGrid.Views.WinExplorer.WinExplorerView() Me.RibbonControl1 = New DevExpress.XtraBars.Ribbon.RibbonControl() Me.BarButtonItem1 = New DevExpress.XtraBars.BarButtonItem() Me.BarButtonItem2 = New DevExpress.XtraBars.BarButtonItem() @@ -63,10 +69,12 @@ Partial Class frmAdmin_Start Me.RibbonPage_IDB = New DevExpress.XtraBars.Ribbon.RibbonPage() Me.RibbonPageGroupAttributes = New DevExpress.XtraBars.Ribbon.RibbonPageGroup() Me.RibbonStatusBar1 = New DevExpress.XtraBars.Ribbon.RibbonStatusBar() + Me.ViewCWWindows = New DevExpress.XtraGrid.Views.Grid.GridView() + Me.ViewCWControls = New DevExpress.XtraGrid.Views.Grid.GridView() Me.RibbonPage2 = New DevExpress.XtraBars.Ribbon.RibbonPage() Me.TreeListMenu = New DevExpress.XtraTreeList.TreeList() Me.TreeListColumn1 = New DevExpress.XtraTreeList.Columns.TreeListColumn() - Me.SvgImageCollection1 = New DevExpress.Utils.SvgImageCollection(Me.components) + Me.MainTreeImages = New DevExpress.Utils.SvgImageCollection(Me.components) Me.DockManager1 = New DevExpress.XtraBars.Docking.DockManager(Me.components) Me.DockPanel1 = New DevExpress.XtraBars.Docking.DockPanel() Me.DockPanel1_Container = New DevExpress.XtraBars.Docking.ControlContainer() @@ -81,6 +89,7 @@ Partial Class frmAdmin_Start Me.XtraTabPageIDB_Attributes_New = New DevExpress.XtraTab.XtraTabPage() Me.GridAttributes = New DevExpress.XtraGrid.GridControl() Me.ViewAttributes = New DevExpress.XtraGrid.Views.Grid.GridView() + Me.GridView2 = New DevExpress.XtraGrid.Views.Grid.GridView() Me.XtraTabPageIDB_Attributes = New DevExpress.XtraTab.XtraTabPage() Me.ComboBox1 = New System.Windows.Forms.ComboBox() Me.GridControl1 = New DevExpress.XtraGrid.GridControl() @@ -103,11 +112,18 @@ Partial Class frmAdmin_Start Me.GridSourceSQL = New DevExpress.XtraGrid.GridControl() Me.ViewSourceSQL = New DevExpress.XtraGrid.Views.Grid.GridView() Me.XtraTabPage_GlobalIndexer = New DevExpress.XtraTab.XtraTabPage() + Me.TreeList2 = New DevExpress.XtraTreeList.TreeList() + Me.GLOBIXImages = New DevExpress.Utils.SvgImageCollection(Me.components) Me.XtraTabPage_ClipboardWatcher = New DevExpress.XtraTab.XtraTabPage() Me.XtraTabControl1 = New DevExpress.XtraTab.XtraTabControl() Me.XtraTabPageCWProfiles = New DevExpress.XtraTab.XtraTabPage() - Me.GridCWProfiles = New DevExpress.XtraGrid.GridControl() - Me.ViewCWProfiles = New DevExpress.XtraGrid.Views.Grid.GridView() + Me.TreeList1 = New DevExpress.XtraTreeList.TreeList() + Me.COL_ENTITY = New DevExpress.XtraTreeList.Columns.TreeListColumn() + Me.COL_ENITY_SCOPE = New DevExpress.XtraTreeList.Columns.TreeListColumn() + Me.COL_PARENT = New DevExpress.XtraTreeList.Columns.TreeListColumn() + Me.COL_GUID = New DevExpress.XtraTreeList.Columns.TreeListColumn() + Me.COL_NODE_TITLE = New DevExpress.XtraTreeList.Columns.TreeListColumn() + Me.CWImages = New DevExpress.Utils.SvgImageCollection(Me.components) Me.XtraTabPage2 = New DevExpress.XtraTab.XtraTabPage() Me.XtraTabControl = New DevExpress.XtraTab.XtraTabControl() CHANGED_WHENLabel = New System.Windows.Forms.Label() @@ -118,9 +134,14 @@ Partial Class frmAdmin_Start VIEW_SEQUENCELabel = New System.Windows.Forms.Label() TITLELabel = New System.Windows.Forms.Label() GUIDLabel = New System.Windows.Forms.Label() + CType(Me.ViewCWProcesses, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.GridCWProfiles, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.WinExplorerView1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.RibbonControl1, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.ViewCWWindows, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.ViewCWControls, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.TreeListMenu, System.ComponentModel.ISupportInitialize).BeginInit() - CType(Me.SvgImageCollection1, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.MainTreeImages, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.DockManager1, System.ComponentModel.ISupportInitialize).BeginInit() Me.DockPanel1.SuspendLayout() Me.DockPanel1_Container.SuspendLayout() @@ -133,18 +154,22 @@ Partial Class frmAdmin_Start Me.XtraTabPageIDB_Attributes_New.SuspendLayout() CType(Me.GridAttributes, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.ViewAttributes, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.GridView2, System.ComponentModel.ISupportInitialize).BeginInit() Me.XtraTabPageIDB_Attributes.SuspendLayout() CType(Me.GridControl1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.GridView1, System.ComponentModel.ISupportInitialize).BeginInit() Me.XtraTabPageIDB_SourceSQL.SuspendLayout() CType(Me.GridSourceSQL, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.ViewSourceSQL, System.ComponentModel.ISupportInitialize).BeginInit() + Me.XtraTabPage_GlobalIndexer.SuspendLayout() + CType(Me.TreeList2, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.GLOBIXImages, System.ComponentModel.ISupportInitialize).BeginInit() Me.XtraTabPage_ClipboardWatcher.SuspendLayout() CType(Me.XtraTabControl1, System.ComponentModel.ISupportInitialize).BeginInit() Me.XtraTabControl1.SuspendLayout() Me.XtraTabPageCWProfiles.SuspendLayout() - CType(Me.GridCWProfiles, System.ComponentModel.ISupportInitialize).BeginInit() - CType(Me.ViewCWProfiles, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.TreeList1, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.CWImages, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.XtraTabControl, System.ComponentModel.ISupportInitialize).BeginInit() Me.XtraTabControl.SuspendLayout() Me.SuspendLayout() @@ -154,7 +179,7 @@ Partial Class frmAdmin_Start CHANGED_WHENLabel.AutoSize = True CHANGED_WHENLabel.Location = New System.Drawing.Point(472, 188) CHANGED_WHENLabel.Name = "CHANGED_WHENLabel" - CHANGED_WHENLabel.Size = New System.Drawing.Size(85, 13) + CHANGED_WHENLabel.Size = New System.Drawing.Size(90, 13) CHANGED_WHENLabel.TabIndex = 20 CHANGED_WHENLabel.Text = "Geändert wann:" ' @@ -163,7 +188,7 @@ Partial Class frmAdmin_Start CHANGED_WHOLabel.AutoSize = True CHANGED_WHOLabel.Location = New System.Drawing.Point(351, 188) CHANGED_WHOLabel.Name = "CHANGED_WHOLabel" - CHANGED_WHOLabel.Size = New System.Drawing.Size(77, 13) + CHANGED_WHOLabel.Size = New System.Drawing.Size(80, 13) CHANGED_WHOLabel.TabIndex = 18 CHANGED_WHOLabel.Text = "Geändert wer:" ' @@ -172,7 +197,7 @@ Partial Class frmAdmin_Start ADDED_WHENLabel.AutoSize = True ADDED_WHENLabel.Location = New System.Drawing.Point(472, 146) ADDED_WHENLabel.Name = "ADDED_WHENLabel" - ADDED_WHENLabel.Size = New System.Drawing.Size(73, 13) + ADDED_WHENLabel.Size = New System.Drawing.Size(77, 13) ADDED_WHENLabel.TabIndex = 16 ADDED_WHENLabel.Text = "Erstellt wann:" ' @@ -181,7 +206,7 @@ Partial Class frmAdmin_Start ADDED_WHOLabel.AutoSize = True ADDED_WHOLabel.Location = New System.Drawing.Point(351, 146) ADDED_WHOLabel.Name = "ADDED_WHOLabel" - ADDED_WHOLabel.Size = New System.Drawing.Size(65, 13) + ADDED_WHOLabel.Size = New System.Drawing.Size(67, 13) ADDED_WHOLabel.TabIndex = 14 ADDED_WHOLabel.Text = "Erstellt wer:" ' @@ -190,7 +215,7 @@ Partial Class frmAdmin_Start COMMENTLabel.AutoSize = True COMMENTLabel.Location = New System.Drawing.Point(351, 106) COMMENTLabel.Name = "COMMENTLabel" - COMMENTLabel.Size = New System.Drawing.Size(65, 13) + COMMENTLabel.Size = New System.Drawing.Size(68, 13) COMMENTLabel.TabIndex = 12 COMMENTLabel.Text = "Kommentar:" ' @@ -199,7 +224,7 @@ Partial Class frmAdmin_Start VIEW_SEQUENCELabel.AutoSize = True VIEW_SEQUENCELabel.Location = New System.Drawing.Point(351, 82) VIEW_SEQUENCELabel.Name = "VIEW_SEQUENCELabel" - VIEW_SEQUENCELabel.Size = New System.Drawing.Size(93, 13) + VIEW_SEQUENCELabel.Size = New System.Drawing.Size(101, 13) VIEW_SEQUENCELabel.TabIndex = 8 VIEW_SEQUENCELabel.Text = "View Reihenfolge:" ' @@ -208,7 +233,7 @@ Partial Class frmAdmin_Start TITLELabel.AutoSize = True TITLELabel.Location = New System.Drawing.Point(351, 12) TITLELabel.Name = "TITLELabel" - TITLELabel.Size = New System.Drawing.Size(71, 13) + TITLELabel.Size = New System.Drawing.Size(76, 13) TITLELabel.TabIndex = 2 TITLELabel.Text = "Bezeichnung:" ' @@ -217,10 +242,40 @@ Partial Class frmAdmin_Start GUIDLabel.AutoSize = True GUIDLabel.Location = New System.Drawing.Point(297, 12) GUIDLabel.Name = "GUIDLabel" - GUIDLabel.Size = New System.Drawing.Size(36, 13) + GUIDLabel.Size = New System.Drawing.Size(37, 13) GUIDLabel.TabIndex = 0 GUIDLabel.Text = "GUID:" ' + 'ViewCWProcesses + ' + Me.ViewCWProcesses.GridControl = Me.GridCWProfiles + Me.ViewCWProcesses.Name = "ViewCWProcesses" + Me.ViewCWProcesses.VertScrollVisibility = DevExpress.XtraGrid.Views.Base.ScrollVisibility.Never + ' + 'GridCWProfiles + ' + GridLevelNode1.LevelTemplate = Me.ViewCWProcesses + GridLevelNode2.LevelTemplate = Me.ViewCWWindows + GridLevelNode3.LevelTemplate = Me.ViewCWControls + GridLevelNode3.RelationName = "Level3" + GridLevelNode2.Nodes.AddRange(New DevExpress.XtraGrid.GridLevelNode() {GridLevelNode3}) + GridLevelNode2.RelationName = "Level2" + GridLevelNode1.Nodes.AddRange(New DevExpress.XtraGrid.GridLevelNode() {GridLevelNode2}) + GridLevelNode1.RelationName = "Level1" + Me.GridCWProfiles.LevelTree.Nodes.AddRange(New DevExpress.XtraGrid.GridLevelNode() {GridLevelNode1}) + Me.GridCWProfiles.Location = New System.Drawing.Point(819, 41) + Me.GridCWProfiles.MainView = Me.WinExplorerView1 + Me.GridCWProfiles.MenuManager = Me.RibbonControl1 + Me.GridCWProfiles.Name = "GridCWProfiles" + Me.GridCWProfiles.Size = New System.Drawing.Size(319, 266) + Me.GridCWProfiles.TabIndex = 0 + Me.GridCWProfiles.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.WinExplorerView1, Me.ViewCWWindows, Me.ViewCWControls, Me.ViewCWProcesses}) + ' + 'WinExplorerView1 + ' + Me.WinExplorerView1.GridControl = Me.GridCWProfiles + Me.WinExplorerView1.Name = "WinExplorerView1" + ' 'RibbonControl1 ' Me.RibbonControl1.ExpandCollapseItem.Id = 0 @@ -231,7 +286,7 @@ Partial Class frmAdmin_Start Me.RibbonControl1.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1, Me.RibbonPage_ClipboardWatcher, Me.RibbonPage_GlobalIndexer, Me.RibbonPage_IDB}) Me.RibbonControl1.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.[False] Me.RibbonControl1.ShowToolbarCustomizeItem = False - Me.RibbonControl1.Size = New System.Drawing.Size(1328, 158) + Me.RibbonControl1.Size = New System.Drawing.Size(1328, 159) Me.RibbonControl1.StatusBar = Me.RibbonStatusBar1 Me.RibbonControl1.Toolbar.ShowCustomizeItem = False ' @@ -420,10 +475,20 @@ Partial Class frmAdmin_Start ' Me.RibbonStatusBar1.ItemLinks.Add(Me.labelStatus) Me.RibbonStatusBar1.ItemLinks.Add(Me.labelError) - Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 727) + Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 729) Me.RibbonStatusBar1.Name = "RibbonStatusBar1" Me.RibbonStatusBar1.Ribbon = Me.RibbonControl1 - Me.RibbonStatusBar1.Size = New System.Drawing.Size(1328, 24) + Me.RibbonStatusBar1.Size = New System.Drawing.Size(1328, 22) + ' + 'ViewCWWindows + ' + Me.ViewCWWindows.GridControl = Me.GridCWProfiles + Me.ViewCWWindows.Name = "ViewCWWindows" + ' + 'ViewCWControls + ' + Me.ViewCWControls.GridControl = Me.GridCWProfiles + Me.ViewCWControls.Name = "ViewCWControls" ' 'RibbonPage2 ' @@ -454,8 +519,8 @@ Partial Class frmAdmin_Start Me.TreeListMenu.OptionsView.ShowHorzLines = False Me.TreeListMenu.OptionsView.ShowIndicator = False Me.TreeListMenu.OptionsView.ShowVertLines = False - Me.TreeListMenu.SelectImageList = Me.SvgImageCollection1 - Me.TreeListMenu.Size = New System.Drawing.Size(193, 540) + Me.TreeListMenu.SelectImageList = Me.MainTreeImages + Me.TreeListMenu.Size = New System.Drawing.Size(193, 521) Me.TreeListMenu.TabIndex = 8 ' 'TreeListColumn1 @@ -466,14 +531,14 @@ Partial Class frmAdmin_Start Me.TreeListColumn1.Visible = True Me.TreeListColumn1.VisibleIndex = 0 ' - 'SvgImageCollection1 + 'MainTreeImages ' - Me.SvgImageCollection1.Add("shopping_box", "image://svgimages/icon builder/shopping_box.svg") - Me.SvgImageCollection1.Add("bo_organization", "image://svgimages/business objects/bo_organization.svg") - Me.SvgImageCollection1.Add("bo_appearance", "image://svgimages/business objects/bo_appearance.svg") - Me.SvgImageCollection1.Add("managedatasource", "image://svgimages/spreadsheet/managedatasource.svg") - Me.SvgImageCollection1.Add("grandtotals", "image://svgimages/dashboards/grandtotals.svg") - Me.SvgImageCollection1.Add("allowuserstoeditranges", "image://svgimages/spreadsheet/allowuserstoeditranges.svg") + Me.MainTreeImages.Add("shopping_box", "image://svgimages/icon builder/shopping_box.svg") + Me.MainTreeImages.Add("bo_organization", "image://svgimages/business objects/bo_organization.svg") + Me.MainTreeImages.Add("bo_appearance", "image://svgimages/business objects/bo_appearance.svg") + 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") ' 'DockManager1 ' @@ -486,18 +551,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, 569) + Me.DockPanel1.Size = New System.Drawing.Size(200, 570) 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, 540) + Me.DockPanel1_Container.Size = New System.Drawing.Size(193, 521) Me.DockPanel1_Container.TabIndex = 0 ' 'TBIDB_ATTRIBUTEBindingSource @@ -537,7 +602,7 @@ Partial Class frmAdmin_Start ' Me.XtraTabPage_IDB.Controls.Add(Me.XtraTabControlIDB) Me.XtraTabPage_IDB.Name = "XtraTabPage_IDB" - Me.XtraTabPage_IDB.Size = New System.Drawing.Size(1126, 544) + Me.XtraTabPage_IDB.Size = New System.Drawing.Size(1126, 547) Me.XtraTabPage_IDB.Text = "IDB" ' 'XtraTabControlIDB @@ -546,7 +611,7 @@ Partial Class frmAdmin_Start Me.XtraTabControlIDB.Location = New System.Drawing.Point(0, 0) Me.XtraTabControlIDB.Name = "XtraTabControlIDB" Me.XtraTabControlIDB.SelectedTabPage = Me.XtraTabPageIDB_Attributes_New - Me.XtraTabControlIDB.Size = New System.Drawing.Size(1126, 544) + Me.XtraTabControlIDB.Size = New System.Drawing.Size(1126, 547) Me.XtraTabControlIDB.TabIndex = 0 Me.XtraTabControlIDB.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPageIDB_Attributes_New, Me.XtraTabPageIDB_Attributes, Me.XtraTabPageIDB_SourceSQL}) ' @@ -554,7 +619,7 @@ Partial Class frmAdmin_Start ' Me.XtraTabPageIDB_Attributes_New.Controls.Add(Me.GridAttributes) Me.XtraTabPageIDB_Attributes_New.Name = "XtraTabPageIDB_Attributes_New" - Me.XtraTabPageIDB_Attributes_New.Size = New System.Drawing.Size(1124, 519) + Me.XtraTabPageIDB_Attributes_New.Size = New System.Drawing.Size(1124, 524) Me.XtraTabPageIDB_Attributes_New.Text = "Attribute" ' 'GridAttributes @@ -564,15 +629,20 @@ Partial Class frmAdmin_Start Me.GridAttributes.MainView = Me.ViewAttributes Me.GridAttributes.MenuManager = Me.RibbonControl1 Me.GridAttributes.Name = "GridAttributes" - Me.GridAttributes.Size = New System.Drawing.Size(1124, 519) + Me.GridAttributes.Size = New System.Drawing.Size(1124, 524) Me.GridAttributes.TabIndex = 0 - Me.GridAttributes.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.ViewAttributes}) + Me.GridAttributes.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.ViewAttributes, Me.GridView2}) ' 'ViewAttributes ' Me.ViewAttributes.GridControl = Me.GridAttributes Me.ViewAttributes.Name = "ViewAttributes" ' + 'GridView2 + ' + Me.GridView2.GridControl = Me.GridAttributes + Me.GridView2.Name = "GridView2" + ' 'XtraTabPageIDB_Attributes ' Me.XtraTabPageIDB_Attributes.AutoScroll = True @@ -598,7 +668,7 @@ Partial Class frmAdmin_Start Me.XtraTabPageIDB_Attributes.Controls.Add(CHANGED_WHENLabel) Me.XtraTabPageIDB_Attributes.Controls.Add(Me.CHANGED_WHENTextBox) Me.XtraTabPageIDB_Attributes.Name = "XtraTabPageIDB_Attributes" - Me.XtraTabPageIDB_Attributes.Size = New System.Drawing.Size(1124, 519) + Me.XtraTabPageIDB_Attributes.Size = New System.Drawing.Size(1124, 524) Me.XtraTabPageIDB_Attributes.Text = "Attributverwaltung" ' 'ComboBox1 @@ -617,7 +687,7 @@ Partial Class frmAdmin_Start Me.GridControl1.MainView = Me.GridView1 Me.GridControl1.MenuManager = Me.RibbonControl1 Me.GridControl1.Name = "GridControl1" - Me.GridControl1.Size = New System.Drawing.Size(282, 519) + Me.GridControl1.Size = New System.Drawing.Size(282, 524) Me.GridControl1.TabIndex = 28 Me.GridControl1.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.GridView1}) ' @@ -663,7 +733,7 @@ Partial Class frmAdmin_Start Me.GUIDTextBox.Location = New System.Drawing.Point(300, 28) Me.GUIDTextBox.Name = "GUIDTextBox" Me.GUIDTextBox.ReadOnly = True - Me.GUIDTextBox.Size = New System.Drawing.Size(33, 21) + Me.GUIDTextBox.Size = New System.Drawing.Size(33, 22) Me.GUIDTextBox.TabIndex = 1 ' 'TITLETextBox @@ -671,7 +741,7 @@ Partial Class frmAdmin_Start Me.TITLETextBox.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.TBIDB_ATTRIBUTEBindingSource, "TITLE", True)) Me.TITLETextBox.Location = New System.Drawing.Point(354, 28) Me.TITLETextBox.Name = "TITLETextBox" - Me.TITLETextBox.Size = New System.Drawing.Size(290, 21) + Me.TITLETextBox.Size = New System.Drawing.Size(290, 22) Me.TITLETextBox.TabIndex = 3 ' 'TYP_IDTextBox @@ -679,7 +749,7 @@ Partial Class frmAdmin_Start Me.TYP_IDTextBox.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.TBIDB_ATTRIBUTEBindingSource, "TYP_ID", True)) Me.TYP_IDTextBox.Location = New System.Drawing.Point(777, 28) Me.TYP_IDTextBox.Name = "TYP_IDTextBox" - Me.TYP_IDTextBox.Size = New System.Drawing.Size(104, 21) + Me.TYP_IDTextBox.Size = New System.Drawing.Size(104, 22) Me.TYP_IDTextBox.TabIndex = 5 ' 'MULTI_CONTEXTCheckBox @@ -697,7 +767,7 @@ Partial Class frmAdmin_Start Me.VIEW_SEQUENCETextBox.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.TBIDB_ATTRIBUTEBindingSource, "VIEW_SEQUENCE", True)) Me.VIEW_SEQUENCETextBox.Location = New System.Drawing.Point(450, 79) Me.VIEW_SEQUENCETextBox.Name = "VIEW_SEQUENCETextBox" - Me.VIEW_SEQUENCETextBox.Size = New System.Drawing.Size(33, 21) + Me.VIEW_SEQUENCETextBox.Size = New System.Drawing.Size(33, 22) Me.VIEW_SEQUENCETextBox.TabIndex = 9 ' 'VIEW_VISIBLECheckBox @@ -715,7 +785,7 @@ Partial Class frmAdmin_Start Me.COMMENTTextBox.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.TBIDB_ATTRIBUTEBindingSource, "COMMENT", True)) Me.COMMENTTextBox.Location = New System.Drawing.Point(354, 122) Me.COMMENTTextBox.Name = "COMMENTTextBox" - Me.COMMENTTextBox.Size = New System.Drawing.Size(417, 21) + Me.COMMENTTextBox.Size = New System.Drawing.Size(417, 22) Me.COMMENTTextBox.TabIndex = 13 ' 'ADDED_WHOTextBox @@ -724,7 +794,7 @@ Partial Class frmAdmin_Start Me.ADDED_WHOTextBox.Location = New System.Drawing.Point(354, 164) Me.ADDED_WHOTextBox.Name = "ADDED_WHOTextBox" Me.ADDED_WHOTextBox.ReadOnly = True - Me.ADDED_WHOTextBox.Size = New System.Drawing.Size(104, 21) + Me.ADDED_WHOTextBox.Size = New System.Drawing.Size(104, 22) Me.ADDED_WHOTextBox.TabIndex = 15 ' 'ADDED_WHENTextBox @@ -733,7 +803,7 @@ Partial Class frmAdmin_Start Me.ADDED_WHENTextBox.Location = New System.Drawing.Point(475, 164) Me.ADDED_WHENTextBox.Name = "ADDED_WHENTextBox" Me.ADDED_WHENTextBox.ReadOnly = True - Me.ADDED_WHENTextBox.Size = New System.Drawing.Size(131, 21) + Me.ADDED_WHENTextBox.Size = New System.Drawing.Size(131, 22) Me.ADDED_WHENTextBox.TabIndex = 17 ' 'CHANGED_WHOTextBox @@ -742,7 +812,7 @@ Partial Class frmAdmin_Start Me.CHANGED_WHOTextBox.Location = New System.Drawing.Point(354, 204) Me.CHANGED_WHOTextBox.Name = "CHANGED_WHOTextBox" Me.CHANGED_WHOTextBox.ReadOnly = True - Me.CHANGED_WHOTextBox.Size = New System.Drawing.Size(104, 21) + Me.CHANGED_WHOTextBox.Size = New System.Drawing.Size(104, 22) Me.CHANGED_WHOTextBox.TabIndex = 19 ' 'CHANGED_WHENTextBox @@ -751,14 +821,14 @@ Partial Class frmAdmin_Start Me.CHANGED_WHENTextBox.Location = New System.Drawing.Point(475, 204) Me.CHANGED_WHENTextBox.Name = "CHANGED_WHENTextBox" Me.CHANGED_WHENTextBox.ReadOnly = True - Me.CHANGED_WHENTextBox.Size = New System.Drawing.Size(131, 21) + Me.CHANGED_WHENTextBox.Size = New System.Drawing.Size(131, 22) Me.CHANGED_WHENTextBox.TabIndex = 21 ' 'XtraTabPageIDB_SourceSQL ' Me.XtraTabPageIDB_SourceSQL.Controls.Add(Me.GridSourceSQL) Me.XtraTabPageIDB_SourceSQL.Name = "XtraTabPageIDB_SourceSQL" - Me.XtraTabPageIDB_SourceSQL.Size = New System.Drawing.Size(1124, 519) + Me.XtraTabPageIDB_SourceSQL.Size = New System.Drawing.Size(1124, 524) Me.XtraTabPageIDB_SourceSQL.Text = "Source SQL" ' 'GridSourceSQL @@ -768,7 +838,7 @@ Partial Class frmAdmin_Start Me.GridSourceSQL.MainView = Me.ViewSourceSQL Me.GridSourceSQL.MenuManager = Me.RibbonControl1 Me.GridSourceSQL.Name = "GridSourceSQL" - Me.GridSourceSQL.Size = New System.Drawing.Size(1124, 519) + Me.GridSourceSQL.Size = New System.Drawing.Size(1124, 524) Me.GridSourceSQL.TabIndex = 0 Me.GridSourceSQL.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.ViewSourceSQL}) ' @@ -779,66 +849,127 @@ Partial Class frmAdmin_Start ' 'XtraTabPage_GlobalIndexer ' + Me.XtraTabPage_GlobalIndexer.Controls.Add(Me.TreeList2) Me.XtraTabPage_GlobalIndexer.Name = "XtraTabPage_GlobalIndexer" Me.XtraTabPage_GlobalIndexer.PageVisible = False - Me.XtraTabPage_GlobalIndexer.Size = New System.Drawing.Size(1126, 544) + Me.XtraTabPage_GlobalIndexer.Size = New System.Drawing.Size(1126, 547) Me.XtraTabPage_GlobalIndexer.Text = "Global Indexer" ' + 'TreeList2 + ' + Me.TreeList2.Dock = System.Windows.Forms.DockStyle.Fill + Me.TreeList2.Location = New System.Drawing.Point(0, 0) + Me.TreeList2.MenuManager = Me.RibbonControl1 + Me.TreeList2.Name = "TreeList2" + Me.TreeList2.PreviewFieldName = "Title" + Me.TreeList2.Size = New System.Drawing.Size(1126, 547) + Me.TreeList2.StateImageList = Me.GLOBIXImages + Me.TreeList2.TabIndex = 0 + ' + 'GLOBIXImages + ' + Me.GLOBIXImages.Add("bo_document", "image://svgimages/business objects/bo_document.svg") + Me.GLOBIXImages.Add("calculatenow", "image://svgimages/spreadsheet/calculatenow.svg") + Me.GLOBIXImages.Add("calculationoptions", "image://svgimages/spreadsheet/calculationoptions.svg") + ' 'XtraTabPage_ClipboardWatcher ' Me.XtraTabPage_ClipboardWatcher.Controls.Add(Me.XtraTabControl1) Me.XtraTabPage_ClipboardWatcher.Name = "XtraTabPage_ClipboardWatcher" Me.XtraTabPage_ClipboardWatcher.PageVisible = False - Me.XtraTabPage_ClipboardWatcher.Size = New System.Drawing.Size(1126, 544) + Me.XtraTabPage_ClipboardWatcher.Size = New System.Drawing.Size(1126, 547) Me.XtraTabPage_ClipboardWatcher.Text = "Clipboard Watcher" ' 'XtraTabControl1 ' - Me.XtraTabControl1.Dock = System.Windows.Forms.DockStyle.Fill Me.XtraTabControl1.Location = New System.Drawing.Point(0, 0) Me.XtraTabControl1.Name = "XtraTabControl1" Me.XtraTabControl1.SelectedTabPage = Me.XtraTabPageCWProfiles - Me.XtraTabControl1.Size = New System.Drawing.Size(1126, 544) + Me.XtraTabControl1.Size = New System.Drawing.Size(1126, 547) Me.XtraTabControl1.TabIndex = 0 Me.XtraTabControl1.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPageCWProfiles, Me.XtraTabPage2}) ' 'XtraTabPageCWProfiles ' + Me.XtraTabPageCWProfiles.Controls.Add(Me.TreeList1) Me.XtraTabPageCWProfiles.Controls.Add(Me.GridCWProfiles) Me.XtraTabPageCWProfiles.Name = "XtraTabPageCWProfiles" - Me.XtraTabPageCWProfiles.Size = New System.Drawing.Size(1124, 519) + Me.XtraTabPageCWProfiles.Size = New System.Drawing.Size(1124, 524) Me.XtraTabPageCWProfiles.Text = "Profile" ' - 'GridCWProfiles + 'TreeList1 ' - Me.GridCWProfiles.Dock = System.Windows.Forms.DockStyle.Fill - Me.GridCWProfiles.Location = New System.Drawing.Point(0, 0) - Me.GridCWProfiles.MainView = Me.ViewCWProfiles - Me.GridCWProfiles.MenuManager = Me.RibbonControl1 - Me.GridCWProfiles.Name = "GridCWProfiles" - Me.GridCWProfiles.Size = New System.Drawing.Size(1124, 519) - Me.GridCWProfiles.TabIndex = 0 - Me.GridCWProfiles.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.ViewCWProfiles}) + Me.TreeList1.Columns.AddRange(New DevExpress.XtraTreeList.Columns.TreeListColumn() {Me.COL_ENTITY, Me.COL_ENITY_SCOPE, Me.COL_PARENT, Me.COL_GUID, Me.COL_NODE_TITLE}) + Me.TreeList1.KeyFieldName = "" + Me.TreeList1.Location = New System.Drawing.Point(4, 3) + Me.TreeList1.MenuManager = Me.RibbonControl1 + Me.TreeList1.Name = "TreeList1" + Me.TreeList1.OptionsView.ShowIndentAsRowStyle = True + Me.TreeList1.ParentFieldName = "" + Me.TreeList1.Size = New System.Drawing.Size(809, 504) + Me.TreeList1.StateImageList = Me.CWImages + Me.TreeList1.TabIndex = 2 + ' + 'COL_ENTITY + ' + Me.COL_ENTITY.Caption = "Entität" + Me.COL_ENTITY.FieldName = "Entity" + Me.COL_ENTITY.Name = "COL_ENTITY" + Me.COL_ENTITY.Visible = True + Me.COL_ENTITY.VisibleIndex = 1 ' - 'ViewCWProfiles + 'COL_ENITY_SCOPE ' - Me.ViewCWProfiles.GridControl = Me.GridCWProfiles - Me.ViewCWProfiles.Name = "ViewCWProfiles" + Me.COL_ENITY_SCOPE.Caption = "Scope" + Me.COL_ENITY_SCOPE.FieldName = "Scope" + Me.COL_ENITY_SCOPE.Name = "COL_ENITY_SCOPE" + Me.COL_ENITY_SCOPE.Visible = True + Me.COL_ENITY_SCOPE.VisibleIndex = 2 + ' + 'COL_PARENT + ' + Me.COL_PARENT.Caption = "ParentId" + Me.COL_PARENT.FieldName = "ParentId" + Me.COL_PARENT.Name = "COL_PARENT" + Me.COL_PARENT.Visible = True + Me.COL_PARENT.VisibleIndex = 3 + ' + 'COL_GUID + ' + Me.COL_GUID.Caption = "Guid" + Me.COL_GUID.FieldName = "Guid" + Me.COL_GUID.Name = "COL_GUID" + Me.COL_GUID.Visible = True + Me.COL_GUID.VisibleIndex = 4 + ' + 'COL_NODE_TITLE + ' + Me.COL_NODE_TITLE.Caption = "Titel" + Me.COL_NODE_TITLE.FieldName = "Title" + Me.COL_NODE_TITLE.Name = "COL_NODE_TITLE" + Me.COL_NODE_TITLE.Visible = True + Me.COL_NODE_TITLE.VisibleIndex = 0 + ' + 'CWImages + ' + Me.CWImages.Add("detailed", "image://svgimages/outlook inspired/detailed.svg") + Me.CWImages.Add("newtablestyle", "image://svgimages/actions/newtablestyle.svg") + Me.CWImages.Add("bo_appointment", "image://svgimages/business objects/bo_appointment.svg") ' 'XtraTabPage2 ' Me.XtraTabPage2.Name = "XtraTabPage2" - Me.XtraTabPage2.Size = New System.Drawing.Size(1124, 519) + Me.XtraTabPage2.Size = New System.Drawing.Size(1124, 524) Me.XtraTabPage2.Text = "XtraTabPage2" ' 'XtraTabControl ' Me.XtraTabControl.Dock = System.Windows.Forms.DockStyle.Fill - Me.XtraTabControl.Location = New System.Drawing.Point(200, 158) + Me.XtraTabControl.Location = New System.Drawing.Point(200, 159) Me.XtraTabControl.Name = "XtraTabControl" Me.XtraTabControl.SelectedTabPage = Me.XtraTabPage_IDB Me.XtraTabControl.ShowTabHeader = DevExpress.Utils.DefaultBoolean.[True] - Me.XtraTabControl.Size = New System.Drawing.Size(1128, 569) + Me.XtraTabControl.Size = New System.Drawing.Size(1128, 570) Me.XtraTabControl.TabIndex = 4 Me.XtraTabControl.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPage_ClipboardWatcher, Me.XtraTabPage_GlobalIndexer, Me.XtraTabPage_IDB}) ' @@ -856,9 +987,14 @@ Partial Class frmAdmin_Start Me.Ribbon = Me.RibbonControl1 Me.StatusBar = Me.RibbonStatusBar1 Me.Text = "Administration" + CType(Me.ViewCWProcesses, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.GridCWProfiles, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.WinExplorerView1, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.RibbonControl1, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.ViewCWWindows, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.ViewCWControls, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.TreeListMenu, System.ComponentModel.ISupportInitialize).EndInit() - CType(Me.SvgImageCollection1, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.MainTreeImages, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.DockManager1, System.ComponentModel.ISupportInitialize).EndInit() Me.DockPanel1.ResumeLayout(False) Me.DockPanel1_Container.ResumeLayout(False) @@ -871,6 +1007,7 @@ Partial Class frmAdmin_Start Me.XtraTabPageIDB_Attributes_New.ResumeLayout(False) CType(Me.GridAttributes, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.ViewAttributes, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.GridView2, System.ComponentModel.ISupportInitialize).EndInit() Me.XtraTabPageIDB_Attributes.ResumeLayout(False) Me.XtraTabPageIDB_Attributes.PerformLayout() CType(Me.GridControl1, System.ComponentModel.ISupportInitialize).EndInit() @@ -878,12 +1015,15 @@ Partial Class frmAdmin_Start Me.XtraTabPageIDB_SourceSQL.ResumeLayout(False) CType(Me.GridSourceSQL, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.ViewSourceSQL, System.ComponentModel.ISupportInitialize).EndInit() + Me.XtraTabPage_GlobalIndexer.ResumeLayout(False) + CType(Me.TreeList2, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.GLOBIXImages, System.ComponentModel.ISupportInitialize).EndInit() Me.XtraTabPage_ClipboardWatcher.ResumeLayout(False) CType(Me.XtraTabControl1, System.ComponentModel.ISupportInitialize).EndInit() Me.XtraTabControl1.ResumeLayout(False) Me.XtraTabPageCWProfiles.ResumeLayout(False) - CType(Me.GridCWProfiles, System.ComponentModel.ISupportInitialize).EndInit() - CType(Me.ViewCWProfiles, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.TreeList1, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.CWImages, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.XtraTabControl, System.ComponentModel.ISupportInitialize).EndInit() Me.XtraTabControl.ResumeLayout(False) Me.ResumeLayout(False) @@ -899,7 +1039,7 @@ Partial Class frmAdmin_Start Friend WithEvents RibbonPage2 As DevExpress.XtraBars.Ribbon.RibbonPage Friend WithEvents TreeListMenu As DevExpress.XtraTreeList.TreeList Friend WithEvents TreeListColumn1 As DevExpress.XtraTreeList.Columns.TreeListColumn - Friend WithEvents SvgImageCollection1 As DevExpress.Utils.SvgImageCollection + Friend WithEvents MainTreeImages As DevExpress.Utils.SvgImageCollection Friend WithEvents RibbonGroup_ClipboardWatcher_DataSearch As DevExpress.XtraBars.Ribbon.RibbonPageGroup Friend WithEvents RibbonGroup_ClipboardWatcher_Process As DevExpress.XtraBars.Ribbon.RibbonPageGroup Friend WithEvents RibbonGroup_ClipboardWatcher_Window As DevExpress.XtraBars.Ribbon.RibbonPageGroup @@ -968,5 +1108,18 @@ Partial Class frmAdmin_Start Friend WithEvents XtraTabPageCWProfiles As DevExpress.XtraTab.XtraTabPage Friend WithEvents XtraTabPage2 As DevExpress.XtraTab.XtraTabPage Friend WithEvents GridCWProfiles As GridControl - Friend WithEvents ViewCWProfiles As GridView + Friend WithEvents GridView2 As GridView + Friend WithEvents ViewCWProcesses As GridView + Friend WithEvents ViewCWWindows As GridView + Friend WithEvents ViewCWControls As GridView + Friend WithEvents TreeList1 As DevExpress.XtraTreeList.TreeList + Friend WithEvents WinExplorerView1 As Views.WinExplorer.WinExplorerView + Friend WithEvents COL_ENTITY As DevExpress.XtraTreeList.Columns.TreeListColumn + Friend WithEvents COL_ENITY_SCOPE As DevExpress.XtraTreeList.Columns.TreeListColumn + Friend WithEvents COL_PARENT As DevExpress.XtraTreeList.Columns.TreeListColumn + Friend WithEvents COL_GUID As DevExpress.XtraTreeList.Columns.TreeListColumn + Friend WithEvents COL_NODE_TITLE As DevExpress.XtraTreeList.Columns.TreeListColumn + Friend WithEvents CWImages As DevExpress.Utils.SvgImageCollection + Friend WithEvents TreeList2 As DevExpress.XtraTreeList.TreeList + Friend WithEvents GLOBIXImages As DevExpress.Utils.SvgImageCollection End Class diff --git a/GUIs.ZooFlow/Administration/frmAdmin_Start.resx b/GUIs.ZooFlow/Administration/frmAdmin_Start.resx index d72b3efc..ce7d4407 100644 --- a/GUIs.ZooFlow/Administration/frmAdmin_Start.resx +++ b/GUIs.ZooFlow/Administration/frmAdmin_Start.resx @@ -291,17 +291,23 @@ bGFzcz0iR3JlZW4iIC8+DQogIDwvZz4NCjwvc3ZnPgs= - - 22, 21 + + 122, 17 - 188, 21 + 396, 17 - 483, 21 + 691, 17 - 323, 21 + 531, 17 + + + 17, 17 + + + 264, 17 @@ -327,15 +333,15 @@ - 711, 21 + 919, 17 - 933, 21 + 1141, 17 - 1106, 21 + 17, 56 - 1366, 21 + 277, 56 \ No newline at end of file diff --git a/GUIs.ZooFlow/Administration/frmAdmin_Start.vb b/GUIs.ZooFlow/Administration/frmAdmin_Start.vb index f09cfc15..2627a2cc 100644 --- a/GUIs.ZooFlow/Administration/frmAdmin_Start.vb +++ b/GUIs.ZooFlow/Administration/frmAdmin_Start.vb @@ -1,10 +1,11 @@ Imports DevExpress.Utils -Imports DevExpress.XtraBars.Docking2010.Views Imports DevExpress.XtraBars.Ribbon Imports DevExpress.XtraGrid Imports DevExpress.XtraGrid.Views.Grid Imports DevExpress.XtraGrid.Views.Grid.ViewInfo Imports DevExpress.XtraTab +Imports DevExpress.XtraTreeList +Imports DevExpress.XtraTreeList.Nodes Imports DigitalData.Modules.Logging Public Class frmAdmin_Start @@ -18,14 +19,17 @@ Public Class frmAdmin_Start Private Const CW_PROFILES = "CW_PROFILES" Private PrimaryKey As String = Nothing - Private SourceCommands As New Dictionary(Of String, SourceSql) + Private AdminItems As New List(Of AdminItem) Private CurrentPage As String - Private Class SourceSql - Public Title As String - Public SQL As String - Public PrimaryKey As String + Private Class AdminItem + Public Property Guid As Integer + Public Property ParentId As Integer + Public Property Title As String + Public Property Entity As String + Public Property Scope As String + Public Property Summary As String End Class Private Sub frmAdministration_Load(sender As Object, e As EventArgs) Handles MyBase.Load @@ -39,17 +43,20 @@ Public Class frmAdmin_Start Private Function Load_SQLData() As Boolean Try - Dim oTable As DataTable = My.Database.GetDatatable("SELECT * FROM TBZF_ADMIN_SOURCE_SQL") - SourceCommands.Clear() + Dim oTable As DataTable = My.Database.GetDatatable("SELECT * FROM VWIDB_ADMINISTRATION_TREEVIEW") + AdminItems.Clear() For Each oRow As DataRow In oTable.Rows - Dim oSource As New SourceSql With { - .PrimaryKey = oRow.Item("PK_COLUMN").ToString, - .SQL = oRow.Item("SQL_COMMAND").ToString, - .Title = oRow.Item("ENTITY_TITLE").ToString + Dim oItem As New AdminItem With { + .Guid = oRow.Item("GUID"), + .ParentId = oRow.Item("PARENT"), + .Entity = oRow.Item("ENTITY").ToString, + .Scope = oRow.Item("ENTITY_SCOPE").ToString, + .Title = oRow.Item("NODE_TITLE").ToString, + .Summary = oRow.Item("SUMMARY").ToString } - SourceCommands.Add(oRow.Item("ENTITY_TITLE").ToString, oSource) + AdminItems.Add(oItem) Next Return True Catch ex As Exception @@ -96,11 +103,6 @@ Public Class frmAdmin_Start CurrentPage = e.Node.Tag.ToString - Dim oSource As SourceSql - If SourceCommands.ContainsKey(CurrentPage) Then - oSource = SourceCommands.Item(CurrentPage) - End If - Select Case e.Node.Tag.ToString Case IDB_START Display_Tab(XtraTabPage_IDB) @@ -109,8 +111,8 @@ Public Class frmAdmin_Start Display_Tab(XtraTabPage_IDB) Display_Tab(XtraTabPageIDB_Attributes_New) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridAttributes) + 'Dim oTable As DataTable = My.Database.GetDatatable(oSource.Title) + 'Load_Grid(oTable, oSource, GridAttributes) Case IDB_BUSINESS_ENTITY 'DisplayTab(XtraTabPage_Entities) @@ -119,20 +121,27 @@ Public Class frmAdmin_Start Display_Tab(XtraTabPage_GlobalIndexer) Display_RibbonPage(RibbonPage_GlobalIndexer) + Dim oCWItems As List(Of AdminItem) = (From Item As AdminItem In AdminItems + Where Item.Entity = "GLOBIX" + Select Item).ToList() + Load_Tree(oCWItems, TreeList2) + Case CW_PROFILES Display_Tab(XtraTabPage_ClipboardWatcher) Display_Tab(XtraTabPageCWProfiles) Display_RibbonPage(RibbonPage_ClipboardWatcher) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridCWProfiles) + Dim oCWItems As List(Of AdminItem) = (From Item As AdminItem In AdminItems + Where Item.Entity = "CW" + Select Item).ToList() + Load_Tree(oCWItems, TreeList1) Case IDB_SOURCE_SQL Display_Tab(XtraTabPage_IDB) Display_Tab(XtraTabPageIDB_SourceSQL) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridSourceSQL) + 'Dim oTable As DataTable = My.Database.GetDatatable(oSource.Title) + 'Load_Grid(oTable, oSource, GridSourceSQL) End Select Catch ex As Exception @@ -141,61 +150,98 @@ Public Class frmAdmin_Start End Sub - Private Sub Load_Grid(DataSource As DataTable, PrimaryKey As String, GridControl As GridControl) + 'Private Sub Load_Children(Source As AdminItem, DataSet As DataSet, DataTable As DataTable) + ' Dim oChildren = AdminItems.Where(Function(cmd) cmd.Value.ParentId = Source.Guid).ToList() + + ' If oChildren.Count > 0 Then + ' For Each oChild In oChildren + ' Dim oChildSource As AdminItem = oChild.Value + ' Dim oChildTable As DataTable = My.Database.GetDatatable(oChildSource.Title) + ' oChildTable.TableName = oChildSource.Title + ' Dim oRelationName As String = $"{Source.Title}__{oChildSource.Title}" + + ' DataSet.Tables.Add(oChildTable) + ' DataSet.Relations.Add(New DataRelation(oRelationName, + ' DataTable.Columns.Item(Source.Entity), + ' oChildTable.Columns.Item(oChildSource.Scope))) + + ' Load_Children(oChildSource, DataSet, oChildTable) + ' Next + ' End If + 'End Sub + + Private Sub Load_Tree(Source As List(Of AdminItem), TreeList As TreeList) + TreeList.HierarchyFieldName = "Title" + TreeList.KeyFieldName = "Guid" + TreeList.ParentFieldName = "ParentId" + 'TreeList.PreviewFieldName = "Summary" + 'TreeList.PreviewLineCount = 3 + 'TreeList.OptionsView.ShowPreview = True + TreeList.DataSource = Source + TreeList.ForceInitialize() + End Sub + + Private Sub Load_Grid(DataSource As DataTable, Source As AdminItem, GridControl As GridControl) Try - Me.PrimaryKey = PrimaryKey - - GridControl.DataSource = DataSource - GridControl.ForceInitialize() - - Dim oGridView = DirectCast(GridControl.DefaultView, GridView) - - With oGridView.Appearance.EvenRow - .BackColor = Color.Gainsboro - .Options.UseBackColor = True - End With - - With oGridView.Appearance.FocusedCell - .BackColor = Color.Gold - .Options.UseBackColor = True - End With - - With oGridView.Appearance.FocusedRow - .BackColor = Color.Gold - .Options.UseBackColor = True - End With - - With oGridView.OptionsBehavior - .Editable = False - .ReadOnly = True - End With - - With oGridView.OptionsClipboard - .CopyColumnHeaders = DefaultBoolean.False - End With - - With oGridView.OptionsFind - .AlwaysVisible = True - End With - - With oGridView.OptionsView - .ShowAutoFilterRow = True - .EnableAppearanceEvenRow = True - .ShowIndicator = False - End With - - AddHandler oGridView.KeyDown, Sub(sender As Object, e As KeyEventArgs) - Dim oView As GridView = DirectCast(sender, GridView) - If e.Control AndAlso e.KeyCode = Keys.C And e.Modifiers = Keys.Control Then - Dim oCellValue = oView.GetRowCellValue(oView.FocusedRowHandle, oView.FocusedColumn) - If oCellValue IsNot Nothing AndAlso oCellValue.ToString() <> String.Empty Then - Clipboard.SetText(oCellValue.ToString) - End If - e.Handled = True - End If - End Sub - - oGridView.BestFitColumns() + PrimaryKey = Source.Entity + + Dim oDataSet As New DataSet() + DataSource.TableName = Source.Title + oDataSet.Tables.Add(DataSource) + + 'Load_Children(Source, oDataSet, DataSource) + + 'GridControl.DataSource = oDataSet.Tables.Item(Source.Title) + 'GridControl.ForceInitialize() + + 'Dim oGridView = DirectCast(GridControl.DefaultView, GridView) + + 'With oGridView.Appearance.EvenRow + ' .BackColor = Color.Gainsboro + ' .Options.UseBackColor = True + 'End With + + 'With oGridView.Appearance.FocusedCell + ' .BackColor = Color.Gold + ' .Options.UseBackColor = True + 'End With + + 'With oGridView.Appearance.FocusedRow + ' .BackColor = Color.Gold + ' .Options.UseBackColor = True + 'End With + + 'With oGridView.OptionsBehavior + ' .Editable = False + ' .ReadOnly = True + 'End With + + 'With oGridView.OptionsClipboard + ' .CopyColumnHeaders = DefaultBoolean.False + 'End With + + 'With oGridView.OptionsFind + ' .AlwaysVisible = True + 'End With + + 'With oGridView.OptionsView + ' .ShowAutoFilterRow = True + ' .EnableAppearanceEvenRow = True + ' .ShowIndicator = False + 'End With + + 'AddHandler oGridView.KeyDown, Sub(sender As Object, e As KeyEventArgs) + ' Dim oView As GridView = DirectCast(sender, GridView) + ' If e.Control AndAlso e.KeyCode = Keys.C And e.Modifiers = Keys.Control Then + ' Dim oCellValue = oView.GetRowCellValue(oView.FocusedRowHandle, oView.FocusedColumn) + ' If oCellValue IsNot Nothing AndAlso oCellValue.ToString() <> String.Empty Then + ' Clipboard.SetText(oCellValue.ToString) + ' End If + ' e.Handled = True + ' End If + ' End Sub + + 'oGridView.BestFitColumns() Catch ex As Exception ShowError(ex) @@ -203,7 +249,7 @@ Public Class frmAdmin_Start End Sub Private Sub View_DoubleClick(sender As Object, e As EventArgs) Handles _ - ViewAttributes.DoubleClick, ViewSourceSQL.DoubleClick, ViewCWProfiles.DoubleClick + ViewAttributes.DoubleClick, ViewSourceSQL.DoubleClick Dim oView As GridView = TryCast(sender, GridView) Dim hitInfo As GridHitInfo = oView.CalcHitInfo(TryCast(e, DXMouseEventArgs).Location) If hitInfo.InDataRow Then @@ -219,7 +265,7 @@ Public Class frmAdmin_Start Case ViewSourceSQL.Name Load_SourceSql(oPrimaryKey) - Case ViewCWProfiles.Name + Case WinExplorerView1.Name Load_CWProfile(oPrimaryKey) End Select @@ -237,9 +283,9 @@ Public Class frmAdmin_Start oForm.ShowDialog() If oForm.HasChanges Then - Dim oSource As SourceSql = SourceCommands.Item(CurrentPage) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridAttributes) + Dim oSource As AdminItem = AdminItems.Item(CurrentPage) + Dim oTable As DataTable = My.Database.GetDatatable(oSource.Title) + Load_Grid(oTable, oSource, GridAttributes) End If Catch ex As Exception ShowError(ex) @@ -252,9 +298,9 @@ Public Class frmAdmin_Start oForm.ShowDialog() If oForm.HasChanges Then - Dim oSource As SourceSql = SourceCommands.Item(CurrentPage) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridSourceSQL) + Dim oSource As AdminItem = AdminItems.Item(CurrentPage) + Dim oTable As DataTable = My.Database.GetDatatable(oSource.Title) + Load_Grid(oTable, oSource, GridSourceSQL) End If Catch ex As Exception ShowError(ex) @@ -267,9 +313,9 @@ Public Class frmAdmin_Start oForm.ShowDialog() If oForm.HasChanges Then - Dim oSource As SourceSql = SourceCommands.Item(CurrentPage) - Dim oTable As DataTable = My.Database.GetDatatable(oSource.SQL) - Load_Grid(oTable, oSource.PrimaryKey, GridCWProfiles) + Dim oSource As AdminItem = AdminItems.Item(CurrentPage) + Dim oTable As DataTable = My.Database.GetDatatable(oSource.Title) + 'Load_Tree(oTable, oSource, TreeList1) End If Catch ex As Exception ShowError(ex) @@ -301,4 +347,42 @@ Public Class frmAdmin_Start Private Sub ResetStatus() labelStatus.Visibility = DevExpress.XtraBars.BarItemVisibility.Never End Sub + + Private Sub TreeList1_GetStateImage(sender As Object, e As GetStateImageEventArgs) Handles TreeList1.GetStateImage + Dim oTreeList As TreeList = DirectCast(sender, TreeList) + Dim oItem As AdminItem = oTreeList.GetRow(e.Node.Id) + + Select Case oItem.Scope + Case "PROFILE" + e.NodeImageIndex = 0 + + Case "PROCESS" + e.NodeImageIndex = 1 + + Case "WINDOW" + e.NodeImageIndex = 2 + + Case "CONTROL" + e.NodeImageIndex = 3 + End Select + + End Sub + + Private Sub TreeList2_GetStateImage(sender As Object, e As GetStateImageEventArgs) Handles TreeList2.GetStateImage + Dim oTreeList As TreeList = DirectCast(sender, TreeList) + Dim oItem As AdminItem = oTreeList.GetRow(e.Node.Id) + + Select Case oItem.Scope + Case "PROFILE" + e.NodeImageIndex = 0 + + Case "INDEX_MAN" + e.NodeImageIndex = 1 + + Case "INDEX_AUTO" + e.NodeImageIndex = 2 + + End Select + + End Sub End Class \ No newline at end of file