1 | <?php |
||
14 | class Subscription { |
||
15 | |||
16 | /** |
||
17 | * @var string |
||
18 | * |
||
19 | * @ORM\Column(name="full_name", type="string", length=250, options={"default":""}, nullable=false) |
||
20 | */ |
||
21 | private $fullName = ''; |
||
22 | |||
23 | /** |
||
24 | * @var string |
||
25 | * |
||
26 | * @ORM\Column(name="email", type="string", length=250, options={"default":""}, nullable=false) |
||
27 | */ |
||
28 | private $email = ''; |
||
29 | |||
30 | /** |
||
31 | * @var \DateTime |
||
32 | * |
||
33 | * @ORM\Column(name="export", type="datetime", nullable=true) |
||
34 | */ |
||
35 | private $export; |
||
36 | |||
37 | /** |
||
38 | * @var \DateTime |
||
39 | * |
||
40 | * @ORM\Column(name="backup", type="datetime", nullable=true) |
||
41 | */ |
||
42 | private $backup; |
||
43 | |||
44 | /** |
||
45 | * @var integer |
||
46 | * |
||
47 | * @ORM\Column(name="status", type="smallint", options={"default":0}, nullable=true) |
||
48 | */ |
||
49 | private $status = 0; |
||
50 | |||
51 | /** |
||
52 | * @var string |
||
53 | * |
||
54 | * @ORM\Column(name="confirmationCode", type="blob", length=16, nullable=true) |
||
55 | */ |
||
56 | private $confirmationCode; |
||
57 | |||
58 | /** |
||
59 | * @var integer |
||
60 | * |
||
61 | * @ORM\Column(name="id", type="integer") |
||
62 | * @ORM\Id |
||
63 | * @ORM\GeneratedValue(strategy="IDENTITY") |
||
64 | */ |
||
65 | private $id; |
||
66 | |||
67 | /** |
||
68 | * @ORM\ManyToOne(targetEntity="Address") |
||
69 | * @ORM\JoinColumn(name="address_id", referencedColumnName="id") |
||
70 | */ |
||
71 | private $address; |
||
72 | |||
73 | /** |
||
74 | * @var string |
||
75 | * |
||
76 | * @ORM\Column(name="tracking", type="string", length=50, nullable=true) |
||
77 | */ |
||
78 | private $tracking; |
||
79 | |||
80 | /** |
||
81 | * @var string |
||
82 | * |
||
83 | * @ORM\Column(name="campaign_code", type="string", length=50, nullable=true) |
||
84 | */ |
||
85 | private $campaignCode; |
||
86 | |||
87 | /** |
||
88 | * @var \DateTime |
||
89 | * @Gedmo\Timestampable(on="create") |
||
90 | * @ORM\Column(type="datetime") |
||
91 | */ |
||
92 | private $createdAt; |
||
93 | |||
94 | const STATUS_NEW = 0; |
||
95 | const STATUS_CONFIRMED = 1; |
||
96 | const STATUS_MODERATION = 2; |
||
97 | |||
98 | /** |
||
99 | * Set name |
||
100 | * |
||
101 | * @param string $fullName |
||
102 | * @return self |
||
103 | */ |
||
104 | public function setFullName( $fullName ) { |
||
109 | |||
110 | /** |
||
111 | * Get name |
||
112 | * |
||
113 | * @return string |
||
114 | */ |
||
115 | public function getFullName() { |
||
118 | |||
119 | /** |
||
120 | * Set email |
||
121 | * |
||
122 | * @param string $email |
||
123 | * @return self |
||
124 | */ |
||
125 | public function setEmail( $email ) { |
||
130 | |||
131 | /** |
||
132 | * Get email |
||
133 | * |
||
134 | * @return string |
||
135 | */ |
||
136 | public function getEmail() { |
||
139 | |||
140 | /** |
||
141 | * Set export |
||
142 | * |
||
143 | * @param \DateTime $export |
||
144 | * @return self |
||
145 | */ |
||
146 | public function setExport( $export ) { |
||
151 | |||
152 | /** |
||
153 | * Get export |
||
154 | * |
||
155 | * @return \DateTime |
||
156 | */ |
||
157 | public function getExport() { |
||
160 | |||
161 | /** |
||
162 | * Set backup |
||
163 | * |
||
164 | * @param \DateTime $backup |
||
165 | * @return self |
||
166 | */ |
||
167 | public function setBackup( $backup ) { |
||
172 | |||
173 | /** |
||
174 | * Get backup |
||
175 | * |
||
176 | * @return \DateTime |
||
177 | */ |
||
178 | public function getBackup() { |
||
181 | |||
182 | /** |
||
183 | * Set status |
||
184 | * |
||
185 | * @param integer $status |
||
186 | * @return self |
||
187 | */ |
||
188 | public function setStatus( $status ) { |
||
193 | |||
194 | /** |
||
195 | * Get status |
||
196 | * |
||
197 | * @return integer |
||
198 | */ |
||
199 | public function getStatus() { |
||
202 | |||
203 | /** |
||
204 | * Set guid |
||
205 | * |
||
206 | 1 | * @param string $confirmationCode |
|
207 | 1 | * @return self |
|
208 | */ |
||
209 | 1 | public function setConfirmationCode( $confirmationCode ) { |
|
214 | |||
215 | /** |
||
216 | * Get guid |
||
217 | 1 | * |
|
218 | 1 | * @return string |
|
219 | */ |
||
220 | public function getConfirmationCode() { |
||
223 | |||
224 | /** |
||
225 | * Get id |
||
226 | * |
||
227 | * @return integer |
||
228 | */ |
||
229 | public function getId() { |
||
232 | |||
233 | /** |
||
234 | * @return Address |
||
235 | */ |
||
236 | public function getAddress() { |
||
239 | |||
240 | /** |
||
241 | * @return \DateTime |
||
242 | */ |
||
243 | public function getCreatedAt() { |
||
246 | |||
247 | /** |
||
248 | * @param \DateTime $createdAt |
||
249 | * @return self |
||
250 | */ |
||
251 | public function setCreatedAt( $createdAt ) { |
||
255 | |||
256 | /** |
||
257 | * @return string |
||
258 | */ |
||
259 | public function getTracking() { |
||
262 | |||
263 | /** |
||
264 | * @param string $tracking |
||
265 | */ |
||
266 | public function setTracking( $tracking ) { |
||
269 | |||
270 | /** |
||
271 | * @param Address $address |
||
272 | */ |
||
273 | public function setAddress( $address ) { |
||
276 | |||
277 | public function isUnconfirmed() { |
||
280 | |||
281 | public function getHexConfirmationCode() { |
||
284 | 1 | ||
285 | public function setHexConfirmationCode( $confirmationCode ) { |
||
288 | |||
289 | public function setCampaignCode( string $campaignCode ) { |
||
293 | |||
294 | public function getCampaignCode(): string { |
||
297 | |||
298 | } |
||
299 |