public function getBrandsToSelect() { $brands = $this->brandManager->getAll(); $result = []; foreach ($brands as $brand) { $result[$brand['id']] = $brand['title']; } return $result; }
public function actionDelete($category_id) { $this->brandManager->delete($category_id); $this->flashMessage('Brand has been successfully deleted.', 'success'); $this->redirect('default'); }