Example #1
0
 /**
  * Show the application dashboard.
  *
  * @return \Illuminate\Http\Response
  */
 public function index($local_events_only = false)
 {
     $user = Auth::user();
     $events = $this->getUsersEvents();
     $invites = $this->getUserInvitedEvents();
     $public_events = Event::getPublicEvents();
     $this->updateCity();
     return view('home')->with('events', $events)->with('invites', $invites)->with('public_events', $public_events)->with('local_events_only', $local_events_only)->with('city', $user->city);
 }
 /**
  * Show the application dashboard.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $public_events = Event::getPublicEvents();
     return response()->json(compact('public_events'));
     /*return view('welcome')->with('public_events', $public_events);
     
             $events = $this->getUsersEvents();
             $invites = $this->getUserInvitedEvents();
             $array = array_merge($events->toArray(), $invites);
             return response()->json(compact('array'));*/
 }
Example #3
0
 public function getPublicEvents()
 {
     $events = Event::getPublicEvents();
     return $events;
 }
Example #4
0
 /**
  * Show the applications welcome page
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $public_events = Event::getPublicEvents();
     return view('welcome')->with('public_events', $public_events);
 }