This commit is contained in:
2020-01-22 18:10:12 +00:00
parent b5708667c2
commit e78b54b040
8 changed files with 150 additions and 9 deletions

View File

@@ -26,9 +26,15 @@ namespace AyaNova.DataList
}
//check rights
if (!UserRoles.HasAnyFlags(DataList.AllowedRoles))
if (listOptions.Mini)
{
if (!UserRoles.HasAnyFlags(DataList.MiniListAllowedRoles))
throw new System.UnauthorizedAccessException("User roles insufficient for this mini format datalist");
}
else
{
throw new System.NotSupportedException("User roles insufficient for this datalist");
if (!UserRoles.HasAnyFlags(DataList.FullListAllowedRoles))
throw new System.UnauthorizedAccessException("User roles insufficient for this full format datalist");
}
//FETCH DATALISTTEMPLATE HERE OR USE DEFAULT IF FAULTY OR NOT FOUND