Skip to content

Commit 7c6ecc3

Browse files
committed
MAGETWO-70532: [GitHub] REST API Missing Product_Option values for Order Items in salesOrderManagementV1 and salesOrderItemRepositoryV1 #9326
- Added product options merger
1 parent b3a1cc6 commit 7c6ecc3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

app/code/Magento/Sales/Model/Order/ItemRepository.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,9 @@ public function save(OrderItemInterface $entity)
168168
{
169169
if ($entity->getProductOption()) {
170170
$request = $this->getBuyRequest($entity);
171-
$entity->setProductOptions(['info_buyRequest' => $request->toArray()]);
171+
$productOptions = $entity->getProductOptions();
172+
$productOptions['info_buyRequest'] = $request->toArray();
173+
$entity->setProductOptions($productOptions);
172174
}
173175

174176
$this->metadata->getMapper()->save($entity);

0 commit comments

Comments
 (0)