/** * Defines the common data for JS * * @return array */ public function defineCommonJSData() { return array_merge(parent::defineCommonJSData(), array('product_id' => $this->getProductId(), 'category_id' => $this->getCategoryId())); }
/** * Check if redirect to clean URL is needed * * @return boolean */ protected function isRedirectToCleanURLNeeded() { return parent::isRedirectToCleanURLNeeded() && $this->getCategory()->getParent(); }