Allow UI to delete sessions

This commit is contained in:
2024-09-07 22:26:38 -05:00
parent 0eb75994c9
commit 6b5bb96de7
11 changed files with 162 additions and 21 deletions

View File

@@ -10,31 +10,22 @@
<row class="header">
<span>Creator</span>
<span>Seats</span>
<span></span>
</row>
<hr />
<AuthorizeView>
@foreach (var session in allSessions)
{
<row>
<div>
<a href="play/@session.SessionId">@session.Player1</a>
</div>
@if (string.IsNullOrEmpty(session.Player2))
{
<span>1 / 2</span>
}
else
{
<span>Full</span>
}
</row>
<row>
<GameBrowserEntry Session="session" OnSessionDeleted="FetchSessions" />
</row>
}
</AuthorizeView>
</div>
@if (allSessions.Length == 0)
{
<p>There are no games being played.</p>
<p>There are no games being played.</p>
}
</section>