Example #1
0
 /**
  * Define columns structure
  *
  * @return array
  */
 protected function defineColumns()
 {
     $list = parent::defineColumns();
     unset($list['category']);
     foreach ($list as $name => $info) {
         unset($list[$name][static::COLUMN_SORT]);
     }
     return $list;
 }
Example #2
0
 /**
  * Define items list columns
  *
  * @return array
  */
 protected function defineColumns()
 {
     $allowedColumns = array('sku', 'name', 'qty');
     $columns = parent::defineColumns();
     // Remove redundant columns
     foreach ($columns as $k => $v) {
         $columns[$k][static::COLUMN_SORT] = null;
         if (!in_array($k, $allowedColumns)) {
             unset($columns[$k]);
         }
     }
     return $columns;
 }