public function index(BrandListener $listener) { $eloquent = BrandModel::orderBy('name', 'ASC')->paginate(); $data = ['brands' => $eloquent]; return $listener->showAllBrands($data); }
public function destroy(ResourceListener $listener, $brandId) { $eloquent = BrandModel::findOrFail($brandId); $model->delete(); return $listener->successfulProcess(); }