2012-02-10 88 views

回答

5

是的,這是可能的。如果你這樣做在安裝腳本 - 你應該設置'visible'爲false:

$installer->addAttribute(Mage_Catalog_Model_Product::ENTITY, '<attribute_code>', array(
    ... 
    'visible'  => false, 
    ... 
)); 

如果需要直接在DB改變它存在的屬性 - 去catalog_eav_attribute表,找到你的屬性(尋找屬性ID的屬性代碼在eav_attribute表中)並將它的is_visible字段設置爲0.

+0

謝謝!它爲我工作:) – sudhakar 2013-09-05 08:46:12

+0

你確定is_visible字段在eav_attribute表中可用嗎?我正在談論Magento版本。 1.7.0.2。因爲我只能得到這些字段('attribute_id','entity_type_id','attribute_code','attribute_model','backend_model','backend_type','backend_table','frontend_model','frontend_input','frontend_label '''''frontend_class','source_model','is_required','is_user_defined','default_value','is_unique','note') – Jyotiranjan 2015-04-26 07:38:56

相關問題