@@ 188-195 (lines=8) @@ | ||
185 | $products[$i]['currency']['DKK']['price_incl_vat'] = $product->getDetails()->getPriceIncludingVat(); |
|
186 | $products[$i]['currency']['DKK']['before_price'] = $product->getDetails()->getBeforePrice(); |
|
187 | $products[$i]['currency']['DKK']['before_price_incl_vat'] = $product->getDetails()->getBeforePriceIncludingVat(); |
|
188 | if ($currencies && $currencies->count() > 0) { |
|
189 | foreach ($currencies as $currency) { |
|
190 | $products[$i]['currency'][$currency->getType()->getIsoCode()]['price'] = $product->getDetails()->getPriceInCurrency($currency); |
|
191 | $products[$i]['currency'][$currency->getType()->getIsoCode()]['price_incl_vat'] = $product->getDetails()->getPriceIncludingVatInCurrency($currency); |
|
192 | $products[$i]['currency'][$currency->getType()->getIsoCode()]['before_price'] = $product->getDetails()->getBeforePriceInCurrency($currency); |
|
193 | $products[$i]['currency'][$currency->getType()->getIsoCode()]['before_price_incl_vat'] = $product->getDetails()->getBeforePriceIncludingVatInCurrency($currency); |
|
194 | } |
|
195 | } |
|
196 | ||
197 | if (!$product->get('has_variation') and is_object($product->getStock()) and strtolower(get_class($product->getStock())) == "stock") { |
|
198 | $products[$i]['stock_status'] = $product->getStock()->get(); |
@@ 285-292 (lines=8) @@ | ||
282 | $products[$key]['currency']['DKK']['before_price'] = $p->getDetails()->getBeforePrice()->getAsIso(2); |
|
283 | $products[$key]['currency']['DKK']['before_price_incl_vat'] = $p->getDetails()->getBeforePriceIncludingVat()->getAsIso(2); |
|
284 | ||
285 | if ($currencies && $currencies->count() > 0) { |
|
286 | foreach ($currencies as $currency) { |
|
287 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['price'] = $p->getDetails()->getPriceInCurrency($currency); |
|
288 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['price_incl_vat'] = $p->getDetails()->getPriceIncludingVatInCurrency($currency); |
|
289 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['before_price'] = $p->getDetails()->getBeforePriceInCurrency($currency); |
|
290 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['before_price_incl_vat'] = $p->getDetails()->getBeforePriceIncludingVatInCurrency($currency); |
|
291 | } |
|
292 | } |
|
293 | ||
294 | $products[$key]['pictures'] = $this->getProductPictures($p); |
|
295 |
@@ 705-712 (lines=8) @@ | ||
702 | ||
703 | $products[$key]['pictures'] = $product->getPictures(); |
|
704 | ||
705 | if ($currencies && $currencies->count() > 0) { |
|
706 | foreach ($currencies as $currency) { |
|
707 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['price'] = $product->getDetails()->getPriceInCurrency($currency); |
|
708 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['price_incl_vat'] = $product->getDetails()->getPriceIncludingVatInCurrency($currency); |
|
709 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['before_price'] = $product->getDetails()->getBeforePriceInCurrency($currency); |
|
710 | $products[$key]['currency'][$currency->getType()->getIsoCode()]['before_price_incl_vat'] = $product->getDetails()->getBeforePriceIncludingVatInCurrency($currency); |
|
711 | } |
|
712 | } |
|
713 | ||
714 | if (!$product->hasVariation() and is_object($product->getStock())) { |
|
715 | $products[$key]['stock_status'] = $product->getStock()->get(); |