diff --git a/tippspiel/app/Http/Controllers/PagesController.php b/tippspiel/app/Http/Controllers/PagesController.php index ee1a189..6bbf618 100644 --- a/tippspiel/app/Http/Controllers/PagesController.php +++ b/tippspiel/app/Http/Controllers/PagesController.php @@ -16,7 +16,6 @@ class PagesController extends Controller $teams = Team::all(); $matches = Match::all(); $tipps = Tipp::where('user', Auth::user()->id)->get(); - dd($tipps->where('matchid', 1)); return view('dashboard')->with([ 'teams' => $teams, diff --git a/tippspiel/resources/views/dashboard.blade.php b/tippspiel/resources/views/dashboard.blade.php index ff3cb04..ff1d6b4 100644 --- a/tippspiel/resources/views/dashboard.blade.php +++ b/tippspiel/resources/views/dashboard.blade.php @@ -39,7 +39,7 @@ {!! $teams->find($match->teama)->name !!} {!! $teams->find($match->teamb)->name !!} {!! $match->resulta . ':' . $match->resultb !!} - {!! $tipps->where('matchid', $match->id)->resulta->first() . ':' . $tipps->where('matchid', $match->id)->resultb->first() !!} + {!! $tipps->where('matchid', $match->id)->first()->resulta . ':' . $tipps->where('matchid', $match->id)->first()->resultb !!} @if($tipps->where('matchid', $match->id)->resulta != null)