Roman168140 Posted March 24, 2014 Share Posted March 24, 2014 Hey.I want do add another option to product visibility (in product informations) because i have products that may appears in special places only. I made changes at informations.tpl where i add <option value="related" {if $product->visibility == 'related'}selected="selected"{/if} >{l s='Related only'}</option> In Validation file isProductVisibility: return preg_match('/^both|catalog|search|related|none$/i', $s); and in /classes/Product.php 'visibility' => array('type' => self::TYPE_STRING, 'shop' => true, 'validate' => 'isProductVisibility', 'values' => array('both', 'catalog', 'search','related', 'none'), 'default' => 'both'), and changed in DB ps_product Enum field 'visibility' that it accept 'related' Saving works fine. In db it shows "related". But in AdminContrroller (BackOffice, front i can handle) on this product page( in informations tab ) there is no correct population because product->visibility =''Why!?. Thanks in advance. Link to comment Share on other sites More sharing options...
Roman168140 Posted March 24, 2014 Author Share Posted March 24, 2014 Ok. I managed to achieve what i want. Table ps_product_shop also required to add related in visibility enum field. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now