public void OnGet(int?id) { ViewID = id ?? userContext.Views.GetFirstViewID() ?? 0; ViewData["SelectedViewID"] = ViewID; // used by _MainLayout if (viewLoader.GetViewSpec(ViewID, out ViewSpec viewSpec, out string errMsg)) { ErrorMessage = ""; ViewFrameUrl = Url.Content(viewSpec.GetFrameUrl(ViewID)); }
public IActionResult OnGet(int?id) { int viewID = id ?? userContext.Views.GetFirstViewID() ?? 0; if (viewLoader.GetViewSpec(viewID, out ViewSpec viewSpec, out string errMsg)) { ErrorMessage = ""; string viewFrameUrl = Url.Content(viewSpec.GetFrameUrl(viewID)); return(LocalRedirect(viewFrameUrl)); }