mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2024-11-15 04:27:14 +01:00
Improvements for BogxProductConfigurator (Shopware6)
This commit is contained in:
parent
5b33e09021
commit
36c751d317
@ -3825,16 +3825,16 @@ class Shopimporter_Shopware6 extends ShopimporterBase
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
$bogxdata = $lineItem['attributes']['payload']['bogxProductConfigurator'];
|
$bogxdata = $lineItem['attributes']['payload']['bogxProductConfigurator'];
|
||||||
file_put_contents("/var/www/bogx", print_r($bogxdata, true));
|
file_put_contents("/var/www/bogx", print_r($lineItem['attributes'], true));
|
||||||
$textlines = [];
|
$textlines = [];
|
||||||
|
|
||||||
if (isset($bogxdata['ordercode']))
|
if (isset($bogxdata['ordercode']))
|
||||||
$textlines[] = "Order-Code: ${bogxdata['ordercode']}";
|
$textlines[] = "Order-Code: ${bogxdata['ordercode']}";
|
||||||
else
|
|
||||||
$textlines[] = "Produkt-Nr: ${bogxdata['articleordernumber']}";
|
|
||||||
|
|
||||||
foreach ($bogxdata['optionsGroups'] as $bogxposition) {
|
foreach ($bogxdata['optionsGroups'] as $bogxposition) {
|
||||||
$dt = $bogxposition['datatype'];
|
$dt = $bogxposition['datatype'];
|
||||||
|
if ($dt == 'quantity_total')
|
||||||
|
continue;
|
||||||
if (is_array($bogxposition['valueID']) && is_array($bogxposition['title']))
|
if (is_array($bogxposition['valueID']) && is_array($bogxposition['title']))
|
||||||
{
|
{
|
||||||
foreach ($bogxposition['valueID'] as $valueID) {
|
foreach ($bogxposition['valueID'] as $valueID) {
|
||||||
@ -3854,6 +3854,13 @@ class Shopimporter_Shopware6 extends ShopimporterBase
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!empty($bogxdata['shippingtime'])) {
|
||||||
|
$textlines[] = $bogxdata['shippingtime'];
|
||||||
|
}
|
||||||
|
|
||||||
$product['options'] .= join("\n", $textlines);
|
$product['options'] .= join("\n", $textlines);
|
||||||
|
$product['price'] = $bogxdata['unitySurcharge'];
|
||||||
|
$product['price_netto'] = $bogxdata['unitySurchargeNetto'];
|
||||||
|
$product['quantity'] = $bogxdata['totalQuantity'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user