147 lines
5.3 KiB
VB.net
147 lines
5.3 KiB
VB.net
Imports Microsoft.VisualBasic
|
|
Imports System
|
|
Imports System.Linq
|
|
Imports System.Text
|
|
Imports DevExpress.Xpo
|
|
Imports DevExpress.ExpressApp
|
|
Imports System.ComponentModel
|
|
Imports DevExpress.ExpressApp.DC
|
|
Imports DevExpress.Data.Filtering
|
|
Imports DevExpress.Persistent.Base
|
|
Imports System.Collections.Generic
|
|
Imports DevExpress.ExpressApp.Model
|
|
Imports DevExpress.Persistent.BaseImpl
|
|
Imports DevExpress.Persistent.Validation
|
|
|
|
'<ImageName("BO_Contact")> _
|
|
'<DefaultProperty("DisplayMemberNameForLookupEditorsOfThisType")> _
|
|
'<DefaultListViewOptions(MasterDetailMode.ListViewOnly, False, NewItemRowPosition.None)> _
|
|
'<Persistent("DatabaseTableName")> _
|
|
<DefaultClassOptions(), NavigationItem(False), CreatableItem(False)> _
|
|
Public Class VATCompare ' Specify more UI options using a declarative approach (http://documentation.devexpress.com/#Xaf/CustomDocument2701).
|
|
Inherits BaseObject ' Inherit from a different class to provide a custom primary key, concurrency and deletion behavior, etc. (http://documentation.devexpress.com/#Xaf/CustomDocument3146).
|
|
|
|
Private _CustomersFrom As CustomersFrom
|
|
Private _ShortName As String 'Megnevezés pld 2011 jaunári áfa
|
|
Private _ObjectCreated As Date
|
|
Private _UserCreated As User
|
|
|
|
Private _VATReportSource As VATReport
|
|
Private _VATReportDestination As VATReport
|
|
|
|
Public Sub New(ByVal session As Session)
|
|
MyBase.New(session)
|
|
End Sub
|
|
Public Overrides Sub AfterConstruction()
|
|
MyBase.AfterConstruction()
|
|
' Place your initialization code here (http://documentation.devexpress.com/#Xaf/CustomDocument2834).
|
|
End Sub
|
|
Protected Overrides Sub OnSaving()
|
|
MyBase.OnSaving()
|
|
If Session.IsNewObject(Me) Then
|
|
ObjectCreated = GetSQLTime(Session)
|
|
UserCreated = Session.GetObjectByKey(Of User)(Session.GetKeyValue(SecuritySystem.CurrentUser))
|
|
End If
|
|
End Sub
|
|
|
|
Property CustomersFrom As CustomersFrom
|
|
Get
|
|
Return _CustomersFrom
|
|
End Get
|
|
Set(value As CustomersFrom)
|
|
SetPropertyValue("CustomersFrom", _CustomersFrom, value)
|
|
End Set
|
|
End Property
|
|
<RuleRequiredField("VATCompare-ShortName-Save", DefaultContexts.Save)> _
|
|
Property ShortName As String
|
|
Get
|
|
Return _ShortName
|
|
End Get
|
|
Set(ByVal value As String)
|
|
SetPropertyValue("ShortName", _ShortName, value)
|
|
End Set
|
|
End Property
|
|
Property VATReportSource As VATReport
|
|
Get
|
|
Return _VATReportSource
|
|
End Get
|
|
Set(value As VATReport)
|
|
SetPropertyValue("VATReportSource", _VATReportSource, value)
|
|
End Set
|
|
End Property
|
|
Property VATReportDestination As VATReport
|
|
Get
|
|
Return _VATReportDestination
|
|
End Get
|
|
Set(value As VATReport)
|
|
SetPropertyValue("VATReportDestination", _VATReportDestination, value)
|
|
End Set
|
|
End Property
|
|
|
|
|
|
<NonCloneable> _
|
|
Property ObjectCreated As Date
|
|
Get
|
|
Return _ObjectCreated
|
|
End Get
|
|
Set(value As Date)
|
|
SetPropertyValue("ObjectCreated", _ObjectCreated, value)
|
|
End Set
|
|
End Property
|
|
<NonCloneable> _
|
|
Property UserCreated As User
|
|
Get
|
|
Return _UserCreated
|
|
End Get
|
|
Set(value As User)
|
|
SetPropertyValue("UserCreated", _UserCreated, value)
|
|
End Set
|
|
End Property
|
|
|
|
<Association("VATCompare-VATCompareDetail", GetType(VATCompareDetail)), VisibleInListView(False), VisibleInLookupListView(False)> _
|
|
ReadOnly Property VATCompareDetail As XPCollection(Of VATCompareDetail)
|
|
Get
|
|
Return GetCollection(Of VATCompareDetail)("VATCompareDetail")
|
|
End Get
|
|
End Property
|
|
|
|
<ImmediatePostData(True), DataSourceCriteria("CustomersFrom = '@This.CustomersFrom'")>
|
|
ReadOnly Property VATReportGroup_Source As XPCollection(Of VATReportGroup)
|
|
Get
|
|
If Me.VATReportSource IsNot Nothing Then
|
|
Return Me.VATReportSource.VATReportGroup
|
|
Else
|
|
Return Nothing
|
|
End If
|
|
End Get
|
|
End Property
|
|
<ImmediatePostData(True), DataSourceCriteria("CustomersFrom = '@This.CustomersFrom'")>
|
|
ReadOnly Property VATReportGroup_Destination As XPCollection(Of VATReportGroup)
|
|
Get
|
|
If Me.VATReportDestination IsNot Nothing Then
|
|
Return Me.VATReportDestination.VATReportGroup
|
|
Else
|
|
Return Nothing
|
|
End If
|
|
End Get
|
|
End Property
|
|
'Private _PersistentProperty As String
|
|
'<XafDisplayName("My display name"), ToolTip("My hint message")> _
|
|
'<ModelDefault("EditMask", "(000)-00"), Index(0), VisibleInListView(False)> _
|
|
'<Persistent("DatabaseColumnName"), RuleRequiredField(DefaultContexts.Save)> _
|
|
'Public Property PersistentProperty() As String
|
|
' Get
|
|
' Return _PersistentProperty
|
|
' End Get
|
|
' Set(ByVal value As String)
|
|
' SetPropertyValue("PersistentProperty", _PersistentProperty, value)
|
|
' End Set
|
|
'End Property
|
|
|
|
'<Action(Caption:="My UI Action", ConfirmationMessage:="Are you sure?", ImageName:="Attention", AutoCommit:=True)> _
|
|
'Public Sub ActionMethod()
|
|
' ' Trigger a custom business logic for the current record in the UI (http://documentation.devexpress.com/#Xaf/CustomDocument2619).
|
|
' Me.PersistentProperty = "Paid"
|
|
'End Sub
|
|
End Class
|