src/Eccube/Service/PurchaseFlow/Processor/SaleLimitMultipleValidator.php 1 location
|
@@ 48-53 (lines=6) @@
|
| 45 |
|
public function validate(ItemHolderInterface $itemHolder, PurchaseContext $context) |
| 46 |
|
{ |
| 47 |
|
$OrderItemsByProductClass = []; |
| 48 |
|
foreach ($itemHolder->getItems() as $Item) { |
| 49 |
|
if ($Item->isProduct()) { |
| 50 |
|
$id = $Item->getProductClass()->getId(); |
| 51 |
|
$OrderItemsByProductClass[$id][] = $Item; |
| 52 |
|
} |
| 53 |
|
} |
| 54 |
|
|
| 55 |
|
foreach ($OrderItemsByProductClass as $id => $Items) { |
| 56 |
|
$ProductClass = $this->productClassRepository->find($id); |
src/Eccube/Service/PurchaseFlow/Processor/StockMultipleValidator.php 1 location
|
@@ 48-53 (lines=6) @@
|
| 45 |
|
public function validate(ItemHolderInterface $itemHolder, PurchaseContext $context) |
| 46 |
|
{ |
| 47 |
|
$OrderItemsByProductClass = []; |
| 48 |
|
foreach ($itemHolder->getItems() as $Item) { |
| 49 |
|
if ($Item->isProduct()) { |
| 50 |
|
$id = $Item->getProductClass()->getId(); |
| 51 |
|
$OrderItemsByProductClass[$id][] = $Item; |
| 52 |
|
} |
| 53 |
|
} |
| 54 |
|
|
| 55 |
|
foreach ($OrderItemsByProductClass as $id => $Items) { |
| 56 |
|
$ProductClass = $this->productClassRepository->find($id); |