Load Dynamic Form for frmEdit, Save Application Skin, add UIConfig

This commit is contained in:
Jonathan Jenne
2019-02-21 16:53:27 +01:00
parent 08e3ca9dd3
commit 72788c84bd
18 changed files with 366 additions and 94 deletions

View File

@@ -1,6 +1,7 @@
Imports DevExpress.XtraGrid
Imports DevExpress.XtraGrid.Views.Base
Imports DevExpress.XtraGrid.Views.Grid
Imports DigitalData.GUIs.ClientSuite.ClassLayout
Public Class UserControlAssignment
Private _DragDropManager As ClassDragDrop
@@ -41,6 +42,22 @@ Public Class UserControlAssignment
GridAssignedToParent = ClassUIUtils.ConfigureGridControlDefaults(GridAssignedToParent, [ReadOnly]:=True)
ViewAssignedToParent.OptionsSelection.MultiSelectMode = GridMultiSelectMode.CheckBoxRowSelect
ViewAssignedToParent.OptionsSelection.MultiSelect = True
' Load view layouts
Dim ViewParentListPath = GetLayoutPath(GroupName.LayoutUserManager, Name, ViewParentList.Name)
Dim ViewAssignedPath = GetLayoutPath(GroupName.LayoutUserManager, Name, ViewAssignedToParent.Name)
Dim ViewNotAssignedPath = GetLayoutPath(GroupName.LayoutUserManager, Name, ViewNotAssignedToParent.Name)
If IO.File.Exists(ViewParentListPath) Then
ViewParentList.RestoreLayoutFromXml(ViewParentListPath)
End If
If IO.File.Exists(ViewAssignedPath) Then
ViewAssignedToParent.RestoreLayoutFromXml(ViewAssignedPath)
End If
If IO.File.Exists(ViewNotAssignedPath) Then
ViewNotAssignedToParent.RestoreLayoutFromXml(ViewNotAssignedPath)
End If
End Sub
Private Function MaybeCopyToDataTable(RowCollection As EnumerableRowCollection(Of DataRow)) As DataTable
@@ -174,4 +191,10 @@ Public Class UserControlAssignment
GridAssignedToParent.DataSource = MaybeCopyToDataTable(oAssignedChildren)
GridNotAssignedToParent.DataSource = MaybeCopyToDataTable(oNotAssignedChildren)
End Sub
Private Sub View_LayoutChanged(sender As Object, e As EventArgs) Handles ViewNotAssignedToParent.Layout, ViewAssignedToParent.Layout, ViewParentList.Layout
Dim oView As BaseView = sender
Dim oLayoutPath = GetLayoutPath(GroupName.LayoutUserManager, Name, oView.Name)
oView.SaveLayoutToXml(oLayoutPath)
End Sub
End Class