coisio/module-multiselect-attribute-fix

修复多选属性索引问题

1.0.0 2017-05-19 11:51 UTC

This package is auto-updated.

Last update: 2024-09-10 22:38:18 UTC


README

请注意,当运行自定义的多选文本属性并保存到平坦表时

您必须告诉索引器关于平坦表列的信息。

public function getFlatColums()
    {
        $attributeCode = $this->getAttribute()->getAttributeCode();
        $column = array(
            'default'   => null,
            'extra'     => null
        );
        if (Mage::helper('core')->useDbCompatibleMode()) {
            $column['type']     = 'varchar(255)';
            $column['is_null']  = true;
        } else {
            $column['type']     = Varien_Db_Ddl_Table::TYPE_VARCHAR;
            $column['nullable'] = true;
            $column['comment']  = $attributeCode . ' column';
        }
        return array($attributeCode => $column);
    }