Prestashop: Additional field in product attributes

Added an additional field for product attributes

Files updated and added to override folder

override/classes
Attribute.php
line 36    public $barcode;
line 50            ‘barcode’ =>             array(‘type’ => self::TYPE_STRING, ‘validate’ => ‘isAnything’, ‘size’ => 3),

override/controllers/admin
AdminAttributesGroupsController.php
line 128
‘barcode’ => array(
‘title’ => $this->l(‘Barcode’),
‘align’ => ‘center’,
‘class’ => ‘fixed-width-xs’
)
line 277
array(
‘type’ => ‘text’,
‘label’ => $this->l(‘Barcode’),
‘name’ => ‘barcode’,
‘hint’ => $this->l(‘Invalid characters:’).’ <>;=#{}’
)

Database insert column
#     Name     Type     Collation     Attributes     Null     Default
5     barcode     varchar(3)     utf8_unicode_ci    –     Yes     NULL

This entry was posted in database, ecommerce and tagged . Bookmark the permalink.