-
Notifications
You must be signed in to change notification settings - Fork 1
/
Customer.vb
78 lines (73 loc) · 2.48 KB
/
Customer.vb
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
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated from a template.
'
' Manual changes to this file may cause unexpected behavior in your application.
' Manual changes to this file will be overwritten if the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Imports Microsoft.VisualBasic
Imports System
Imports System.Collections.Generic
Imports System.ComponentModel.DataAnnotations
Namespace E4425.Models
Partial Public Class Customer
Private privateCustomerId As Integer
Public Property CustomerId() As Integer
Get
Return privateCustomerId
End Get
Set(ByVal value As Integer)
privateCustomerId = value
End Set
End Property
Private privateCustomerName As String
<Required(ErrorMessage:="Customer cannot be empty")> _
Public Property CustomerName() As String
Get
Return privateCustomerName
End Get
Set(ByVal value As String)
privateCustomerName = value
End Set
End Property
Private privateCountryId? As Integer
<Required(ErrorMessage:="Country should be chosen")>
Public Property CountryId() As Integer?
Get
Return privateCountryId
End Get
Set(ByVal value As Integer?)
privateCountryId = value
End Set
End Property
Private privateCityId? As Integer
<Required(ErrorMessage:="City should be chosen")>
Public Property CityId() As Integer?
Get
Return privateCityId
End Get
Set(ByVal value As Integer?)
privateCityId = value
End Set
End Property
Private privateCity As City
Public Overridable Property City() As City
Get
Return privateCity
End Get
Set(ByVal value As City)
privateCity = value
End Set
End Property
Private privateCountry As Country
Public Overridable Property Country() As Country
Get
Return privateCountry
End Get
Set(ByVal value As Country)
privateCountry = value
End Set
End Property
End Class
End Namespace