| | 1 | | @inherits LayoutComponentBase |
| | 2 | |
|
| | 3 | | @inject NavigationManager navManager |
| | 4 | | @inject MunityContext dbContext |
| | 5 | |
|
| | 6 | | @*@((mainViewService.ShowSidebar) ? "page-sidebar-toggled" : null)*@ |
| | 7 | | <div id="app" class="app app-header-fixed app-content-full-height app-with-top-menu app-sidebar-fixed app-without-sideba |
| | 8 | | <MUNity.BlazorServer.Shared.Header.HeaderComponent /> |
| | 9 | | <MUNity.BlazorServer.Shared.TopMenu.TopMenuComponent /> |
| | 10 | | <div id="content" class="app-content d-flex flex-column"> |
| | 11 | | <div class="app-content-padding flex-grow-1 overflow-hidden ps" data-scrollbar="true" data-height="100%" data-in |
| 0 | 12 | | @Body |
| | 13 | |
|
| | 14 | | </div> |
| | 15 | |
|
| 0 | 16 | | @if (conferenceId != null) |
| 0 | 17 | | { |
| 0 | 18 | | var footer = dbContext.ConferenceWebsiteFooters.FirstOrDefault(n => n.ConferenceId == conferenceId); |
| 0 | 19 | | if (footer != null) |
| 0 | 20 | | { |
| | 21 | | <div id="footer" class="app-footer m-0"> |
| 0 | 22 | | <p>@((MarkupString)footer.FooterContent)</p> |
| | 23 | | </div> |
| 0 | 24 | | } |
| 0 | 25 | | } |
| | 26 | |
|
| | 27 | |
|
| | 28 | | </div> |
| | 29 | | </div> |
| | 30 | |
|
| | 31 | | <RadzenDialog /> |
| | 32 | | <RadzenNotification /> |
| | 33 | | <RadzenContextMenu /> |
| | 34 | | <RadzenTooltip /> |
| | 35 | |
|
| | 36 | | @code { |
| | 37 | | private string conferenceId; |
| | 38 | |
|
| | 39 | | protected override void OnInitialized() |
| 0 | 40 | | { |
| 0 | 41 | | base.OnInitialized(); |
| 0 | 42 | | navManager.LocationChanged += delegate { ParseConferenceId(); }; |
| 0 | 43 | | ParseConferenceId(); |
| 0 | 44 | | } |
| | 45 | |
|
| | 46 | | private void ParseConferenceId() |
| 0 | 47 | | { |
| 0 | 48 | | if (navManager.Uri.Count(n => n == '/') >= 5) |
| 0 | 49 | | { |
| 0 | 50 | | conferenceId = navManager.Uri.Split("/")[5]; |
| 0 | 51 | | } |
| | 52 | | else |
| 0 | 53 | | { |
| 0 | 54 | | conferenceId = null; |
| 0 | 55 | | } |
| 0 | 56 | | this.InvokeAsync(StateHasChanged); |
| 0 | 57 | | } |
| | 58 | | } |