Example #1
0
 /**
  * Process
  *
  * @return void
  */
 public function process()
 {
     if ($this->preValidateAction()) {
         parent::process();
         $items = \XLite\Core\Database::getRepo('XLite\\Model\\OrderItem')->search($this->getSearchCondition());
         foreach ($items as $item) {
             $item->calculate();
         }
     } else {
         \XLite\Core\TopMessage::getInstance()->addError(static::t('All items cannot be removed from the order.'));
         $this->setActionError();
     }
 }