- /**
- * Trigger collect totals after loading, if required
- *
- * @return $this
- */
- protected function _afterLoad()
- {
- // collect totals and save me, if required
- if (1 == $this->getTriggerRecollect()) {
- $this->collectTotals()
- ->setTriggerRecollect(0)
- ->save();
- }
- return parent::_afterLoad();
- }