Skip to content

Commit 8625726

Browse files
ENGCOM-3000: Update shipment collection to unserialize \packages\ attribute after load #17679
- Merge Pull Request #17679 from dnsv/magento2:shipment-collection-unserialize - Merged commits: 1. 8f4efee
2 parents 50a4da0 + 8f4efee commit 8625726

File tree

1 file changed

+5
-3
lines changed
  • app/code/Magento/Sales/Model/ResourceModel/Order/Shipment

1 file changed

+5
-3
lines changed

app/code/Magento/Sales/Model/ResourceModel/Order/Shipment/Collection.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,14 +57,16 @@ protected function _construct()
5757
}
5858

5959
/**
60-
* Used to emulate after load functionality for each item without loading them
60+
* Unserialize packages in each item
6161
*
6262
* @return $this
6363
*/
6464
protected function _afterLoad()
6565
{
66-
$this->walk('afterLoad');
66+
foreach ($this->_items as $item) {
67+
$this->getResource()->unserializeFields($item);
68+
}
6769

68-
return $this;
70+
return parent::_afterLoad();
6971
}
7072
}

0 commit comments

Comments
 (0)