1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace Loevgaard\DandomainFoundation\Entity; |
4
|
|
|
|
5
|
|
|
use Doctrine\Common\Collections\ArrayCollection; |
6
|
|
|
use Doctrine\ORM\Mapping as ORM; |
7
|
|
|
use Loevgaard\DandomainFoundation\Entity\Generated\ProductInterface; |
8
|
|
|
use Loevgaard\DandomainFoundation\Entity\Generated\ProductTrait; |
9
|
|
|
|
10
|
|
|
/** |
11
|
|
|
* @ORM\Entity() |
12
|
|
|
* @ORM\Table(name="loevgaard_dandomain_products") |
13
|
|
|
*/ |
14
|
|
|
class Product implements ProductInterface |
15
|
|
|
{ |
16
|
|
|
use ProductTrait; |
17
|
|
|
|
18
|
|
|
/** |
19
|
|
|
* @var int |
20
|
|
|
* |
21
|
|
|
* @ORM\Id |
22
|
|
|
* @ORM\GeneratedValue |
23
|
|
|
* @ORM\Column(type="integer") |
24
|
|
|
**/ |
25
|
|
|
protected $id; |
26
|
|
|
|
27
|
|
|
/** |
28
|
|
|
* @var int |
29
|
|
|
* |
30
|
|
|
* @ORM\Column(type="integer", unique=true) |
31
|
|
|
*/ |
32
|
|
|
protected $externalId; |
33
|
|
|
|
34
|
|
|
/** |
35
|
|
|
* @var string|null |
36
|
|
|
* |
37
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
38
|
|
|
*/ |
39
|
|
|
protected $barCodeNumber; |
40
|
|
|
|
41
|
|
|
/** |
42
|
|
|
* @var array|null |
43
|
|
|
* |
44
|
|
|
* @ORM\Column(nullable=true, type="json") |
45
|
|
|
*/ |
46
|
|
|
protected $categoryIdList; |
47
|
|
|
|
48
|
|
|
/** |
49
|
|
|
* @var string|null |
50
|
|
|
* |
51
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
52
|
|
|
*/ |
53
|
|
|
protected $comments; |
54
|
|
|
|
55
|
|
|
/** |
56
|
|
|
* @var float|null |
57
|
|
|
* |
58
|
|
|
* @ORM\Column(nullable=true, type="decimal", precision=12, scale=2) |
59
|
|
|
*/ |
60
|
|
|
protected $costPrice; |
61
|
|
|
|
62
|
|
|
/** |
63
|
|
|
* @var \DateTimeImmutable|null |
64
|
|
|
* |
65
|
|
|
* @ORM\Column(nullable=true, type="datetime_immutable") |
66
|
|
|
*/ |
67
|
|
|
protected $created; |
68
|
|
|
|
69
|
|
|
/** |
70
|
|
|
* @var string|null |
71
|
|
|
* |
72
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
73
|
|
|
*/ |
74
|
|
|
protected $createdBy; |
75
|
|
|
|
76
|
|
|
/** |
77
|
|
|
* @var int|null |
78
|
|
|
* |
79
|
|
|
* @ORM\Column(nullable=true, type="integer") |
80
|
|
|
*/ |
81
|
|
|
protected $defaultCategoryId; |
82
|
|
|
|
83
|
|
|
/** |
84
|
|
|
* @var array|null |
85
|
|
|
* |
86
|
|
|
* @ORM\Column(nullable=true, type="json") |
87
|
|
|
*/ |
88
|
|
|
protected $disabledVariantIdList; |
89
|
|
|
|
90
|
|
|
/** |
91
|
|
|
* @var string|null |
92
|
|
|
* |
93
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
94
|
|
|
*/ |
95
|
|
|
protected $edbPriserProductNumber; |
96
|
|
|
|
97
|
|
|
/** |
98
|
|
|
* @var string|null |
99
|
|
|
* |
100
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
101
|
|
|
*/ |
102
|
|
|
protected $fileSaleLink; |
103
|
|
|
|
104
|
|
|
/** |
105
|
|
|
* @var string|null |
106
|
|
|
* |
107
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
108
|
|
|
*/ |
109
|
|
|
protected $googleFeedCategory; |
110
|
|
|
|
111
|
|
|
/** |
112
|
|
|
* @var bool|null |
113
|
|
|
* |
114
|
|
|
* @ORM\Column(nullable=true, type="boolean") |
115
|
|
|
*/ |
116
|
|
|
protected $isGiftCertificate; |
117
|
|
|
|
118
|
|
|
/** |
119
|
|
|
* @var bool|null |
120
|
|
|
* |
121
|
|
|
* @ORM\Column(nullable=true, type="boolean") |
122
|
|
|
*/ |
123
|
|
|
protected $isModified; |
124
|
|
|
|
125
|
|
|
/** |
126
|
|
|
* @var bool|null |
127
|
|
|
* |
128
|
|
|
* @ORM\Column(nullable=true, type="boolean") |
129
|
|
|
*/ |
130
|
|
|
protected $isRateVariants; |
131
|
|
|
|
132
|
|
|
/** |
133
|
|
|
* @var bool|null |
134
|
|
|
* |
135
|
|
|
* @ORM\Column(nullable=true, type="boolean") |
136
|
|
|
*/ |
137
|
|
|
protected $isReviewVariants; |
138
|
|
|
|
139
|
|
|
/** |
140
|
|
|
* @var bool|null |
141
|
|
|
* |
142
|
|
|
* @ORM\Column(nullable=true, type="boolean") |
143
|
|
|
*/ |
144
|
|
|
protected $isVariantMaster; |
145
|
|
|
|
146
|
|
|
/** |
147
|
|
|
* @var string|null |
148
|
|
|
* |
149
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
150
|
|
|
*/ |
151
|
|
|
protected $locationNumber; |
152
|
|
|
|
153
|
|
|
/** |
154
|
|
|
* @var array|null |
155
|
|
|
* |
156
|
|
|
* @ORM\Column(nullable=true, type="json") |
157
|
|
|
*/ |
158
|
|
|
protected $manufacturereIdList; |
159
|
|
|
|
160
|
|
|
/** |
161
|
|
|
* @var int|null |
162
|
|
|
* |
163
|
|
|
* @ORM\Column(nullable=true, type="integer") |
164
|
|
|
*/ |
165
|
|
|
protected $maxBuyAmount; |
166
|
|
|
|
167
|
|
|
/** |
168
|
|
|
* @var int|null |
169
|
|
|
* |
170
|
|
|
* @ORM\Column(nullable=true, type="integer") |
171
|
|
|
*/ |
172
|
|
|
protected $minBuyAmount; |
173
|
|
|
|
174
|
|
|
/** |
175
|
|
|
* @var int|null |
176
|
|
|
* |
177
|
|
|
* @ORM\Column(nullable=true, type="integer") |
178
|
|
|
*/ |
179
|
|
|
protected $minBuyAmountB2B; |
180
|
|
|
|
181
|
|
|
/** |
182
|
|
|
* The product number |
183
|
|
|
* |
184
|
|
|
* @var string|null |
185
|
|
|
* |
186
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
187
|
|
|
*/ |
188
|
|
|
protected $number; |
189
|
|
|
|
190
|
|
|
/** |
191
|
|
|
* @var string|null |
192
|
|
|
* |
193
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
194
|
|
|
*/ |
195
|
|
|
protected $picture; |
196
|
|
|
|
197
|
|
|
/** |
198
|
|
|
* @var int|null |
199
|
|
|
* |
200
|
|
|
* @ORM\Column(nullable=true, type="integer") |
201
|
|
|
*/ |
202
|
|
|
protected $salesCount; |
203
|
|
|
|
204
|
|
|
/** |
205
|
|
|
* @var array|null |
206
|
|
|
* |
207
|
|
|
* @ORM\Column(nullable=true, type="json") |
208
|
|
|
*/ |
209
|
|
|
protected $segmentIdList; |
210
|
|
|
|
211
|
|
|
/** |
212
|
|
|
* @var int|null |
213
|
|
|
* |
214
|
|
|
* @ORM\Column(nullable=true, type="integer") |
215
|
|
|
*/ |
216
|
|
|
protected $sortOrder; |
217
|
|
|
|
218
|
|
|
/** |
219
|
|
|
* @var int|null |
220
|
|
|
* |
221
|
|
|
* @ORM\Column(nullable=true, type="integer") |
222
|
|
|
*/ |
223
|
|
|
protected $stockCount; |
224
|
|
|
|
225
|
|
|
/** |
226
|
|
|
* @var int|null |
227
|
|
|
* |
228
|
|
|
* @ORM\Column(nullable=true, type="integer") |
229
|
|
|
*/ |
230
|
|
|
protected $stockLimit; |
231
|
|
|
|
232
|
|
|
/** |
233
|
|
|
* @var int|null |
234
|
|
|
* |
235
|
|
|
* @ORM\Column(nullable=true, type="integer") |
236
|
|
|
*/ |
237
|
|
|
protected $typeId; |
238
|
|
|
|
239
|
|
|
/** |
240
|
|
|
* @var \DateTimeImmutable|null |
241
|
|
|
* |
242
|
|
|
* @ORM\Column(nullable=true, type="datetime_immutable") |
243
|
|
|
*/ |
244
|
|
|
protected $updated; |
245
|
|
|
|
246
|
|
|
/** |
247
|
|
|
* @var string|null |
248
|
|
|
* |
249
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
250
|
|
|
*/ |
251
|
|
|
protected $updatedBy; |
252
|
|
|
|
253
|
|
|
/** |
254
|
|
|
* @var array|null |
255
|
|
|
* |
256
|
|
|
* @ORM\Column(nullable=true, type="json") |
257
|
|
|
*/ |
258
|
|
|
protected $variantGroupIdList; |
259
|
|
|
|
260
|
|
|
/** |
261
|
|
|
* @var array|null |
262
|
|
|
* |
263
|
|
|
* @ORM\Column(nullable=true, type="json") |
264
|
|
|
*/ |
265
|
|
|
protected $variantIdList; |
266
|
|
|
|
267
|
|
|
/** |
268
|
|
|
* @var int|null |
269
|
|
|
* |
270
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
271
|
|
|
*/ |
272
|
|
|
protected $variantMasterId; |
273
|
|
|
|
274
|
|
|
/** |
275
|
|
|
* @var string|null |
276
|
|
|
* |
277
|
|
|
* @ORM\Column(nullable=true, type="string", length=191) |
278
|
|
|
*/ |
279
|
|
|
protected $vendorNumber; |
280
|
|
|
|
281
|
|
|
/** |
282
|
|
|
* @var int|null |
283
|
|
|
* |
284
|
|
|
* @ORM\Column(nullable=true, type="integer") |
285
|
|
|
*/ |
286
|
|
|
protected $weight; |
287
|
|
|
|
288
|
|
|
/** |
289
|
|
|
* @var Category[]|ArrayCollection |
290
|
|
|
*/ |
291
|
|
|
protected $categories; |
292
|
|
|
|
293
|
|
|
/** |
294
|
|
|
* @var Variant[]|ArrayCollection |
295
|
|
|
*/ |
296
|
|
|
protected $disabledVariants; |
297
|
|
|
|
298
|
|
|
/** |
299
|
|
|
* @var Manufacturer[]|ArrayCollection |
300
|
|
|
*/ |
301
|
|
|
protected $manufacturers; |
302
|
|
|
|
303
|
|
|
/** |
304
|
|
|
* @var Medium[]|ArrayCollection |
305
|
|
|
*/ |
306
|
|
|
protected $medias; |
307
|
|
|
|
308
|
|
|
/** |
309
|
|
|
* @var Price[]|ArrayCollection |
310
|
|
|
*/ |
311
|
|
|
protected $prices; |
312
|
|
|
|
313
|
|
|
/** |
314
|
|
|
* @var ProductRelation[]|ArrayCollection |
315
|
|
|
*/ |
316
|
|
|
protected $productRelations; |
317
|
|
|
|
318
|
|
|
/** |
319
|
|
|
* @var ProductType |
320
|
|
|
*/ |
321
|
|
|
protected $productType; |
322
|
|
|
|
323
|
|
|
/** |
324
|
|
|
* @var Segment[]|ArrayCollection |
325
|
|
|
*/ |
326
|
|
|
protected $segments; |
327
|
|
|
|
328
|
|
|
/** |
329
|
|
|
* @var VariantGroup[]|ArrayCollection |
330
|
|
|
*/ |
331
|
|
|
protected $variantGroups; |
332
|
|
|
|
333
|
|
|
/** |
334
|
|
|
* @var Variant[]|ArrayCollection |
335
|
|
|
*/ |
336
|
|
|
protected $variants; |
337
|
|
|
|
338
|
|
|
public function __construct() |
339
|
|
|
{ |
340
|
|
|
$this->categories = new ArrayCollection(); |
341
|
|
|
$this->disabledVariants = new ArrayCollection(); |
342
|
|
|
$this->manufacturers = new ArrayCollection(); |
343
|
|
|
$this->medias = new ArrayCollection(); |
344
|
|
|
$this->prices = new ArrayCollection(); |
345
|
|
|
$this->productRelations = new ArrayCollection(); |
346
|
|
|
$this->segments = new ArrayCollection(); |
347
|
|
|
$this->variants = new ArrayCollection(); |
348
|
|
|
$this->variantGroups = new ArrayCollection(); |
349
|
|
|
} |
350
|
|
|
|
351
|
|
|
/** |
352
|
|
|
* @return int |
353
|
|
|
*/ |
354
|
|
|
public function getId(): int |
355
|
|
|
{ |
356
|
|
|
return (int)$this->id; |
357
|
|
|
} |
358
|
|
|
|
359
|
|
|
/** |
360
|
|
|
* @param int $id |
361
|
|
|
* @return Product |
362
|
|
|
*/ |
363
|
|
|
public function setId(int $id) |
364
|
|
|
{ |
365
|
|
|
$this->id = $id; |
366
|
|
|
return $this; |
367
|
|
|
} |
368
|
|
|
|
369
|
|
|
/** |
370
|
|
|
* @return int |
371
|
|
|
*/ |
372
|
|
|
public function getExternalId(): int |
373
|
|
|
{ |
374
|
|
|
return (int)$this->externalId; |
375
|
|
|
} |
376
|
|
|
|
377
|
|
|
/** |
378
|
|
|
* @param int $externalId |
379
|
|
|
* @return Product |
380
|
|
|
*/ |
381
|
|
|
public function setExternalId(int $externalId) |
382
|
|
|
{ |
383
|
|
|
$this->externalId = $externalId; |
384
|
|
|
return $this; |
385
|
|
|
} |
386
|
|
|
|
387
|
|
|
/** |
388
|
|
|
* @return null|string |
389
|
|
|
*/ |
390
|
|
|
public function getBarCodeNumber() |
391
|
|
|
{ |
392
|
|
|
return $this->barCodeNumber; |
393
|
|
|
} |
394
|
|
|
|
395
|
|
|
/** |
396
|
|
|
* @param null|string $barCodeNumber |
397
|
|
|
* @return Product |
398
|
|
|
*/ |
399
|
|
|
public function setBarCodeNumber($barCodeNumber) |
400
|
|
|
{ |
401
|
|
|
$this->barCodeNumber = $barCodeNumber; |
402
|
|
|
return $this; |
403
|
|
|
} |
404
|
|
|
|
405
|
|
|
/** |
406
|
|
|
* @return array|null |
407
|
|
|
*/ |
408
|
|
|
public function getCategoryIdList() |
409
|
|
|
{ |
410
|
|
|
return $this->categoryIdList; |
411
|
|
|
} |
412
|
|
|
|
413
|
|
|
/** |
414
|
|
|
* @param array|null $categoryIdList |
415
|
|
|
* @return Product |
416
|
|
|
*/ |
417
|
|
|
public function setCategoryIdList($categoryIdList) |
418
|
|
|
{ |
419
|
|
|
$this->categoryIdList = $categoryIdList; |
420
|
|
|
return $this; |
421
|
|
|
} |
422
|
|
|
|
423
|
|
|
/** |
424
|
|
|
* @return null|string |
425
|
|
|
*/ |
426
|
|
|
public function getComments() |
427
|
|
|
{ |
428
|
|
|
return $this->comments; |
429
|
|
|
} |
430
|
|
|
|
431
|
|
|
/** |
432
|
|
|
* @param null|string $comments |
433
|
|
|
* @return Product |
434
|
|
|
*/ |
435
|
|
|
public function setComments($comments) |
436
|
|
|
{ |
437
|
|
|
$this->comments = $comments; |
438
|
|
|
return $this; |
439
|
|
|
} |
440
|
|
|
|
441
|
|
|
/** |
442
|
|
|
* @return float|null |
443
|
|
|
*/ |
444
|
|
|
public function getCostPrice() |
445
|
|
|
{ |
446
|
|
|
return $this->costPrice; |
447
|
|
|
} |
448
|
|
|
|
449
|
|
|
/** |
450
|
|
|
* @param float|null $costPrice |
451
|
|
|
* @return Product |
452
|
|
|
*/ |
453
|
|
|
public function setCostPrice($costPrice) |
454
|
|
|
{ |
455
|
|
|
$this->costPrice = $costPrice; |
456
|
|
|
return $this; |
457
|
|
|
} |
458
|
|
|
|
459
|
|
|
/** |
460
|
|
|
* @return \DateTimeImmutable|null |
461
|
|
|
*/ |
462
|
|
|
public function getCreated() |
463
|
|
|
{ |
464
|
|
|
return $this->created; |
465
|
|
|
} |
466
|
|
|
|
467
|
|
|
/** |
468
|
|
|
* @param \DateTimeImmutable|null $created |
469
|
|
|
* @return Product |
470
|
|
|
*/ |
471
|
|
|
public function setCreated($created) |
472
|
|
|
{ |
473
|
|
|
$this->created = $created; |
474
|
|
|
return $this; |
475
|
|
|
} |
476
|
|
|
|
477
|
|
|
/** |
478
|
|
|
* @return null|string |
479
|
|
|
*/ |
480
|
|
|
public function getCreatedBy() |
481
|
|
|
{ |
482
|
|
|
return $this->createdBy; |
483
|
|
|
} |
484
|
|
|
|
485
|
|
|
/** |
486
|
|
|
* @param null|string $createdBy |
487
|
|
|
* @return Product |
488
|
|
|
*/ |
489
|
|
|
public function setCreatedBy($createdBy) |
490
|
|
|
{ |
491
|
|
|
$this->createdBy = $createdBy; |
492
|
|
|
return $this; |
493
|
|
|
} |
494
|
|
|
|
495
|
|
|
/** |
496
|
|
|
* @return int|null |
497
|
|
|
*/ |
498
|
|
|
public function getDefaultCategoryId() |
499
|
|
|
{ |
500
|
|
|
return $this->defaultCategoryId; |
501
|
|
|
} |
502
|
|
|
|
503
|
|
|
/** |
504
|
|
|
* @param int|null $defaultCategoryId |
505
|
|
|
* @return Product |
506
|
|
|
*/ |
507
|
|
|
public function setDefaultCategoryId($defaultCategoryId) |
508
|
|
|
{ |
509
|
|
|
$this->defaultCategoryId = $defaultCategoryId; |
510
|
|
|
return $this; |
511
|
|
|
} |
512
|
|
|
|
513
|
|
|
/** |
514
|
|
|
* @return array|null |
515
|
|
|
*/ |
516
|
|
|
public function getDisabledVariantIdList() |
517
|
|
|
{ |
518
|
|
|
return $this->disabledVariantIdList; |
519
|
|
|
} |
520
|
|
|
|
521
|
|
|
/** |
522
|
|
|
* @param array|null $disabledVariantIdList |
523
|
|
|
* @return Product |
524
|
|
|
*/ |
525
|
|
|
public function setDisabledVariantIdList($disabledVariantIdList) |
526
|
|
|
{ |
527
|
|
|
$this->disabledVariantIdList = $disabledVariantIdList; |
528
|
|
|
return $this; |
529
|
|
|
} |
530
|
|
|
|
531
|
|
|
/** |
532
|
|
|
* @return null|string |
533
|
|
|
*/ |
534
|
|
|
public function getEdbPriserProductNumber() |
535
|
|
|
{ |
536
|
|
|
return $this->edbPriserProductNumber; |
537
|
|
|
} |
538
|
|
|
|
539
|
|
|
/** |
540
|
|
|
* @param null|string $edbPriserProductNumber |
541
|
|
|
* @return Product |
542
|
|
|
*/ |
543
|
|
|
public function setEdbPriserProductNumber($edbPriserProductNumber) |
544
|
|
|
{ |
545
|
|
|
$this->edbPriserProductNumber = $edbPriserProductNumber; |
546
|
|
|
return $this; |
547
|
|
|
} |
548
|
|
|
|
549
|
|
|
/** |
550
|
|
|
* @return null|string |
551
|
|
|
*/ |
552
|
|
|
public function getFileSaleLink() |
553
|
|
|
{ |
554
|
|
|
return $this->fileSaleLink; |
555
|
|
|
} |
556
|
|
|
|
557
|
|
|
/** |
558
|
|
|
* @param null|string $fileSaleLink |
559
|
|
|
* @return Product |
560
|
|
|
*/ |
561
|
|
|
public function setFileSaleLink($fileSaleLink) |
562
|
|
|
{ |
563
|
|
|
$this->fileSaleLink = $fileSaleLink; |
564
|
|
|
return $this; |
565
|
|
|
} |
566
|
|
|
|
567
|
|
|
/** |
568
|
|
|
* @return null|string |
569
|
|
|
*/ |
570
|
|
|
public function getGoogleFeedCategory() |
571
|
|
|
{ |
572
|
|
|
return $this->googleFeedCategory; |
573
|
|
|
} |
574
|
|
|
|
575
|
|
|
/** |
576
|
|
|
* @param null|string $googleFeedCategory |
577
|
|
|
* @return Product |
578
|
|
|
*/ |
579
|
|
|
public function setGoogleFeedCategory($googleFeedCategory) |
580
|
|
|
{ |
581
|
|
|
$this->googleFeedCategory = $googleFeedCategory; |
582
|
|
|
return $this; |
583
|
|
|
} |
584
|
|
|
|
585
|
|
|
/** |
586
|
|
|
* @return bool|null |
587
|
|
|
*/ |
588
|
|
|
public function getisGiftCertificate() |
589
|
|
|
{ |
590
|
|
|
return $this->isGiftCertificate; |
591
|
|
|
} |
592
|
|
|
|
593
|
|
|
/** |
594
|
|
|
* @param bool|null $isGiftCertificate |
595
|
|
|
* @return Product |
596
|
|
|
*/ |
597
|
|
|
public function setIsGiftCertificate($isGiftCertificate) |
598
|
|
|
{ |
599
|
|
|
$this->isGiftCertificate = $isGiftCertificate; |
600
|
|
|
return $this; |
601
|
|
|
} |
602
|
|
|
|
603
|
|
|
/** |
604
|
|
|
* @return bool|null |
605
|
|
|
*/ |
606
|
|
|
public function getisModified() |
607
|
|
|
{ |
608
|
|
|
return $this->isModified; |
609
|
|
|
} |
610
|
|
|
|
611
|
|
|
/** |
612
|
|
|
* @param bool|null $isModified |
613
|
|
|
* @return Product |
614
|
|
|
*/ |
615
|
|
|
public function setIsModified($isModified) |
616
|
|
|
{ |
617
|
|
|
$this->isModified = $isModified; |
618
|
|
|
return $this; |
619
|
|
|
} |
620
|
|
|
|
621
|
|
|
/** |
622
|
|
|
* @return bool|null |
623
|
|
|
*/ |
624
|
|
|
public function getisRateVariants() |
625
|
|
|
{ |
626
|
|
|
return $this->isRateVariants; |
627
|
|
|
} |
628
|
|
|
|
629
|
|
|
/** |
630
|
|
|
* @param bool|null $isRateVariants |
631
|
|
|
* @return Product |
632
|
|
|
*/ |
633
|
|
|
public function setIsRateVariants($isRateVariants) |
634
|
|
|
{ |
635
|
|
|
$this->isRateVariants = $isRateVariants; |
636
|
|
|
return $this; |
637
|
|
|
} |
638
|
|
|
|
639
|
|
|
/** |
640
|
|
|
* @return bool|null |
641
|
|
|
*/ |
642
|
|
|
public function getisReviewVariants() |
643
|
|
|
{ |
644
|
|
|
return $this->isReviewVariants; |
645
|
|
|
} |
646
|
|
|
|
647
|
|
|
/** |
648
|
|
|
* @param bool|null $isReviewVariants |
649
|
|
|
* @return Product |
650
|
|
|
*/ |
651
|
|
|
public function setIsReviewVariants($isReviewVariants) |
652
|
|
|
{ |
653
|
|
|
$this->isReviewVariants = $isReviewVariants; |
654
|
|
|
return $this; |
655
|
|
|
} |
656
|
|
|
|
657
|
|
|
/** |
658
|
|
|
* @return bool|null |
659
|
|
|
*/ |
660
|
|
|
public function getisVariantMaster() |
661
|
|
|
{ |
662
|
|
|
return $this->isVariantMaster; |
663
|
|
|
} |
664
|
|
|
|
665
|
|
|
/** |
666
|
|
|
* @param bool|null $isVariantMaster |
667
|
|
|
* @return Product |
668
|
|
|
*/ |
669
|
|
|
public function setIsVariantMaster($isVariantMaster) |
670
|
|
|
{ |
671
|
|
|
$this->isVariantMaster = $isVariantMaster; |
672
|
|
|
return $this; |
673
|
|
|
} |
674
|
|
|
|
675
|
|
|
/** |
676
|
|
|
* @return null|string |
677
|
|
|
*/ |
678
|
|
|
public function getLocationNumber() |
679
|
|
|
{ |
680
|
|
|
return $this->locationNumber; |
681
|
|
|
} |
682
|
|
|
|
683
|
|
|
/** |
684
|
|
|
* @param null|string $locationNumber |
685
|
|
|
* @return Product |
686
|
|
|
*/ |
687
|
|
|
public function setLocationNumber($locationNumber) |
688
|
|
|
{ |
689
|
|
|
$this->locationNumber = $locationNumber; |
690
|
|
|
return $this; |
691
|
|
|
} |
692
|
|
|
|
693
|
|
|
/** |
694
|
|
|
* @return array|null |
695
|
|
|
*/ |
696
|
|
|
public function getManufacturereIdList() |
697
|
|
|
{ |
698
|
|
|
return $this->manufacturereIdList; |
699
|
|
|
} |
700
|
|
|
|
701
|
|
|
/** |
702
|
|
|
* @param array|null $manufacturereIdList |
703
|
|
|
* @return Product |
704
|
|
|
*/ |
705
|
|
|
public function setManufacturereIdList($manufacturereIdList) |
706
|
|
|
{ |
707
|
|
|
$this->manufacturereIdList = $manufacturereIdList; |
708
|
|
|
return $this; |
709
|
|
|
} |
710
|
|
|
|
711
|
|
|
/** |
712
|
|
|
* @return int|null |
713
|
|
|
*/ |
714
|
|
|
public function getMaxBuyAmount() |
715
|
|
|
{ |
716
|
|
|
return $this->maxBuyAmount; |
717
|
|
|
} |
718
|
|
|
|
719
|
|
|
/** |
720
|
|
|
* @param int|null $maxBuyAmount |
721
|
|
|
* @return Product |
722
|
|
|
*/ |
723
|
|
|
public function setMaxBuyAmount($maxBuyAmount) |
724
|
|
|
{ |
725
|
|
|
$this->maxBuyAmount = $maxBuyAmount; |
726
|
|
|
return $this; |
727
|
|
|
} |
728
|
|
|
|
729
|
|
|
/** |
730
|
|
|
* @return int|null |
731
|
|
|
*/ |
732
|
|
|
public function getMinBuyAmount() |
733
|
|
|
{ |
734
|
|
|
return $this->minBuyAmount; |
735
|
|
|
} |
736
|
|
|
|
737
|
|
|
/** |
738
|
|
|
* @param int|null $minBuyAmount |
739
|
|
|
* @return Product |
740
|
|
|
*/ |
741
|
|
|
public function setMinBuyAmount($minBuyAmount) |
742
|
|
|
{ |
743
|
|
|
$this->minBuyAmount = $minBuyAmount; |
744
|
|
|
return $this; |
745
|
|
|
} |
746
|
|
|
|
747
|
|
|
/** |
748
|
|
|
* @return int|null |
749
|
|
|
*/ |
750
|
|
|
public function getMinBuyAmountB2B() |
751
|
|
|
{ |
752
|
|
|
return $this->minBuyAmountB2B; |
753
|
|
|
} |
754
|
|
|
|
755
|
|
|
/** |
756
|
|
|
* @param int|null $minBuyAmountB2B |
757
|
|
|
* @return Product |
758
|
|
|
*/ |
759
|
|
|
public function setMinBuyAmountB2B($minBuyAmountB2B) |
760
|
|
|
{ |
761
|
|
|
$this->minBuyAmountB2B = $minBuyAmountB2B; |
762
|
|
|
return $this; |
763
|
|
|
} |
764
|
|
|
|
765
|
|
|
/** |
766
|
|
|
* @return null|string |
767
|
|
|
*/ |
768
|
|
|
public function getNumber() |
769
|
|
|
{ |
770
|
|
|
return $this->number; |
771
|
|
|
} |
772
|
|
|
|
773
|
|
|
/** |
774
|
|
|
* @param null|string $number |
775
|
|
|
* @return Product |
776
|
|
|
*/ |
777
|
|
|
public function setNumber($number) |
778
|
|
|
{ |
779
|
|
|
$this->number = $number; |
780
|
|
|
return $this; |
781
|
|
|
} |
782
|
|
|
|
783
|
|
|
/** |
784
|
|
|
* @return null|string |
785
|
|
|
*/ |
786
|
|
|
public function getPicture() |
787
|
|
|
{ |
788
|
|
|
return $this->picture; |
789
|
|
|
} |
790
|
|
|
|
791
|
|
|
/** |
792
|
|
|
* @param null|string $picture |
793
|
|
|
* @return Product |
794
|
|
|
*/ |
795
|
|
|
public function setPicture($picture) |
796
|
|
|
{ |
797
|
|
|
$this->picture = $picture; |
798
|
|
|
return $this; |
799
|
|
|
} |
800
|
|
|
|
801
|
|
|
/** |
802
|
|
|
* @return int|null |
803
|
|
|
*/ |
804
|
|
|
public function getSalesCount() |
805
|
|
|
{ |
806
|
|
|
return $this->salesCount; |
807
|
|
|
} |
808
|
|
|
|
809
|
|
|
/** |
810
|
|
|
* @param int|null $salesCount |
811
|
|
|
* @return Product |
812
|
|
|
*/ |
813
|
|
|
public function setSalesCount($salesCount) |
814
|
|
|
{ |
815
|
|
|
$this->salesCount = $salesCount; |
816
|
|
|
return $this; |
817
|
|
|
} |
818
|
|
|
|
819
|
|
|
/** |
820
|
|
|
* @return array|null |
821
|
|
|
*/ |
822
|
|
|
public function getSegmentIdList() |
823
|
|
|
{ |
824
|
|
|
return $this->segmentIdList; |
825
|
|
|
} |
826
|
|
|
|
827
|
|
|
/** |
828
|
|
|
* @param array|null $segmentIdList |
829
|
|
|
* @return Product |
830
|
|
|
*/ |
831
|
|
|
public function setSegmentIdList($segmentIdList) |
832
|
|
|
{ |
833
|
|
|
$this->segmentIdList = $segmentIdList; |
834
|
|
|
return $this; |
835
|
|
|
} |
836
|
|
|
|
837
|
|
|
/** |
838
|
|
|
* @return int|null |
839
|
|
|
*/ |
840
|
|
|
public function getSortOrder() |
841
|
|
|
{ |
842
|
|
|
return $this->sortOrder; |
843
|
|
|
} |
844
|
|
|
|
845
|
|
|
/** |
846
|
|
|
* @param int|null $sortOrder |
847
|
|
|
* @return Product |
848
|
|
|
*/ |
849
|
|
|
public function setSortOrder($sortOrder) |
850
|
|
|
{ |
851
|
|
|
$this->sortOrder = $sortOrder; |
852
|
|
|
return $this; |
853
|
|
|
} |
854
|
|
|
|
855
|
|
|
/** |
856
|
|
|
* @return int|null |
857
|
|
|
*/ |
858
|
|
|
public function getStockCount() |
859
|
|
|
{ |
860
|
|
|
return $this->stockCount; |
861
|
|
|
} |
862
|
|
|
|
863
|
|
|
/** |
864
|
|
|
* @param int|null $stockCount |
865
|
|
|
* @return Product |
866
|
|
|
*/ |
867
|
|
|
public function setStockCount($stockCount) |
868
|
|
|
{ |
869
|
|
|
$this->stockCount = $stockCount; |
870
|
|
|
return $this; |
871
|
|
|
} |
872
|
|
|
|
873
|
|
|
/** |
874
|
|
|
* @return int|null |
875
|
|
|
*/ |
876
|
|
|
public function getStockLimit() |
877
|
|
|
{ |
878
|
|
|
return $this->stockLimit; |
879
|
|
|
} |
880
|
|
|
|
881
|
|
|
/** |
882
|
|
|
* @param int|null $stockLimit |
883
|
|
|
* @return Product |
884
|
|
|
*/ |
885
|
|
|
public function setStockLimit($stockLimit) |
886
|
|
|
{ |
887
|
|
|
$this->stockLimit = $stockLimit; |
888
|
|
|
return $this; |
889
|
|
|
} |
890
|
|
|
|
891
|
|
|
/** |
892
|
|
|
* @return int|null |
893
|
|
|
*/ |
894
|
|
|
public function getTypeId() |
895
|
|
|
{ |
896
|
|
|
return $this->typeId; |
897
|
|
|
} |
898
|
|
|
|
899
|
|
|
/** |
900
|
|
|
* @param int|null $typeId |
901
|
|
|
* @return Product |
902
|
|
|
*/ |
903
|
|
|
public function setTypeId($typeId) |
904
|
|
|
{ |
905
|
|
|
$this->typeId = $typeId; |
906
|
|
|
return $this; |
907
|
|
|
} |
908
|
|
|
|
909
|
|
|
/** |
910
|
|
|
* @return \DateTimeImmutable|null |
911
|
|
|
*/ |
912
|
|
|
public function getUpdated() |
913
|
|
|
{ |
914
|
|
|
return $this->updated; |
915
|
|
|
} |
916
|
|
|
|
917
|
|
|
/** |
918
|
|
|
* @param \DateTimeImmutable|null $updated |
919
|
|
|
* @return Product |
920
|
|
|
*/ |
921
|
|
|
public function setUpdated($updated) |
922
|
|
|
{ |
923
|
|
|
$this->updated = $updated; |
924
|
|
|
return $this; |
925
|
|
|
} |
926
|
|
|
|
927
|
|
|
/** |
928
|
|
|
* @return null|string |
929
|
|
|
*/ |
930
|
|
|
public function getUpdatedBy() |
931
|
|
|
{ |
932
|
|
|
return $this->updatedBy; |
933
|
|
|
} |
934
|
|
|
|
935
|
|
|
/** |
936
|
|
|
* @param null|string $updatedBy |
937
|
|
|
* @return Product |
938
|
|
|
*/ |
939
|
|
|
public function setUpdatedBy($updatedBy) |
940
|
|
|
{ |
941
|
|
|
$this->updatedBy = $updatedBy; |
942
|
|
|
return $this; |
943
|
|
|
} |
944
|
|
|
|
945
|
|
|
/** |
946
|
|
|
* @return array|null |
947
|
|
|
*/ |
948
|
|
|
public function getVariantGroupIdList() |
949
|
|
|
{ |
950
|
|
|
return $this->variantGroupIdList; |
951
|
|
|
} |
952
|
|
|
|
953
|
|
|
/** |
954
|
|
|
* @param array|null $variantGroupIdList |
955
|
|
|
* @return Product |
956
|
|
|
*/ |
957
|
|
|
public function setVariantGroupIdList($variantGroupIdList) |
958
|
|
|
{ |
959
|
|
|
$this->variantGroupIdList = $variantGroupIdList; |
960
|
|
|
return $this; |
961
|
|
|
} |
962
|
|
|
|
963
|
|
|
/** |
964
|
|
|
* @return array|null |
965
|
|
|
*/ |
966
|
|
|
public function getVariantIdList() |
967
|
|
|
{ |
968
|
|
|
return $this->variantIdList; |
969
|
|
|
} |
970
|
|
|
|
971
|
|
|
/** |
972
|
|
|
* @param array|null $variantIdList |
973
|
|
|
* @return Product |
974
|
|
|
*/ |
975
|
|
|
public function setVariantIdList($variantIdList) |
976
|
|
|
{ |
977
|
|
|
$this->variantIdList = $variantIdList; |
978
|
|
|
return $this; |
979
|
|
|
} |
980
|
|
|
|
981
|
|
|
/** |
982
|
|
|
* @return int|null |
983
|
|
|
*/ |
984
|
|
|
public function getVariantMasterId() |
985
|
|
|
{ |
986
|
|
|
return $this->variantMasterId; |
987
|
|
|
} |
988
|
|
|
|
989
|
|
|
/** |
990
|
|
|
* @param int|null $variantMasterId |
991
|
|
|
* @return Product |
992
|
|
|
*/ |
993
|
|
|
public function setVariantMasterId($variantMasterId) |
994
|
|
|
{ |
995
|
|
|
$this->variantMasterId = $variantMasterId; |
996
|
|
|
return $this; |
997
|
|
|
} |
998
|
|
|
|
999
|
|
|
/** |
1000
|
|
|
* @return null|string |
1001
|
|
|
*/ |
1002
|
|
|
public function getVendorNumber() |
1003
|
|
|
{ |
1004
|
|
|
return $this->vendorNumber; |
1005
|
|
|
} |
1006
|
|
|
|
1007
|
|
|
/** |
1008
|
|
|
* @param null|string $vendorNumber |
1009
|
|
|
* @return Product |
1010
|
|
|
*/ |
1011
|
|
|
public function setVendorNumber($vendorNumber) |
1012
|
|
|
{ |
1013
|
|
|
$this->vendorNumber = $vendorNumber; |
1014
|
|
|
return $this; |
1015
|
|
|
} |
1016
|
|
|
|
1017
|
|
|
/** |
1018
|
|
|
* @return int|null |
1019
|
|
|
*/ |
1020
|
|
|
public function getWeight() |
1021
|
|
|
{ |
1022
|
|
|
return $this->weight; |
1023
|
|
|
} |
1024
|
|
|
|
1025
|
|
|
/** |
1026
|
|
|
* @param int|null $weight |
1027
|
|
|
* @return Product |
1028
|
|
|
*/ |
1029
|
|
|
public function setWeight($weight) |
1030
|
|
|
{ |
1031
|
|
|
$this->weight = $weight; |
1032
|
|
|
return $this; |
1033
|
|
|
} |
1034
|
|
|
|
1035
|
|
|
/** |
1036
|
|
|
* @return ArrayCollection|Category[] |
1037
|
|
|
*/ |
1038
|
|
|
public function getCategories() |
1039
|
|
|
{ |
1040
|
|
|
return $this->categories; |
1041
|
|
|
} |
1042
|
|
|
|
1043
|
|
|
/** |
1044
|
|
|
* @param ArrayCollection|Category[] $categories |
1045
|
|
|
* @return Product |
1046
|
|
|
*/ |
1047
|
|
|
public function setCategories($categories) |
1048
|
|
|
{ |
1049
|
|
|
$this->categories = $categories; |
1050
|
|
|
return $this; |
1051
|
|
|
} |
1052
|
|
|
|
1053
|
|
|
/** |
1054
|
|
|
* @return ArrayCollection|Variant[] |
1055
|
|
|
*/ |
1056
|
|
|
public function getDisabledVariants() |
1057
|
|
|
{ |
1058
|
|
|
return $this->disabledVariants; |
1059
|
|
|
} |
1060
|
|
|
|
1061
|
|
|
/** |
1062
|
|
|
* @param ArrayCollection|Variant[] $disabledVariants |
1063
|
|
|
* @return Product |
1064
|
|
|
*/ |
1065
|
|
|
public function setDisabledVariants($disabledVariants) |
1066
|
|
|
{ |
1067
|
|
|
$this->disabledVariants = $disabledVariants; |
1068
|
|
|
return $this; |
1069
|
|
|
} |
1070
|
|
|
|
1071
|
|
|
/** |
1072
|
|
|
* @return ArrayCollection|Manufacturer[] |
1073
|
|
|
*/ |
1074
|
|
|
public function getManufacturers() |
1075
|
|
|
{ |
1076
|
|
|
return $this->manufacturers; |
1077
|
|
|
} |
1078
|
|
|
|
1079
|
|
|
/** |
1080
|
|
|
* @param ArrayCollection|Manufacturer[] $manufacturers |
1081
|
|
|
* @return Product |
1082
|
|
|
*/ |
1083
|
|
|
public function setManufacturers($manufacturers) |
1084
|
|
|
{ |
1085
|
|
|
$this->manufacturers = $manufacturers; |
1086
|
|
|
return $this; |
1087
|
|
|
} |
1088
|
|
|
|
1089
|
|
|
/** |
1090
|
|
|
* @return ArrayCollection|Medium[] |
1091
|
|
|
*/ |
1092
|
|
|
public function getMedias() |
1093
|
|
|
{ |
1094
|
|
|
return $this->medias; |
1095
|
|
|
} |
1096
|
|
|
|
1097
|
|
|
/** |
1098
|
|
|
* @param ArrayCollection|Medium[] $medias |
1099
|
|
|
* @return Product |
1100
|
|
|
*/ |
1101
|
|
|
public function setMedias($medias) |
1102
|
|
|
{ |
1103
|
|
|
$this->medias = $medias; |
1104
|
|
|
return $this; |
1105
|
|
|
} |
1106
|
|
|
|
1107
|
|
|
/** |
1108
|
|
|
* @return ArrayCollection|Price[] |
1109
|
|
|
*/ |
1110
|
|
|
public function getPrices() |
1111
|
|
|
{ |
1112
|
|
|
return $this->prices; |
1113
|
|
|
} |
1114
|
|
|
|
1115
|
|
|
/** |
1116
|
|
|
* @param ArrayCollection|Price[] $prices |
1117
|
|
|
* @return Product |
1118
|
|
|
*/ |
1119
|
|
|
public function setPrices($prices) |
1120
|
|
|
{ |
1121
|
|
|
$this->prices = $prices; |
1122
|
|
|
return $this; |
1123
|
|
|
} |
1124
|
|
|
|
1125
|
|
|
/** |
1126
|
|
|
* @return ArrayCollection|ProductRelation[] |
1127
|
|
|
*/ |
1128
|
|
|
public function getProductRelations() |
1129
|
|
|
{ |
1130
|
|
|
return $this->productRelations; |
1131
|
|
|
} |
1132
|
|
|
|
1133
|
|
|
/** |
1134
|
|
|
* @param ArrayCollection|ProductRelation[] $productRelations |
1135
|
|
|
* @return Product |
1136
|
|
|
*/ |
1137
|
|
|
public function setProductRelations($productRelations) |
1138
|
|
|
{ |
1139
|
|
|
$this->productRelations = $productRelations; |
1140
|
|
|
return $this; |
1141
|
|
|
} |
1142
|
|
|
|
1143
|
|
|
/** |
1144
|
|
|
* @return ProductType |
1145
|
|
|
*/ |
1146
|
|
|
public function getProductType(): ProductType |
1147
|
|
|
{ |
1148
|
|
|
return $this->productType; |
1149
|
|
|
} |
1150
|
|
|
|
1151
|
|
|
/** |
1152
|
|
|
* @param ProductType $productType |
1153
|
|
|
* @return Product |
1154
|
|
|
*/ |
1155
|
|
|
public function setProductType(ProductType $productType) |
1156
|
|
|
{ |
1157
|
|
|
$this->productType = $productType; |
1158
|
|
|
return $this; |
1159
|
|
|
} |
1160
|
|
|
|
1161
|
|
|
/** |
1162
|
|
|
* @return ArrayCollection|Segment[] |
1163
|
|
|
*/ |
1164
|
|
|
public function getSegments() |
1165
|
|
|
{ |
1166
|
|
|
return $this->segments; |
1167
|
|
|
} |
1168
|
|
|
|
1169
|
|
|
/** |
1170
|
|
|
* @param ArrayCollection|Segment[] $segments |
1171
|
|
|
* @return Product |
1172
|
|
|
*/ |
1173
|
|
|
public function setSegments($segments) |
1174
|
|
|
{ |
1175
|
|
|
$this->segments = $segments; |
1176
|
|
|
return $this; |
1177
|
|
|
} |
1178
|
|
|
|
1179
|
|
|
/** |
1180
|
|
|
* @return ArrayCollection|VariantGroup[] |
1181
|
|
|
*/ |
1182
|
|
|
public function getVariantGroups() |
1183
|
|
|
{ |
1184
|
|
|
return $this->variantGroups; |
1185
|
|
|
} |
1186
|
|
|
|
1187
|
|
|
/** |
1188
|
|
|
* @param ArrayCollection|VariantGroup[] $variantGroups |
1189
|
|
|
* @return Product |
1190
|
|
|
*/ |
1191
|
|
|
public function setVariantGroups($variantGroups) |
1192
|
|
|
{ |
1193
|
|
|
$this->variantGroups = $variantGroups; |
1194
|
|
|
return $this; |
1195
|
|
|
} |
1196
|
|
|
|
1197
|
|
|
/** |
1198
|
|
|
* @return ArrayCollection|Variant[] |
1199
|
|
|
*/ |
1200
|
|
|
public function getVariants() |
1201
|
|
|
{ |
1202
|
|
|
return $this->variants; |
1203
|
|
|
} |
1204
|
|
|
|
1205
|
|
|
/** |
1206
|
|
|
* @param ArrayCollection|Variant[] $variants |
1207
|
|
|
* @return Product |
1208
|
|
|
*/ |
1209
|
|
|
public function setVariants($variants) |
1210
|
|
|
{ |
1211
|
|
|
$this->variants = $variants; |
1212
|
|
|
return $this; |
1213
|
|
|
} |
1214
|
|
|
} |
1215
|
|
|
|