]> git.localhorst.tv Git - alttp.git/blobdiff - app/Http/Controllers/UserController.php
show placements on user profile
[alttp.git] / app / Http / Controllers / UserController.php
index 8c451fc1328c3260ff6a9ed0c984b353536d917a..692c45862feb0e21186862476cf9ff5a76e31bc8 100644 (file)
@@ -43,6 +43,12 @@ class UserController extends Controller
                $this->authorize('view', $user);
                $user->load('participation');
                $user->load('participation.tournament');
+               $user->loadCount('round_first');
+               $user->loadCount('round_second');
+               $user->loadCount('round_third');
+               $user->loadCount('tournament_first');
+               $user->loadCount('tournament_second');
+               $user->loadCount('tournament_third');
                return $user->toJson();
        }