Routes with Module ID and no Action can be displayed on any page regardless of whether a PageModule record exists (ie. Admin Dashboard)

This commit is contained in:
Shaun Walker 2023-04-11 10:21:37 -04:00
parent 8985dcb4c0
commit 7fe4577158

View File

@ -107,7 +107,7 @@ else
{
if (PageState.ModuleId != -1)
{
Module module = PageState.Modules.FirstOrDefault(item => item.PageId == PageState.Page.PageId && item.ModuleId == PageState.ModuleId);
Module module = PageState.Modules.FirstOrDefault(item => item.ModuleId == PageState.ModuleId);
if (module != null && module.Pane.ToLower() == Name.ToLower())
{
// check if user is authorized to view module