Reconfigure for GIT
This commit is contained in:
+32
@@ -0,0 +1,32 @@
|
||||
Partial Class GLCassaVC
|
||||
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Public Sub New(ByVal Container As System.ComponentModel.IContainer)
|
||||
MyClass.New()
|
||||
|
||||
'Required for Windows.Forms Class Composition Designer support
|
||||
Container.Add(Me)
|
||||
|
||||
End Sub
|
||||
|
||||
'Component overrides dispose to clean up the component list.
|
||||
<System.Diagnostics.DebuggerNonUserCode()> _
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
MyBase.Dispose(disposing)
|
||||
End Sub
|
||||
|
||||
'Required by the Component Designer
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'NOTE: The following procedure is required by the Component Designer
|
||||
'It can be modified using the Component Designer.
|
||||
'Do not modify it using the code editor.
|
||||
<System.Diagnostics.DebuggerStepThrough()> _
|
||||
Private Sub InitializeComponent()
|
||||
components = New System.ComponentModel.Container()
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
Imports System.Diagnostics
|
||||
Imports System.Text
|
||||
|
||||
Imports DevExpress.ExpressApp
|
||||
Imports DevExpress.ExpressApp.Actions
|
||||
Imports DevExpress.Persistent.Base
|
||||
Imports DevExpress.ExpressApp.Win.SystemModule
|
||||
Imports DevExpress.XtraGrid.Views.Grid
|
||||
Imports DevExpress.ExpressApp.Editors
|
||||
Imports DevExpress.ExpressApp.Win.Editors
|
||||
|
||||
Public Class GLCassaVC
|
||||
Inherits DevExpress.ExpressApp.ViewController
|
||||
Private _GridListEditor As GridListEditor
|
||||
|
||||
Public Sub New()
|
||||
MyBase.New()
|
||||
|
||||
'This call is required by the Component Designer.
|
||||
InitializeComponent()
|
||||
RegisterActions(components)
|
||||
|
||||
End Sub
|
||||
Protected Overrides Sub OnActivated()
|
||||
MyBase.OnActivated()
|
||||
If View.Id = "GLCassa_DetailView" Or View.Id = "GLCassa_GLRows_ListView" Then
|
||||
Frame.GetController(Of WinModificationsController).ModificationsHandlingMode = SystemModule.ModificationsHandlingMode.AutoCommit
|
||||
End If
|
||||
End Sub
|
||||
Protected Overrides Sub OnDeactivated()
|
||||
MyBase.OnDeactivated()
|
||||
If View.Id = "GLCassa_ListView" Then
|
||||
Dim editor As ListEditor = (CType(View, ListView)).Editor
|
||||
Dim gridView As GridView = (CType(editor, GridListEditor)).GridView
|
||||
|
||||
RemoveHandler gridView.SelectionChanged, AddressOf GridView_SelectionChanged
|
||||
End If
|
||||
End Sub
|
||||
Protected Overrides Sub OnViewControlsCreated()
|
||||
MyBase.OnViewControlsCreated()
|
||||
If View.Id = "GLCassa_ListView" Then
|
||||
Dim editor As ListEditor = (CType(View, ListView)).Editor
|
||||
Dim gridView As GridView = (CType(editor, GridListEditor)).GridView
|
||||
|
||||
AddHandler gridView.SelectionChanged, AddressOf GridView_SelectionChanged
|
||||
End If
|
||||
|
||||
'If View.Id = "GLRows_ListView_Cassa" Then
|
||||
' Dim _ListView As ListView = CType(View, ListView)
|
||||
' _GridListEditor = TryCast(_ListView.Editor, GridListEditor)
|
||||
' If _GridListEditor IsNot Nothing Then
|
||||
' _GridListEditor.AllowEdit = True
|
||||
|
||||
' For i As Integer = 0 To _GridListEditor.Columns.Count - 1
|
||||
|
||||
' If _GridListEditor.GridView.Columns(i).FieldName <> "NoteRows" And _
|
||||
' _GridListEditor.GridView.Columns(i).FieldName <> "Controlling!" And _
|
||||
' _GridListEditor.GridView.Columns(i).FieldName <> "CostHolder!" And _
|
||||
' _GridListEditor.GridView.Columns(i).FieldName <> "CostPlace!" And _
|
||||
' _GridListEditor.GridView.Columns(i).FieldName <> "JobNumberObjects!" And _
|
||||
' _GridListEditor.GridView.Columns(i).FieldName <> "UniqueObjects!" Then
|
||||
' _GridListEditor.GridView.Columns(i).OptionsColumn.ReadOnly = True
|
||||
' _GridListEditor.GridView.Columns(i).OptionsColumn.AllowEdit = False
|
||||
' _GridListEditor.GridView.Columns(i).OptionsColumn.TabStop = False
|
||||
' End If
|
||||
|
||||
' Next
|
||||
|
||||
' End If
|
||||
'End If
|
||||
|
||||
End Sub
|
||||
Private Sub GridView_SelectionChanged(ByVal sender As Object, ByVal e As DevExpress.Data.SelectionChangedEventArgs)
|
||||
Dim gridView As GridView = TryCast(sender, GridView)
|
||||
If View.SelectedObjects.Count = 1 Then
|
||||
Dim _GLCassa As GLCassa = TryCast(View.SelectedObjects(0), GLCassa)
|
||||
If _GLCassa Is Nothing Then
|
||||
Else
|
||||
Frame.GetController(Of DevExpress.ExpressApp.SystemModule.DeleteObjectsViewController).Active.SetItemValue("", True)
|
||||
If _GLCassa.IsEditable = False Then
|
||||
Frame.GetController(Of DevExpress.ExpressApp.SystemModule.DeleteObjectsViewController).Active.SetItemValue("", False)
|
||||
End If
|
||||
End If
|
||||
ElseIf View.SelectedObjects.Count > 1 Then
|
||||
Frame.GetController(Of DevExpress.ExpressApp.SystemModule.DeleteObjectsViewController).Active.SetItemValue("", False)
|
||||
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user