Add ProductPrice import
modifié: core/lib/Thelia/ImportExport/Import/Type/ProductPriceImport.php
This commit is contained in:
@@ -86,12 +86,15 @@ class ProductPriceImport extends ImportHandler
|
|||||||
}
|
}
|
||||||
|
|
||||||
$price = ProductPriceQuery::create()
|
$price = ProductPriceQuery::create()
|
||||||
->filterByProductSaleElements($obj)
|
->filterByProductSaleElementsId($obj->getId())
|
||||||
->findOneByCurrencyId($currency->getId());
|
->findOneByCurrencyId($currency->getId())
|
||||||
|
;
|
||||||
|
|
||||||
if ($price === null) {
|
if ($price === null) {
|
||||||
$price = new ProductPrice();
|
$price = new ProductPrice();
|
||||||
$price->setProductSaleElements($obj)
|
|
||||||
|
$price
|
||||||
|
->setProductSaleElements($obj)
|
||||||
->setCurrency($currency)
|
->setCurrency($currency)
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
@@ -109,4 +112,4 @@ class ProductPriceImport extends ImportHandler
|
|||||||
return $errors;
|
return $errors;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user