Beispiel #1
0
 /**
  * Check whether specified attribute can be used in LN
  *
  * @param Mage_Catalog_Model_Resource_Eav_Attribute $attribute
  * @return bool
  */
 protected function _getIsFilterableAttribute($attribute)
 {
     return $attribute->getIsFilterable();
 }
 /**
  * @param Mage_Catalog_Model_Resource_Eav_Attribute $attribute
  * @return bool
  */
 public function isIndexableAttribute(Mage_Catalog_Model_Resource_Eav_Attribute $attribute)
 {
     if ($attribute->getBackendType() == 'varchar' && !$attribute->getBackendModel()) {
         return true;
     }
     if ($attribute->getBackendType() == 'int' && $attribute->getSourceModel() != 'eav/entity_attribute_source_boolean' && ($attribute->getIsSearchable() || $attribute->getIsFilterable() || $attribute->getIsFilterableInSearch())) {
         return true;
     }
     if ($attribute->getIsSearchable() || $attribute->getIsFilterable() || $attribute->getIsFilterableInSearch()) {
         return true;
     }
     return false;
 }
Beispiel #3
0
 /**
  * Check whether specified attribute can be used in LN
  *
  * @param Mage_Catalog_Model_Resource_Eav_Attribute $attribute
  * @return bool
  */
 protected function _getIsFilterableAttribute($attribute)
 {
     if (Mage::registry("current_category")) {
         return $attribute->getIsFilterable();
     }
 }