Common: ObjectPropertyDialog
This commit is contained in:
@@ -85,6 +85,8 @@ Public Class PropertyControls
|
||||
|
||||
End Select
|
||||
|
||||
oControl.Tag = pAttribute
|
||||
|
||||
Return oControl
|
||||
End Function
|
||||
End Class
|
||||
|
||||
@@ -32,6 +32,7 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.TabFormControl1 = New DevExpress.XtraBars.TabFormControl()
|
||||
Me.cmbBusinessEntity = New DevExpress.XtraBars.BarEditItem()
|
||||
Me.BarStaticItem1 = New DevExpress.XtraBars.BarStaticItem()
|
||||
Me.btnSave = New DevExpress.XtraBars.BarButtonItem()
|
||||
Me.TabPageAttributes = New DevExpress.XtraBars.TabFormPage()
|
||||
Me.TabFormContentContainer1 = New DevExpress.XtraBars.TabFormContentContainer()
|
||||
Me.LayoutControlAttributes = New DevExpress.XtraLayout.LayoutControl()
|
||||
@@ -39,6 +40,10 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.TabPageObject = New DevExpress.XtraBars.TabFormPage()
|
||||
Me.TabFormContentContainer2 = New DevExpress.XtraBars.TabFormContentContainer()
|
||||
Me.LayoutControlObject = New DevExpress.XtraLayout.LayoutControl()
|
||||
Me.GridObjectHistory = New DevExpress.XtraGrid.GridControl()
|
||||
Me.GridView1 = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.GridColumn6 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.GridColumn7 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.GroupControl1 = New DevExpress.XtraEditors.GroupControl()
|
||||
Me.progressLifecycle = New DevExpress.XtraEditors.ProgressBarControl()
|
||||
Me.lbLifecycleEnd = New DevExpress.XtraEditors.LabelControl()
|
||||
@@ -51,16 +56,18 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.txtChangedWho = New DevExpress.XtraEditors.TextEdit()
|
||||
Me.TextEdit1 = New DevExpress.XtraEditors.TextEdit()
|
||||
Me.LayoutObject = New DevExpress.XtraLayout.LayoutControlGroup()
|
||||
Me.LayoutControlItem1 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem2 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem3 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem4 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.SimpleSeparator1 = New DevExpress.XtraLayout.SimpleSeparator()
|
||||
Me.LayoutControlItem7 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlGroup1 = New DevExpress.XtraLayout.LayoutControlGroup()
|
||||
Me.LayoutControlItem8 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlGroup2 = New DevExpress.XtraLayout.LayoutControlGroup()
|
||||
Me.LayoutControlItem4 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem1 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem5 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem6 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem2 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.LayoutControlItem3 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.txtAccessedWho = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.EmptySpaceItem1 = New DevExpress.XtraLayout.EmptySpaceItem()
|
||||
Me.LayoutControlItem7 = New DevExpress.XtraLayout.LayoutControlItem()
|
||||
Me.TabPageHistory = New DevExpress.XtraBars.TabFormPage()
|
||||
Me.TabFormContentContainer4 = New DevExpress.XtraBars.TabFormContentContainer()
|
||||
Me.GridValueHistory = New DevExpress.XtraGrid.GridControl()
|
||||
@@ -79,6 +86,8 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.TabFormContentContainer2.SuspendLayout()
|
||||
CType(Me.LayoutControlObject, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.LayoutControlObject.SuspendLayout()
|
||||
CType(Me.GridObjectHistory, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.GridView1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.GroupControl1.SuspendLayout()
|
||||
CType(Me.progressLifecycle.Properties, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
@@ -90,16 +99,18 @@ Partial Class frmObjectPropertyDialog
|
||||
CType(Me.txtChangedWho.Properties, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.TextEdit1.Properties, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutObject, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem4, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.SimpleSeparator1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem7, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlGroup1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem8, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlGroup2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem4, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem5, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem6, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.txtAccessedWho, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.EmptySpaceItem1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.LayoutControlItem7, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.TabFormContentContainer4.SuspendLayout()
|
||||
CType(Me.GridValueHistory, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.ViewValueHistory, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
@@ -118,13 +129,13 @@ Partial Class frmObjectPropertyDialog
|
||||
'
|
||||
'TabFormControl1
|
||||
'
|
||||
Me.TabFormControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.cmbBusinessEntity, Me.BarStaticItem1})
|
||||
Me.TabFormControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.cmbBusinessEntity, Me.BarStaticItem1, Me.btnSave})
|
||||
Me.TabFormControl1.Location = New System.Drawing.Point(0, 0)
|
||||
Me.TabFormControl1.Name = "TabFormControl1"
|
||||
Me.TabFormControl1.Pages.Add(Me.TabPageAttributes)
|
||||
Me.TabFormControl1.Pages.Add(Me.TabPageObject)
|
||||
Me.TabFormControl1.Pages.Add(Me.TabPageHistory)
|
||||
Me.TabFormControl1.SelectedPage = Me.TabPageAttributes
|
||||
Me.TabFormControl1.SelectedPage = Me.TabPageObject
|
||||
Me.TabFormControl1.ShowAddPageButton = False
|
||||
Me.TabFormControl1.ShowTabCloseButtons = False
|
||||
Me.TabFormControl1.Size = New System.Drawing.Size(572, 71)
|
||||
@@ -133,6 +144,7 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.TabFormControl1.TabRightItemLinks.Add(Me.BarStaticItem1)
|
||||
Me.TabFormControl1.TabRightItemLinks.Add(Me.cmbBusinessEntity)
|
||||
Me.TabFormControl1.TabStop = False
|
||||
Me.TabFormControl1.TitleItemLinks.Add(Me.btnSave)
|
||||
'
|
||||
'cmbBusinessEntity
|
||||
'
|
||||
@@ -149,6 +161,13 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.BarStaticItem1.Name = "BarStaticItem1"
|
||||
Me.BarStaticItem1.Visibility = DevExpress.XtraBars.BarItemVisibility.OnlyInCustomizing
|
||||
'
|
||||
'btnSave
|
||||
'
|
||||
Me.btnSave.Caption = "BarButtonItem1"
|
||||
Me.btnSave.Id = 0
|
||||
Me.btnSave.ImageOptions.SvgImage = Global.DigitalData.GUIs.Common.My.Resources.Resources.save
|
||||
Me.btnSave.Name = "btnSave"
|
||||
'
|
||||
'TabPageAttributes
|
||||
'
|
||||
Me.TabPageAttributes.ContentContainer = Me.TabFormContentContainer1
|
||||
@@ -199,6 +218,7 @@ Partial Class frmObjectPropertyDialog
|
||||
'
|
||||
'LayoutControlObject
|
||||
'
|
||||
Me.LayoutControlObject.Controls.Add(Me.GridObjectHistory)
|
||||
Me.LayoutControlObject.Controls.Add(Me.GroupControl1)
|
||||
Me.LayoutControlObject.Controls.Add(Me.txtCreatedWhen)
|
||||
Me.LayoutControlObject.Controls.Add(Me.txtChangedWhen)
|
||||
@@ -215,14 +235,47 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.LayoutControlObject.TabIndex = 0
|
||||
Me.LayoutControlObject.Text = "LayoutControl1"
|
||||
'
|
||||
'GridObjectHistory
|
||||
'
|
||||
Me.GridObjectHistory.Location = New System.Drawing.Point(24, 211)
|
||||
Me.GridObjectHistory.MainView = Me.GridView1
|
||||
Me.GridObjectHistory.Name = "GridObjectHistory"
|
||||
Me.GridObjectHistory.Size = New System.Drawing.Size(524, 199)
|
||||
Me.GridObjectHistory.TabIndex = 11
|
||||
Me.GridObjectHistory.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.GridView1})
|
||||
'
|
||||
'GridView1
|
||||
'
|
||||
Me.GridView1.Columns.AddRange(New DevExpress.XtraGrid.Columns.GridColumn() {Me.GridColumn6, Me.GridColumn7})
|
||||
Me.GridView1.GridControl = Me.GridObjectHistory
|
||||
Me.GridView1.Name = "GridView1"
|
||||
'
|
||||
'GridColumn6
|
||||
'
|
||||
Me.GridColumn6.Caption = "Status"
|
||||
Me.GridColumn6.FieldName = "STATE_LANG"
|
||||
Me.GridColumn6.Name = "GridColumn6"
|
||||
Me.GridColumn6.Visible = True
|
||||
Me.GridColumn6.VisibleIndex = 0
|
||||
'
|
||||
'GridColumn7
|
||||
'
|
||||
Me.GridColumn7.Caption = "Datum "
|
||||
Me.GridColumn7.FieldName = "ADDED_WHEN"
|
||||
Me.GridColumn7.Name = "GridColumn7"
|
||||
Me.GridColumn7.Visible = True
|
||||
Me.GridColumn7.VisibleIndex = 1
|
||||
'
|
||||
'GroupControl1
|
||||
'
|
||||
Me.GroupControl1.Controls.Add(Me.progressLifecycle)
|
||||
Me.GroupControl1.Controls.Add(Me.lbLifecycleEnd)
|
||||
Me.GroupControl1.Controls.Add(Me.lbLifecycleStart)
|
||||
Me.GroupControl1.Location = New System.Drawing.Point(12, 428)
|
||||
Me.GroupControl1.Location = New System.Drawing.Point(12, 426)
|
||||
Me.GroupControl1.MaximumSize = New System.Drawing.Size(0, 96)
|
||||
Me.GroupControl1.MinimumSize = New System.Drawing.Size(0, 96)
|
||||
Me.GroupControl1.Name = "GroupControl1"
|
||||
Me.GroupControl1.Size = New System.Drawing.Size(548, 94)
|
||||
Me.GroupControl1.Size = New System.Drawing.Size(548, 96)
|
||||
Me.GroupControl1.TabIndex = 2
|
||||
Me.GroupControl1.Text = "Lebenszyklus"
|
||||
'
|
||||
@@ -230,15 +283,17 @@ Partial Class frmObjectPropertyDialog
|
||||
'
|
||||
Me.progressLifecycle.Anchor = CType(((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left) _
|
||||
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.progressLifecycle.Location = New System.Drawing.Point(5, 49)
|
||||
Me.progressLifecycle.Location = New System.Drawing.Point(5, 51)
|
||||
Me.progressLifecycle.Name = "progressLifecycle"
|
||||
Me.progressLifecycle.Size = New System.Drawing.Size(538, 40)
|
||||
Me.progressLifecycle.TabIndex = 0
|
||||
'
|
||||
'lbLifecycleEnd
|
||||
'
|
||||
Me.lbLifecycleEnd.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
|
||||
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.lbLifecycleEnd.LineVisible = True
|
||||
Me.lbLifecycleEnd.Location = New System.Drawing.Point(489, 30)
|
||||
Me.lbLifecycleEnd.Location = New System.Drawing.Point(487, 30)
|
||||
Me.lbLifecycleEnd.Name = "lbLifecycleEnd"
|
||||
Me.lbLifecycleEnd.Size = New System.Drawing.Size(56, 13)
|
||||
Me.lbLifecycleEnd.TabIndex = 1
|
||||
@@ -255,78 +310,78 @@ Partial Class frmObjectPropertyDialog
|
||||
'
|
||||
'txtCreatedWhen
|
||||
'
|
||||
Me.txtCreatedWhen.Location = New System.Drawing.Point(94, 37)
|
||||
Me.txtCreatedWhen.Location = New System.Drawing.Point(109, 78)
|
||||
Me.txtCreatedWhen.Name = "txtCreatedWhen"
|
||||
Me.txtCreatedWhen.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtCreatedWhen.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtCreatedWhen.Properties.ReadOnly = True
|
||||
Me.txtCreatedWhen.Size = New System.Drawing.Size(190, 20)
|
||||
Me.txtCreatedWhen.Size = New System.Drawing.Size(172, 20)
|
||||
Me.txtCreatedWhen.StyleController = Me.LayoutControlObject
|
||||
Me.txtCreatedWhen.TabIndex = 4
|
||||
'
|
||||
'txtChangedWhen
|
||||
'
|
||||
Me.txtChangedWhen.Location = New System.Drawing.Point(94, 61)
|
||||
Me.txtChangedWhen.Location = New System.Drawing.Point(109, 108)
|
||||
Me.txtChangedWhen.Name = "txtChangedWhen"
|
||||
Me.txtChangedWhen.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtChangedWhen.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtChangedWhen.Properties.ReadOnly = True
|
||||
Me.txtChangedWhen.Size = New System.Drawing.Size(190, 20)
|
||||
Me.txtChangedWhen.Size = New System.Drawing.Size(172, 20)
|
||||
Me.txtChangedWhen.StyleController = Me.LayoutControlObject
|
||||
Me.txtChangedWhen.TabIndex = 5
|
||||
'
|
||||
'txtAccessedWhen
|
||||
'
|
||||
Me.txtAccessedWhen.Location = New System.Drawing.Point(94, 85)
|
||||
Me.txtAccessedWhen.Location = New System.Drawing.Point(109, 138)
|
||||
Me.txtAccessedWhen.Name = "txtAccessedWhen"
|
||||
Me.txtAccessedWhen.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtAccessedWhen.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtAccessedWhen.Properties.ReadOnly = True
|
||||
Me.txtAccessedWhen.Size = New System.Drawing.Size(190, 20)
|
||||
Me.txtAccessedWhen.Size = New System.Drawing.Size(172, 20)
|
||||
Me.txtAccessedWhen.StyleController = Me.LayoutControlObject
|
||||
Me.txtAccessedWhen.TabIndex = 6
|
||||
'
|
||||
'txtObjectId
|
||||
'
|
||||
Me.txtObjectId.Location = New System.Drawing.Point(94, 12)
|
||||
Me.txtObjectId.Location = New System.Drawing.Point(109, 48)
|
||||
Me.txtObjectId.Name = "txtObjectId"
|
||||
Me.txtObjectId.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtObjectId.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtObjectId.Properties.ReadOnly = True
|
||||
Me.txtObjectId.Size = New System.Drawing.Size(466, 20)
|
||||
Me.txtObjectId.Size = New System.Drawing.Size(436, 20)
|
||||
Me.txtObjectId.StyleController = Me.LayoutControlObject
|
||||
Me.txtObjectId.TabIndex = 7
|
||||
'
|
||||
'txtCreatedWho
|
||||
'
|
||||
Me.txtCreatedWho.Location = New System.Drawing.Point(370, 37)
|
||||
Me.txtCreatedWho.Location = New System.Drawing.Point(373, 78)
|
||||
Me.txtCreatedWho.Name = "txtCreatedWho"
|
||||
Me.txtCreatedWho.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtCreatedWho.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtCreatedWho.Properties.ReadOnly = True
|
||||
Me.txtCreatedWho.Size = New System.Drawing.Size(190, 20)
|
||||
Me.txtCreatedWho.Size = New System.Drawing.Size(172, 20)
|
||||
Me.txtCreatedWho.StyleController = Me.LayoutControlObject
|
||||
Me.txtCreatedWho.TabIndex = 8
|
||||
'
|
||||
'txtChangedWho
|
||||
'
|
||||
Me.txtChangedWho.Location = New System.Drawing.Point(370, 61)
|
||||
Me.txtChangedWho.Location = New System.Drawing.Point(373, 108)
|
||||
Me.txtChangedWho.Name = "txtChangedWho"
|
||||
Me.txtChangedWho.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.txtChangedWho.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.txtChangedWho.Properties.ReadOnly = True
|
||||
Me.txtChangedWho.Size = New System.Drawing.Size(190, 20)
|
||||
Me.txtChangedWho.Size = New System.Drawing.Size(172, 20)
|
||||
Me.txtChangedWho.StyleController = Me.LayoutControlObject
|
||||
Me.txtChangedWho.TabIndex = 9
|
||||
'
|
||||
'TextEdit1
|
||||
'
|
||||
Me.TextEdit1.Location = New System.Drawing.Point(370, 85)
|
||||
Me.TextEdit1.Location = New System.Drawing.Point(373, 138)
|
||||
Me.TextEdit1.Name = "TextEdit1"
|
||||
Me.TextEdit1.Properties.AppearanceReadOnly.BackColor = System.Drawing.Color.White
|
||||
Me.TextEdit1.Properties.AppearanceReadOnly.Options.UseBackColor = True
|
||||
Me.TextEdit1.Properties.ReadOnly = True
|
||||
Me.TextEdit1.Size = New System.Drawing.Size(190, 20)
|
||||
Me.TextEdit1.Size = New System.Drawing.Size(172, 20)
|
||||
Me.TextEdit1.StyleController = Me.LayoutControlObject
|
||||
Me.TextEdit1.TabIndex = 10
|
||||
'
|
||||
@@ -334,99 +389,123 @@ Partial Class frmObjectPropertyDialog
|
||||
'
|
||||
Me.LayoutObject.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.[True]
|
||||
Me.LayoutObject.GroupBordersVisible = False
|
||||
Me.LayoutObject.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem1, Me.LayoutControlItem2, Me.LayoutControlItem3, Me.LayoutControlItem4, Me.SimpleSeparator1, Me.LayoutControlItem5, Me.LayoutControlItem6, Me.txtAccessedWho, Me.EmptySpaceItem1, Me.LayoutControlItem7})
|
||||
Me.LayoutObject.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.SimpleSeparator1, Me.LayoutControlItem7, Me.LayoutControlGroup1, Me.LayoutControlGroup2})
|
||||
Me.LayoutObject.Name = "LayoutObject"
|
||||
Me.LayoutObject.Size = New System.Drawing.Size(572, 534)
|
||||
Me.LayoutObject.TextVisible = False
|
||||
'
|
||||
'LayoutControlItem1
|
||||
'SimpleSeparator1
|
||||
'
|
||||
Me.LayoutControlItem1.Control = Me.txtCreatedWhen
|
||||
Me.LayoutControlItem1.Location = New System.Drawing.Point(0, 25)
|
||||
Me.LayoutControlItem1.Name = "LayoutControlItem1"
|
||||
Me.LayoutControlItem1.Size = New System.Drawing.Size(276, 24)
|
||||
Me.LayoutControlItem1.Text = "Erstellt"
|
||||
Me.LayoutControlItem1.TextSize = New System.Drawing.Size(70, 13)
|
||||
Me.SimpleSeparator1.AllowHotTrack = False
|
||||
Me.SimpleSeparator1.Location = New System.Drawing.Point(0, 165)
|
||||
Me.SimpleSeparator1.Name = "SimpleSeparator1"
|
||||
Me.SimpleSeparator1.Size = New System.Drawing.Size(552, 1)
|
||||
'
|
||||
'LayoutControlItem2
|
||||
'LayoutControlItem7
|
||||
'
|
||||
Me.LayoutControlItem2.Control = Me.txtChangedWhen
|
||||
Me.LayoutControlItem2.Location = New System.Drawing.Point(0, 49)
|
||||
Me.LayoutControlItem2.Name = "LayoutControlItem2"
|
||||
Me.LayoutControlItem2.Size = New System.Drawing.Size(276, 24)
|
||||
Me.LayoutControlItem2.Text = "Geändert"
|
||||
Me.LayoutControlItem2.TextSize = New System.Drawing.Size(70, 13)
|
||||
Me.LayoutControlItem7.Control = Me.GroupControl1
|
||||
Me.LayoutControlItem7.Location = New System.Drawing.Point(0, 414)
|
||||
Me.LayoutControlItem7.Name = "LayoutControlItem7"
|
||||
Me.LayoutControlItem7.Size = New System.Drawing.Size(552, 100)
|
||||
Me.LayoutControlItem7.TextSize = New System.Drawing.Size(0, 0)
|
||||
Me.LayoutControlItem7.TextVisible = False
|
||||
'
|
||||
'LayoutControlItem3
|
||||
'LayoutControlGroup1
|
||||
'
|
||||
Me.LayoutControlItem3.Control = Me.txtAccessedWhen
|
||||
Me.LayoutControlItem3.Location = New System.Drawing.Point(0, 73)
|
||||
Me.LayoutControlItem3.Name = "LayoutControlItem3"
|
||||
Me.LayoutControlItem3.Size = New System.Drawing.Size(276, 24)
|
||||
Me.LayoutControlItem3.Text = "Letzter Zugriff"
|
||||
Me.LayoutControlItem3.TextSize = New System.Drawing.Size(70, 13)
|
||||
Me.LayoutControlGroup1.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem8})
|
||||
Me.LayoutControlGroup1.Location = New System.Drawing.Point(0, 166)
|
||||
Me.LayoutControlGroup1.Name = "LayoutControlGroup1"
|
||||
Me.LayoutControlGroup1.Size = New System.Drawing.Size(552, 248)
|
||||
Me.LayoutControlGroup1.Text = "Objekt Historie"
|
||||
'
|
||||
'LayoutControlItem8
|
||||
'
|
||||
Me.LayoutControlItem8.Control = Me.GridObjectHistory
|
||||
Me.LayoutControlItem8.Location = New System.Drawing.Point(0, 0)
|
||||
Me.LayoutControlItem8.Name = "LayoutControlItem8"
|
||||
Me.LayoutControlItem8.Size = New System.Drawing.Size(528, 203)
|
||||
Me.LayoutControlItem8.TextSize = New System.Drawing.Size(0, 0)
|
||||
Me.LayoutControlItem8.TextVisible = False
|
||||
'
|
||||
'LayoutControlGroup2
|
||||
'
|
||||
Me.LayoutControlGroup2.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem4, Me.LayoutControlItem1, Me.LayoutControlItem5, Me.LayoutControlItem6, Me.LayoutControlItem2, Me.LayoutControlItem3, Me.txtAccessedWho})
|
||||
Me.LayoutControlGroup2.Location = New System.Drawing.Point(0, 0)
|
||||
Me.LayoutControlGroup2.Name = "LayoutControlGroup2"
|
||||
Me.LayoutControlGroup2.Size = New System.Drawing.Size(552, 165)
|
||||
Me.LayoutControlGroup2.Text = "Eigenschaften"
|
||||
'
|
||||
'LayoutControlItem4
|
||||
'
|
||||
Me.LayoutControlItem4.Control = Me.txtObjectId
|
||||
Me.LayoutControlItem4.Location = New System.Drawing.Point(0, 0)
|
||||
Me.LayoutControlItem4.Name = "LayoutControlItem4"
|
||||
Me.LayoutControlItem4.Size = New System.Drawing.Size(552, 24)
|
||||
Me.LayoutControlItem4.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem4.Size = New System.Drawing.Size(528, 30)
|
||||
Me.LayoutControlItem4.Text = "Objekt Id"
|
||||
Me.LayoutControlItem4.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'SimpleSeparator1
|
||||
'LayoutControlItem1
|
||||
'
|
||||
Me.SimpleSeparator1.AllowHotTrack = False
|
||||
Me.SimpleSeparator1.Location = New System.Drawing.Point(0, 24)
|
||||
Me.SimpleSeparator1.Name = "SimpleSeparator1"
|
||||
Me.SimpleSeparator1.Size = New System.Drawing.Size(552, 1)
|
||||
Me.LayoutControlItem1.Control = Me.txtCreatedWhen
|
||||
Me.LayoutControlItem1.Location = New System.Drawing.Point(0, 30)
|
||||
Me.LayoutControlItem1.Name = "LayoutControlItem1"
|
||||
Me.LayoutControlItem1.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem1.Size = New System.Drawing.Size(264, 30)
|
||||
Me.LayoutControlItem1.Text = "Erstellt"
|
||||
Me.LayoutControlItem1.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'LayoutControlItem5
|
||||
'
|
||||
Me.LayoutControlItem5.Control = Me.txtCreatedWho
|
||||
Me.LayoutControlItem5.Location = New System.Drawing.Point(276, 25)
|
||||
Me.LayoutControlItem5.Location = New System.Drawing.Point(264, 30)
|
||||
Me.LayoutControlItem5.Name = "LayoutControlItem5"
|
||||
Me.LayoutControlItem5.Size = New System.Drawing.Size(276, 24)
|
||||
Me.LayoutControlItem5.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem5.Size = New System.Drawing.Size(264, 30)
|
||||
Me.LayoutControlItem5.Text = "von"
|
||||
Me.LayoutControlItem5.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'LayoutControlItem6
|
||||
'
|
||||
Me.LayoutControlItem6.Control = Me.txtChangedWho
|
||||
Me.LayoutControlItem6.Location = New System.Drawing.Point(276, 49)
|
||||
Me.LayoutControlItem6.Location = New System.Drawing.Point(264, 60)
|
||||
Me.LayoutControlItem6.Name = "LayoutControlItem6"
|
||||
Me.LayoutControlItem6.Size = New System.Drawing.Size(276, 24)
|
||||
Me.LayoutControlItem6.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem6.Size = New System.Drawing.Size(264, 30)
|
||||
Me.LayoutControlItem6.Text = "von"
|
||||
Me.LayoutControlItem6.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'LayoutControlItem2
|
||||
'
|
||||
Me.LayoutControlItem2.Control = Me.txtChangedWhen
|
||||
Me.LayoutControlItem2.Location = New System.Drawing.Point(0, 60)
|
||||
Me.LayoutControlItem2.Name = "LayoutControlItem2"
|
||||
Me.LayoutControlItem2.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem2.Size = New System.Drawing.Size(264, 30)
|
||||
Me.LayoutControlItem2.Text = "Geändert"
|
||||
Me.LayoutControlItem2.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'LayoutControlItem3
|
||||
'
|
||||
Me.LayoutControlItem3.Control = Me.txtAccessedWhen
|
||||
Me.LayoutControlItem3.Location = New System.Drawing.Point(0, 90)
|
||||
Me.LayoutControlItem3.Name = "LayoutControlItem3"
|
||||
Me.LayoutControlItem3.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.LayoutControlItem3.Size = New System.Drawing.Size(264, 30)
|
||||
Me.LayoutControlItem3.Text = "Letzter Zugriff"
|
||||
Me.LayoutControlItem3.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'txtAccessedWho
|
||||
'
|
||||
Me.txtAccessedWho.Control = Me.TextEdit1
|
||||
Me.txtAccessedWho.CustomizationFormText = "von"
|
||||
Me.txtAccessedWho.Location = New System.Drawing.Point(276, 73)
|
||||
Me.txtAccessedWho.Location = New System.Drawing.Point(264, 90)
|
||||
Me.txtAccessedWho.Name = "txtAccessedWho"
|
||||
Me.txtAccessedWho.Size = New System.Drawing.Size(276, 24)
|
||||
Me.txtAccessedWho.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5)
|
||||
Me.txtAccessedWho.Size = New System.Drawing.Size(264, 30)
|
||||
Me.txtAccessedWho.Text = "von"
|
||||
Me.txtAccessedWho.TextSize = New System.Drawing.Size(70, 13)
|
||||
'
|
||||
'EmptySpaceItem1
|
||||
'
|
||||
Me.EmptySpaceItem1.AllowHotTrack = False
|
||||
Me.EmptySpaceItem1.Location = New System.Drawing.Point(0, 97)
|
||||
Me.EmptySpaceItem1.Name = "EmptySpaceItem1"
|
||||
Me.EmptySpaceItem1.Size = New System.Drawing.Size(552, 319)
|
||||
Me.EmptySpaceItem1.TextSize = New System.Drawing.Size(0, 0)
|
||||
'
|
||||
'LayoutControlItem7
|
||||
'
|
||||
Me.LayoutControlItem7.Control = Me.GroupControl1
|
||||
Me.LayoutControlItem7.Location = New System.Drawing.Point(0, 416)
|
||||
Me.LayoutControlItem7.Name = "LayoutControlItem7"
|
||||
Me.LayoutControlItem7.Size = New System.Drawing.Size(552, 98)
|
||||
Me.LayoutControlItem7.TextSize = New System.Drawing.Size(0, 0)
|
||||
Me.LayoutControlItem7.TextVisible = False
|
||||
'
|
||||
'TabPageHistory
|
||||
'
|
||||
Me.TabPageHistory.ContentContainer = Me.TabFormContentContainer4
|
||||
@@ -514,7 +593,7 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.ClientSize = New System.Drawing.Size(572, 605)
|
||||
Me.Controls.Add(Me.TabFormContentContainer1)
|
||||
Me.Controls.Add(Me.TabFormContentContainer2)
|
||||
Me.Controls.Add(Me.TabFormControl1)
|
||||
Me.IconOptions.SvgImage = CType(resources.GetObject("frmObjectPropertyDialog.IconOptions.SvgImage"), DevExpress.Utils.Svg.SvgImage)
|
||||
Me.Name = "frmObjectPropertyDialog"
|
||||
@@ -528,6 +607,8 @@ Partial Class frmObjectPropertyDialog
|
||||
Me.TabFormContentContainer2.ResumeLayout(False)
|
||||
CType(Me.LayoutControlObject, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.LayoutControlObject.ResumeLayout(False)
|
||||
CType(Me.GridObjectHistory, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.GridView1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.GroupControl1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.GroupControl1.ResumeLayout(False)
|
||||
Me.GroupControl1.PerformLayout()
|
||||
@@ -540,16 +621,18 @@ Partial Class frmObjectPropertyDialog
|
||||
CType(Me.txtChangedWho.Properties, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.TextEdit1.Properties, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutObject, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem4, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.SimpleSeparator1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem7, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlGroup1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem8, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlGroup2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem4, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem5, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem6, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.txtAccessedWho, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.EmptySpaceItem1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.LayoutControlItem7, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.TabFormContentContainer4.ResumeLayout(False)
|
||||
CType(Me.GridValueHistory, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.ViewValueHistory, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
@@ -584,21 +667,28 @@ Partial Class frmObjectPropertyDialog
|
||||
Friend WithEvents txtChangedWhen As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents txtAccessedWhen As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents txtObjectId As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents LayoutControlItem1 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem2 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem3 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem4 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents SimpleSeparator1 As DevExpress.XtraLayout.SimpleSeparator
|
||||
Friend WithEvents txtCreatedWho As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents txtChangedWho As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents LayoutControlItem5 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem6 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents TextEdit1 As DevExpress.XtraEditors.TextEdit
|
||||
Friend WithEvents txtAccessedWho As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents EmptySpaceItem1 As DevExpress.XtraLayout.EmptySpaceItem
|
||||
Friend WithEvents lbLifecycleStart As DevExpress.XtraEditors.LabelControl
|
||||
Friend WithEvents lbLifecycleEnd As DevExpress.XtraEditors.LabelControl
|
||||
Friend WithEvents progressLifecycle As DevExpress.XtraEditors.ProgressBarControl
|
||||
Friend WithEvents GroupControl1 As DevExpress.XtraEditors.GroupControl
|
||||
Friend WithEvents LayoutControlItem7 As DevExpress.XtraLayout.LayoutControlItem
|
||||
Friend WithEvents GridObjectHistory As GridControl
|
||||
Friend WithEvents GridView1 As GridView
|
||||
Friend WithEvents LayoutControlItem4 As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem1 As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem2 As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem5 As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem6 As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem3 As LayoutControlItem
|
||||
Friend WithEvents txtAccessedWho As LayoutControlItem
|
||||
Friend WithEvents LayoutControlItem8 As LayoutControlItem
|
||||
Friend WithEvents btnSave As DevExpress.XtraBars.BarButtonItem
|
||||
Friend WithEvents LayoutControlGroup1 As LayoutControlGroup
|
||||
Friend WithEvents LayoutControlGroup2 As LayoutControlGroup
|
||||
Friend WithEvents GridColumn6 As Columns.GridColumn
|
||||
Friend WithEvents GridColumn7 As Columns.GridColumn
|
||||
End Class
|
||||
|
||||
@@ -9,28 +9,37 @@ Imports DigitalData.Modules.ZooFlow
|
||||
Imports DigitalData.Modules.Language
|
||||
Imports DevExpress.XtraGrid
|
||||
Imports DigitalData.Modules.EDMI.API
|
||||
Imports DigitalData.GUIs.Common.Base
|
||||
Imports DigitalData.Modules.Base
|
||||
|
||||
Public Class frmObjectPropertyDialog
|
||||
Private _LogConfig As LogConfig
|
||||
Private _Logger As Logger
|
||||
Private _Environment As Environment
|
||||
Private ReadOnly _Client As Client
|
||||
Private _ObjectId As Int64
|
||||
Private _Db As MSSQLServer
|
||||
Private _Controls As PropertyControls
|
||||
Implements IBaseForm
|
||||
|
||||
Public Sub New(LogConfig As LogConfig, Environment As Environment, Client As Client, ObjectId As Long)
|
||||
Private ReadOnly Environment As Environment
|
||||
Private ReadOnly Client As Client
|
||||
Private ReadOnly ObjectId As Int64
|
||||
Private ReadOnly DatabaseIDB As MSSQLServer
|
||||
Private ReadOnly ControlManager As PropertyControls
|
||||
|
||||
Private ReadOnly Property LogConfig As LogConfig Implements IBaseForm.LogConfig
|
||||
Private ReadOnly Property Logger As Logger Implements IBaseForm.Logger
|
||||
Private ReadOnly Property ErrorHandler As BaseErrorHandler Implements IBaseForm.ErrorHandler
|
||||
|
||||
Private ReadOnly Changes As New Dictionary(Of String, Object)
|
||||
|
||||
Public Sub New(pLogConfig As LogConfig, pEnvironment As Environment, pClient As Client, pObjectId As Long)
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
_LogConfig = LogConfig
|
||||
_Logger = LogConfig.GetLogger()
|
||||
_Environment = Environment
|
||||
_Client = Client
|
||||
_ObjectId = ObjectId
|
||||
_Db = _Environment.DatabaseIDB
|
||||
_Controls = New PropertyControls(_LogConfig, _Db)
|
||||
LogConfig = pLogConfig
|
||||
Logger = pLogConfig.GetLogger()
|
||||
Environment = pEnvironment
|
||||
Client = pClient
|
||||
ObjectId = pObjectId
|
||||
DatabaseIDB = Environment.DatabaseIDB
|
||||
ControlManager = New PropertyControls(LogConfig, DatabaseIDB)
|
||||
ErrorHandler = New BaseErrorHandler(LogConfig, Me)
|
||||
End Sub
|
||||
|
||||
Private Async Sub frmObjectPropertyDialog_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
@@ -39,31 +48,27 @@ Public Class frmObjectPropertyDialog
|
||||
Try
|
||||
oHandle = SplashScreenManager.ShowOverlayForm(Me)
|
||||
|
||||
If IsNothing(_ObjectId) Then
|
||||
If IsNothing(ObjectId) Then
|
||||
Throw New ApplicationException("No valid Object Id supplied!")
|
||||
End If
|
||||
|
||||
Dim oEntityIds = Await GetBusinessEntitiesForObjectId(_ObjectId)
|
||||
Dim oHistoryDataTable = Await GetValueHistoryForObjectId(_ObjectId)
|
||||
Dim oObjectProperties = Await GetPropertiesForObjectId(_ObjectId)
|
||||
Dim oEntityIds = Await GetBusinessEntitiesForObjectId(ObjectId)
|
||||
Dim oValueHistoryTable = Await GetValueHistoryForObjectId(ObjectId)
|
||||
Dim oObjectHistoryTable = Await GetObjectHistoryForObjectID(ObjectId)
|
||||
|
||||
Dim oObjectProperties = Await GetPropertiesForObjectId(ObjectId)
|
||||
Dim oCombobox As RepositoryItemComboBox = DirectCast(cmbBusinessEntity.Edit, RepositoryItemComboBox)
|
||||
oCombobox.Items.AddRange(oEntityIds)
|
||||
|
||||
ShowAttributeHistory(oHistoryDataTable)
|
||||
ShowAttributeHistory(oValueHistoryTable)
|
||||
ShowObjectHistory(oObjectHistoryTable)
|
||||
ShowObjectProperties(oObjectProperties)
|
||||
|
||||
'If oEntityIds.Count = 1 Then
|
||||
' cmbBusinessEntity.EditValue = oEntityIds.First()
|
||||
'End If
|
||||
cmbBusinessEntity.EditValue = oEntityIds.First()
|
||||
Catch ex As ApplicationException
|
||||
_Logger.Error(ex)
|
||||
MessageBox.Show(ex.Message, Text, MessageBoxButtons.OK, MessageBoxIcon.Error)
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
MessageBox.Show("Unhandled exception occurred. Please check the log." & vbNewLine & ex.Message, Text, MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
|
||||
ErrorHandler.ShowErrorMessage(ex, "frmObjectPropertyDialog_Load")
|
||||
Finally
|
||||
If oHandle IsNot Nothing
|
||||
If oHandle IsNot Nothing Then
|
||||
SplashScreenManager.CloseOverlayForm(oHandle)
|
||||
End If
|
||||
End Try
|
||||
@@ -71,8 +76,8 @@ Public Class frmObjectPropertyDialog
|
||||
|
||||
Private Async Function GetAttributesForBusinessEntity(EntityId As Long) As Task(Of List(Of Attribute))
|
||||
Try
|
||||
Dim oSQL = $"SELECT * FROM VWIDB_BE_ATTRIBUTE WHERE BE_ID = {EntityId} AND LANG_CODE = '{_Environment.User.Language}'"
|
||||
Dim oResult = Await _Client.GetDatatableFromIDBAsync(oSQL)
|
||||
Dim oSQL = $"SELECT * FROM VWIDB_BE_ATTRIBUTE WHERE BE_ID = {EntityId} AND LANG_CODE = '{Environment.User.Language}'"
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
If oResult.OK = False Then
|
||||
Throw New ApplicationException($"Attributes for Business Entity {EntityId} could not be retrieved!")
|
||||
@@ -96,7 +101,7 @@ Public Class frmObjectPropertyDialog
|
||||
Return oAttributes
|
||||
End If
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
Logger.Error(ex)
|
||||
Return New List(Of Attribute)
|
||||
End Try
|
||||
End Function
|
||||
@@ -104,7 +109,7 @@ Public Class frmObjectPropertyDialog
|
||||
Private Async Function GetBusinessEntitiesForObjectId(ObjectId As Long) As Task(Of List(Of Long))
|
||||
Try
|
||||
Dim oSQL = $"SELECT BE_ID FROM TBIDB_OBJECT_BE WHERE IDB_OBJ_ID = {ObjectId}"
|
||||
Dim oResult = Await _Client.GetDatatableFromIDBAsync(oSQL)
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
If oResult.OK = False Then
|
||||
Throw New ApplicationException($"Business Entities could not be retrieved!")
|
||||
@@ -122,21 +127,36 @@ Public Class frmObjectPropertyDialog
|
||||
Return oEntities
|
||||
End If
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
Logger.Error(ex)
|
||||
Return New List(Of Long)
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Async Function GetValueHistoryForObjectId(ObjectId As Long) As Task(Of DataTable)
|
||||
Dim oSQL As String = $"SELECT * FROM VWIDB_CHANGE_LOG WHERE IDB_OBJ_ID = {ObjectId} ORDER BY ChangeID DESC"
|
||||
Dim oResult = Await _Client.GetDatatableFromIDBAsync(oSQL)
|
||||
Dim oSQL As String = $"
|
||||
SELECT * FROM VWIDB_CHANGE_LOG
|
||||
WHERE IDB_OBJ_ID = {ObjectId} AND
|
||||
ORDER BY ChangeID DESC
|
||||
"
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
Return oResult.Table
|
||||
End Function
|
||||
|
||||
Private Async Function GetObjectHistoryForObjectId(ObjectId As Long) As Task(Of DataTable)
|
||||
Dim oSQL As String = $"
|
||||
SELECT * FROM VWIDB_DOC_STATES
|
||||
WHERE IDB_OBJ_ID = {ObjectId} AND LANG_CODE = '{Environment.User.Language}'
|
||||
ORDER BY ADDED_WHEN DESC
|
||||
"
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
Return oResult.Table
|
||||
End Function
|
||||
|
||||
Private Async Function GetPropertiesForObjectId(ObjectId As Long) As Task(Of DataTable)
|
||||
Dim oSQL As String = $"SELECT * FROM TBIDB_OBJECT WHERE IDB_OBJ_ID = {ObjectId}"
|
||||
Dim oResult = Await _Client.GetDatatableFromIDBAsync(oSQL)
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
Return oResult.Table
|
||||
End Function
|
||||
@@ -144,7 +164,7 @@ Public Class frmObjectPropertyDialog
|
||||
Private Async Function GetAttributeValue(AttributeName As String, ObjectId As Long, Optional LanguageCode As String = "de-DE", Optional IsForeign As Boolean = False) As Task(Of Object)
|
||||
Dim oIsForeign = IIf(IsForeign, 1, 0)
|
||||
Dim oSQL = $"SELECT TERM_VALUE FROM [dbo].[FNIDB_PM_GET_VARIABLE_VALUE] ({ObjectId}, '{AttributeName}', '{LanguageCode}', {oIsForeign})"
|
||||
Dim oResult = Await _Client.GetScalarValueFromIDBAsync(oSQL)
|
||||
Dim oResult = Await Client.GetScalarValueFromIDBAsync(oSQL)
|
||||
|
||||
Return oResult.Scalar
|
||||
End Function
|
||||
@@ -152,12 +172,12 @@ Public Class frmObjectPropertyDialog
|
||||
Private Async Function GetAttributeValueAsTable(AttributeName As String, ObjectId As Long, Optional LanguageCode As String = "de-DE", Optional IsForeign As Boolean = False) As Task(Of DataTable)
|
||||
Dim oIsForeign = IIf(IsForeign, 1, 0)
|
||||
Dim oSQL = $"SELECT TERM_VALUE FROM [dbo].[FNIDB_PM_GET_VARIABLE_VALUE] ({ObjectId}, '{AttributeName}', '{LanguageCode}', {oIsForeign})"
|
||||
Dim oResult = Await _Client.GetDatatableFromIDBAsync(oSQL)
|
||||
Dim oResult = Await Client.GetDatatableFromIDBAsync(oSQL)
|
||||
|
||||
Return oResult.Table
|
||||
End Function
|
||||
|
||||
Private Async Sub cmbBusinessEntity_EditValueChanged(sender As Object, e As EventArgs) Handles cmbBusinessEntity.EditValueChanged
|
||||
Private Sub cmbBusinessEntity_EditValueChanged(sender As Object, e As EventArgs) Handles cmbBusinessEntity.EditValueChanged
|
||||
Load_Attributes()
|
||||
End Sub
|
||||
Private Async Sub Load_Attributes()
|
||||
@@ -172,12 +192,12 @@ Public Class frmObjectPropertyDialog
|
||||
Dim oAttributes = Await GetAttributesForBusinessEntity(oEntityId)
|
||||
|
||||
If oAttributes.Count = 0 Then
|
||||
MsgBox($"Es konnten keine Attribute für das Objekt '{_ObjectId}' geladen werden!", MsgBoxStyle.Critical, Text)
|
||||
MsgBox($"Es konnten keine Attribute für das Objekt '{ObjectId}' geladen werden!", MsgBoxStyle.Critical, Text)
|
||||
End If
|
||||
|
||||
For Each oAttribute As Attribute In oAttributes
|
||||
Dim oEditable = ShouldControlBeEditable(oAttribute)
|
||||
Dim oControl = _Controls.GetControlForAttribute(oAttribute, Not oEditable)
|
||||
Dim oControl = ControlManager.GetControlForAttribute(oAttribute, Not oEditable)
|
||||
Dim oItem As LayoutControlItem = AttributeLayout.AddItem()
|
||||
|
||||
oItem.Text = oAttribute.Title
|
||||
@@ -187,12 +207,14 @@ Public Class frmObjectPropertyDialog
|
||||
|
||||
For Each oItem As LayoutControlItem In AttributeLayout.Items
|
||||
If TypeOf oItem.Control Is BaseEdit Then
|
||||
Dim oValue = Await GetAttributeValue(oItem.Name, _ObjectId)
|
||||
Dim oValue = Await GetAttributeValue(oItem.Name, ObjectId)
|
||||
Dim oEdit = DirectCast(oItem.Control, BaseEdit)
|
||||
oEdit.EditValue = oValue
|
||||
|
||||
AddHandler oEdit.EditValueChanged, AddressOf BaseEdit_EditValueChanged
|
||||
|
||||
ElseIf TypeOf oItem.Control Is GridControl Then
|
||||
Dim oValueTable = Await GetAttributeValueAsTable(oItem.Name, _ObjectId)
|
||||
Dim oValueTable = Await GetAttributeValueAsTable(oItem.Name, ObjectId)
|
||||
Dim oGrid = DirectCast(oItem.Control, GridControl)
|
||||
oGrid.DataSource = oValueTable
|
||||
|
||||
@@ -200,9 +222,22 @@ Public Class frmObjectPropertyDialog
|
||||
End If
|
||||
Next
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
Logger.Error(ex)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub BaseEdit_EditValueChanged(sender As Object, e As EventArgs)
|
||||
Dim oControl As BaseEdit = sender
|
||||
Dim oAttribute As Attribute = oControl.Tag
|
||||
Dim oValue = oControl.EditValue
|
||||
Dim oKey = oAttribute.Title
|
||||
|
||||
If Changes.ContainsKey(oKey) Then
|
||||
Changes.Item(oKey) = oValue
|
||||
Else
|
||||
Changes.Add(oAttribute.Title, oValue)
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Function ShouldControlBeEditable(pAttribute As Attribute) As Boolean
|
||||
@@ -215,15 +250,22 @@ Public Class frmObjectPropertyDialog
|
||||
|
||||
Private Function ShowAttributeHistory(pDatatable As DataTable) As Boolean
|
||||
Try
|
||||
If pDatatable.Rows.Count > 0
|
||||
GridValueHistory.DataSource = pDatatable
|
||||
Else
|
||||
TabPageHistory.Visible = False
|
||||
End If
|
||||
GridValueHistory.DataSource = pDatatable
|
||||
|
||||
Return True
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
Logger.Error(ex)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Function ShowObjectHistory(pDatatable As DataTable) As Boolean
|
||||
Try
|
||||
GridObjectHistory.DataSource = pDatatable
|
||||
|
||||
Return True
|
||||
Catch ex As Exception
|
||||
Logger.Error(ex)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
@@ -243,8 +285,39 @@ Public Class frmObjectPropertyDialog
|
||||
|
||||
Return True
|
||||
Catch ex As Exception
|
||||
_Logger.Error(ex)
|
||||
Logger.Error(ex)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Async Sub btnSave_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles btnSave.ItemClick
|
||||
Try
|
||||
For Each oChange As KeyValuePair(Of String, Object) In Changes
|
||||
Logger.Info("Updating Attribute [{0}] with value [{1}]", oChange.Key, oChange.Value.ToString)
|
||||
|
||||
Await Client.SetAttributeValueAsync(ObjectId, oChange.Key, oChange.Value, New Options.SetAttributeValueOptions With {
|
||||
.Language = Environment.User.Language,
|
||||
.Username = Environment.User.UserName
|
||||
})
|
||||
Logger.Info("Updating Object State for Object [{0}]", ObjectId)
|
||||
Await Client.SetObjectStateAsync(ObjectId, IDB.FileStore.OBJECT_STATE_METADATA_CHANGED, New Options.SetObjectStateOptions With {
|
||||
.Language = Environment.User.Language,
|
||||
.Username = Environment.User.UserName
|
||||
})
|
||||
Next
|
||||
|
||||
ErrorHandler.ShowInfoMessage($"{Changes.Count} Änderungen gespeichert!")
|
||||
Changes.Clear()
|
||||
Catch ex As Exception
|
||||
ErrorHandler.ShowErrorMessage(ex, "btnSave_ItemClick")
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub TabFormControl1_Click(sender As Object, e As EventArgs) Handles TabFormControl1.Click
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub GroupControl1_Paint(sender As Object, e As PaintEventArgs) Handles GroupControl1.Paint
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user