Skip to content

Commit

Permalink
thanks!
Browse files Browse the repository at this point in the history
  • Loading branch information
vadosnaprimer committed Aug 11, 2024
1 parent 88b1a22 commit 203f663
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion TASVideos/Pages/Games/Index.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
{
<div id="tab-goal-@(goal.Id)" class="tab-pane fade@(goal==Model.Game.PlaygroundGoals.First() ? " active show" : "")">
<ul>
@foreach (var sub in goal.Submissions.OrderByDescending(s => s.Id))
@foreach (var sub in goal.Submissions)
{
<li>
<sub-link id="@sub.Id">@sub.Title</sub-link>
Expand Down
16 changes: 8 additions & 8 deletions TASVideos/Pages/Games/Index.cshtml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@ public async Task<IActionResult> OnGet()
UserFilesCount = g.UserFiles.Count(uf => !uf.Hidden),
PlaygroundGoals = g.Submissions
.Where(s => s.Status == SubmissionStatus.Playground)
.Select(s => s.GameGoal)
.Select(g => new GoalEntry(
g.Id,
g.DisplayName,
g.Submissions
.Where(s => s.Status == SubmissionStatus.Playground)
.Select(s => new SubmissionEntry(s.Id, s.Title))
.GroupBy(s => s.GameGoal)
.OrderBy(gg => gg.Key!.DisplayName.Length)
.Select(gg => new GoalEntry(
gg.Key!.Id,
gg.Key!.DisplayName,
gg.OrderByDescending(ggs => ggs.Id)
.Select(ggs => new SubmissionEntry(ggs.Id, ggs.Title))
.ToList()))
.ToList()
.ToList(),
});

query = ParsedId > 0
Expand Down

0 comments on commit 203f663

Please sign in to comment.