longy Posted July 2, 2014 Share Posted July 2, 2014 (edited) I'm curious to know how prestashop implements status enabled/disabled in backoffice product list. Someone can indicate where i can find code that handle visualization of that button and relative "on click" functionality? Edited July 2, 2014 by longy (see edit history) Link to comment Share on other sites More sharing options...
longy Posted July 3, 2014 Author Share Posted July 3, 2014 up Link to comment Share on other sites More sharing options...
vekia Posted July 3, 2014 Share Posted July 3, 2014 hello by visualiation you mean css styles? (change color etc.?) Link to comment Share on other sites More sharing options...
longy Posted July 3, 2014 Author Share Posted July 3, 2014 (edited) Yes because I would like to do the same with some custom columns I added to product list in backoffice.That columns contain boolean values that should be changed like status column. So I need to know how to create something that looks and works in a similar way. Edited July 3, 2014 by longy (see edit history) Link to comment Share on other sites More sharing options...
longy Posted July 4, 2014 Author Share Posted July 4, 2014 up Link to comment Share on other sites More sharing options...
vekia Posted July 4, 2014 Share Posted July 4, 2014 Yes because I would like to do the same with some custom columns I added to product list in backoffice. That columns contain boolean values that should be changed like status column. So I need to know how to create something that looks and works in a similar way. so you aren't interested in css / design styles but in php / controller things in your controller you can use: $this->fields_list['active'] = array( 'title' => $this->l('Status'), 'active' => 'status', 'filter_key' => $alias.'!active', 'align' => 'text-center', 'type' => 'bool', 'class' => 'fixed-width-sm', 'orderby' => false ); (it's for status! you have to change variable names to own) Link to comment Share on other sites More sharing options...
longy Posted July 4, 2014 Author Share Posted July 4, 2014 Thanks for reply. I'm already using similar code to add custom columns. I could use class attribute to manage style and ajax call to some controller action. I would like to see how prestashop manage these things to know what I've to override or where I should put my code. Link to comment Share on other sites More sharing options...
longy Posted July 8, 2014 Author Share Posted July 8, 2014 up Link to comment Share on other sites More sharing options...
Recommended Posts