1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
| Public Class PromoDetailOwn
Inherits PromoDetail
Public Property Department As Department
Public Property Brand As Brand
Public Property Seasons As List(Of Season)
Public Property SeasonsRange As String
'Public Sub New(id As Integer, buyingDept As BuyingDept, comment As String, note As String, priceReduction As Boolean, percentage As Decimal, encoded As Boolean, dept As Department, brand As Brand)
Public Sub New(id As Integer, buyingDept As BuyingDept, desc As String, note As String, percentage As Decimal, listtype As String, dept As Department, brand As Brand, percentType As PercentType, encoded As Boolean, attachement As Attachment, isduplicate As Boolean, isnew As Boolean)
'MyBase.New(id, buyingDept, comment, note, priceReduction, percentage, encoded)
MyBase.New(id, buyingDept, desc, note, percentage, listtype, percentType, encoded, attachement, isnew)
Me.Department = dept
Me.Brand = brand
Me.SeasonsRange = ""
Me.Seasons = New List(Of Season)
Me.IsDuplicate = isduplicate
End Sub
Public Sub New(id As Integer, buyingDept As BuyingDept, desc As String, note As String, percentage As Decimal, listtype As String, dept As Department, brand As Brand, percentType As PercentType, encoded As Boolean, isnew As Boolean)
'MyBase.New(id, buyingDept, comment, note, priceReduction, percentage, encoded)
MyBase.New(id, buyingDept, desc, note, percentage, listtype, percentType, encoded, isnew)
Me.Department = dept
Me.Brand = brand
Me.SeasonsRange = ""
Me.Seasons = New List(Of Season)
End Sub
End Class
Public Class PromoDetail
Implements DtoBase
Public Property Isnew As Boolean Implements DtoBase.Isnew
Public Property Id As Integer 'DTD_ID pour demo et DTO_ID pour ferme
Public Property BuyingDepartment As BuyingDept
Public Property Description As String
Public Property Note As String
'Public Property PriceReduction As Boolean
Public Property Percentage As Decimal
Public Property PercentType As PercentType
Public Property Encoded As Boolean
Public Property Attachment As Attachment
Public Property IsDuplicate As Boolean
Public Property ErrorText As String
Private _listType As String
Public ReadOnly Property ListType As String
Get
Return _listType
End Get
End Property
Private _productCount As Integer
Public ReadOnly Property ProductCount As Integer
Get
Return _productCount
End Get
End Property
Private _products As List(Of Product)
Public Property Products As List(Of Product)
Get
Return _products
End Get
Set(value As List(Of Product))
_products = value
If value.Count > 0 Then
_listType = "INC"
_productCount = value.Count
End If
End Set
End Property
Private _productsOut As List(Of Product)
Public Property ProductsOut As List(Of Product)
Get
Return _productsOut
End Get
Set(value As List(Of Product))
_productsOut = value
If value.Count > 0 Then
_listType = "EXC"
_productCount = value.Count
End If
End Set
End Property
'Public Sub New(id As Integer, buyingDept As BuyingDept, comment As String, note As String, priceReduction As Boolean, percentage As Decimal, encoded As Boolean)
Public Sub New(id As Integer, buyingDept As BuyingDept, desc As String, note As String, percentage As Decimal, listtype As String, percentType As PercentType, encoded As Boolean, attachement As Attachment, isnew As Boolean)
Me.Id = id
Me.BuyingDepartment = buyingDept
Me.Description = desc
Me.Note = note
'Me.PriceReduction = priceReduction
Me.Percentage = percentage
Me.PercentType = percentType
Me.Encoded = encoded
Me._listType = listtype
Me.Attachment = attachement
Me.Isnew = isnew
End Sub
Public Sub New(id As Integer, buyingDept As BuyingDept, desc As String, note As String, percentage As Decimal, listtype As String, percentType As PercentType, encoded As Boolean, isnew As Boolean)
Me.Id = id
Me.BuyingDepartment = buyingDept
Me.Description = desc
Me.Note = note
'Me.PriceReduction = priceReduction
Me.Percentage = percentage
Me.PercentType = percentType
Me.Encoded = encoded
Me._listType = listtype
Me.Isnew = isnew
End Sub
End Class |