public function all() { $businesses = Business::all(); $categories = Category::all(); $page = "Toutes les entreprises"; return view('businesses', compact('businesses', 'page', 'categories')); }
/** * Show the application dashboard to the user. * * @return Response */ public function search() { $businesses = Business::all(); foreach ($businesses as $key => $business) { $userDetail = UserDetail::where('businessId', $business->id)->first(); $user = User::find($userDetail->userId); $businesses[$key] = (object) array_merge($user->toArray(), $userDetail->toArray(), $business->toArray()); } return view('business.search')->withBusinesses($businesses); }
/** * Display a listing of the resource. * * @return Response */ public function index() { $page = "Toutes les Entreprises"; $businesses = Business::all(); return view('admin.business.index', compact('businesses', 'page')); }
public function index() { $businesses = Business::all(); return view('businessList', compact('businesses')); }
public function dashboard() { $businesses = Business::all(); $page = "Tableau de bord"; return view('admin.index', compact('businesses', 'page')); }
/** * get List * * @return Response Rendered view of all existing Businesses */ public function getList() { $this->log->info('BusinessController: getList'); $businesses = Business::all(); return view('user.businesses.index', compact('businesses')); }
/** * Show JSON listing of all businesses */ public function getBusinesses() { return Business::all(); }