コード例 #1
0
ファイル: Price17.php プロジェクト: jokusafet/MagentoSource
 protected function _getPriceExpression($filter, $select, $replaceAlias = true)
 {
     if (Mage::helper('amshopby')->landingNewFilter()) {
         $replaceAlias = false;
     }
     return parent::_getPriceExpression($filter, $select, $replaceAlias);
 }
コード例 #2
0
ファイル: Price17.php プロジェクト: bigtailbear14/rosstheme
 protected function _getPriceExpression($filter, $select, $replaceAlias = true)
 {
     if ($this->_dataHelper->landingNewFilter()) {
         $replaceAlias = false;
     }
     return parent::_getPriceExpression($filter, $select, $replaceAlias);
 }
コード例 #3
0
ファイル: Price.php プロジェクト: santhosh400/ecart
 /**
  * Get comparing value sql part
  *
  * @param float $price
  * @param Mage_Catalog_Model_Layer_Filter_Price $filter
  * @param bool $decrease
  * @return float
  */
 protected function _getComparingValue($price, $filter, $decrease = true)
 {
     if (Mage::helper('catalin_seo')->isEnabled() && Mage::helper('catalin_seo')->isPriceSliderEnabled()) {
         $currencyRate = $filter->getLayer()->getProductCollection()->getCurrencyRate();
         return $price / $currencyRate;
     }
     return parent::_getComparingValue($price, $filter, $decrease);
 }
コード例 #4
0
ファイル: Price.php プロジェクト: CE-Webmaster/CE-Hub
 protected function _getPriceExpression($filter, $select, $replaceAlias = true)
 {
     //    	if (Mage::helper('amlanding')->newFilterActive()) {
     //    		$replaceAlias = false;
     //    	}
     $replaceAlias = false;
     return parent::_getPriceExpression($filter, $select, $replaceAlias);
 }
コード例 #5
0
ファイル: Price.php プロジェクト: kozinthetdbp/shopmyar
 /**
  * Apply price range filter to product collection
  *
  * @param Mage_Catalog_Model_Layer_Filter_Price $filter
  * @return Mage_Catalog_Model_Resource_Layer_Filter_Price
  */
 public function applyPriceRange($filter)
 {
     if (!Mage::helper('searchanise/ApiSe')->checkSearchaniseResult(true)) {
         return parent::applyPriceRange($filter);
     }
     $collection = $filter->getLayer()->getProductCollection();
     if (!method_exists($collection, 'checkSearchaniseResult') || !$collection->checkSearchaniseResult()) {
         return parent::applyPriceRange($filter);
     }
     // Disable internal price filter.
     return $this;
 }
コード例 #6
0
 /**
  * Apply attribute filter to product collection
  *
  * @deprecated since 1.7.0.0
  * @param Mage_Catalog_Model_Layer_Filter_Price $filter
  * @param int $range
  * @param int $index    the range factor
  * @return Mage_Catalog_Model_Resource_Layer_Filter_Price
  */
 public function applyFilterToCollection($filter, $range, $index)
 {
     if (!Mage::helper('catalogfilter')->priceIsSlider()) {
         return parent::applyFilterToCollection($filter, $range, $index);
     }
     $select = $filter->getLayer()->getProductCollection()->getSelect();
     $priceExpr = $this->_getPriceExpression($filter, $select);
     $filter->getLayer()->getProductCollection()->getSelect()->where($priceExpr . ' >= ' . $this->_getComparingValue($range * ($index - 1), $filter))->where($priceExpr . ' <= ' . $this->_getComparingValue($range * $index, $filter, false));
     return $this;
 }
コード例 #7
0
ファイル: Price17.php プロジェクト: nilshopsahl/hasla.local
 protected function _construct()
 {
     parent::_construct();
 }