Prevent editing product attributes in admin backend.
- version: 1.1.0
- extension key: StackExchange_LockAttributes
- extension on GitHub
Read-Only Product Backend attribute
I would like to create an attribute read only however it look it is not possible.
I have tried to pass to addAttribute()
'disabled' =>true
or'readonly' => true
with out any success. I have found out some suggestion about usingsetLockedAttributes()
but for some reason it is not workingReference:
Varien_Data_Form_Element_Abstract::serialize($attributes = array(), $valueSeparator='=', $fieldSeparator=' ', $quote='"')
- PHP >= 5.4.0
- Magento >= 1.5
- via modman
modman clone https://github.com/sreichel/magento-StackExchange_LockAttributes.git
- via composer
composer require mse-sv3n/m1-lock-attributes
- via modman
modman remove magento-stackexchange-lockattributes
- via composer
composer remove mse-sv3n/m1-lock-attributes
- get to config section and set attributes you want to lock
- set ACL permission for uses that are still allowed to edit
If you have any issues with this extension, open an issue on GitHub.
Any contribution is highly appreciated. The best way to contribute code is to open a pull request on GitHub.