feat: use the new, revised database model

This commit is contained in:
2025-04-28 02:34:03 +02:00
parent b4b81355c1
commit 1083cfa3ff
7 changed files with 570 additions and 9 deletions

View File

@@ -26,6 +26,11 @@
<input asp-for="EventDate" type="datetime-local" class="form-control" />
<span asp-validation-for="EventDate" class="text-danger"></span>
</div>
<div class="form-group">
<label asp-for="OrganisationId">OrganisationId (for debugging purposes)</label>
<input asp-for="OrganisationId" class="form-control" />
<span asp-validation-for="OrganisationId" class="text-danger"></span>
</div>
<button type="submit" class="btn btn-primary">Save</button>
</form>

View File

@@ -22,6 +22,7 @@
<th>Nazwa</th>
<th>Miejsce</th>
<th>Data</th>
<th>Organizacja</th>
<th>Akcje</th>
</tr>
</thead>
@@ -32,6 +33,7 @@
<td>@item.Title</td>
<td>@item.Location</td>
<td>@item.EventDate.ToString("yyyy-MM-dd HH:mm")</td>
<td>@item.OrganisationId</td>
<td>
<form asp-action="Delete" asp-controller="Events" method="post" style="display:inline;">
<input type="hidden" name="id" value="@item.EventId" />

View File

@@ -1,6 +1,7 @@
@using Microsoft.AspNetCore.Identity
@inject SignInManager<IdentityUser> SignInManager
@inject UserManager<IdentityUser> UserManager
@using WebApp.Entities
@inject SignInManager<User> SignInManager
@inject UserManager<User> UserManager
<ul class="navbar-nav">
@if (SignInManager.IsSignedIn(User))