Bulk-Commit: Darft: Anmeldetool.

Interface Definition: done
Server-Side-Implementation: partly done (CR missing, potential Refactor, ...)
Client-Side-Implementation: started: (UI: done, Service: started, but works with SSR)
Missing: Permissions / Roles to restrict access to an event.
Missing: Fields on Event.
Missing: Good Styling
Time-Took: about 12 Hours.
Learning: Commit in smaller packets, rest will be discussed at CR
This commit is contained in:
Konstantin Hintermayer
2025-05-14 20:40:10 +02:00
parent e45fce2e65
commit 38c5bef225
17 changed files with 508 additions and 92 deletions

View File

@ -55,7 +55,7 @@
if (PageState.Action == "Edit")
{
_id = Int32.Parse(PageState.QueryString["id"]);
Event EventRegistration = await EventRegistrationService.GetEventRegistrationAsync(_id, ModuleState.ModuleId);
Event EventRegistration = await EventRegistrationService.GetEventAsync(_id, ModuleState.ModuleId);
if (EventRegistration != null)
{
_name = EventRegistration.Name;
@ -86,14 +86,14 @@
Event EventRegistration = new Event();
EventRegistration.ModuleId = ModuleState.ModuleId;
EventRegistration.Name = _name;
EventRegistration = await EventRegistrationService.AddEventRegistrationAsync(EventRegistration);
EventRegistration = await EventRegistrationService.AddEventAsync(EventRegistration);
await logger.LogInformation("EventRegistration Added {EventRegistration}", EventRegistration);
}
else
{
Event EventRegistration = await EventRegistrationService.GetEventRegistrationAsync(_id, ModuleState.ModuleId);
Event EventRegistration = await EventRegistrationService.GetEventAsync(_id, ModuleState.ModuleId);
EventRegistration.Name = _name;
await EventRegistrationService.UpdateEventRegistrationAsync(EventRegistration);
await EventRegistrationService.UpdateEventAsync(EventRegistration);
await logger.LogInformation("EventRegistration Updated {EventRegistration}", EventRegistration);
}
NavigationManager.NavigateTo(NavigateUrl());