/** * Get messages * * @return array */ public function getMessages() { $list = parent::getMessages(); if (!empty($this->getOptions()->commonData['qdProcessed'])) { $list[] = array('text' => static::t('Products processed: {{count}}', array('count' => $this->getOptions()->commonData['qdProcessed']))); } return $list; }
/** * Sort steps * * @param \XLite\Logic\Import\Step\AStep $a First * @param \XLite\Logic\Import\Step\AStep $b Second * * @return integer */ public function sortSteps(\XLite\Logic\Import\Step\AStep $a, \XLite\Logic\Import\Step\AStep $b) { $aw = $a->getWeight(); $bw = $b->getWeight(); if ($aw > $bw) { $result = 1; } elseif ($aw < $bw) { $result = -1; } else { $result = 0; } return $result; }
/** * Check valid state of step * * @return boolean */ public function isValid() { return parent::isValid() && $this->getProcessor() && $this->getProcessor()->isValid(); }