From 699a83562ee60fd45d6e1eaa3c6a18d5fd48213f Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Thu, 13 Feb 2020 23:47:39 +0000 Subject: [PATCH] --- server/AyaNova/DataList/DataListFetcher.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/server/AyaNova/DataList/DataListFetcher.cs b/server/AyaNova/DataList/DataListFetcher.cs index b64e6f65..e06f14a3 100644 --- a/server/AyaNova/DataList/DataListFetcher.cs +++ b/server/AyaNova/DataList/DataListFetcher.cs @@ -16,7 +16,6 @@ namespace AyaNova.DataList internal static async Task GetResponseAsync(string DataListKey, AyContext ct, ListOptions listOptions, long UserId, AuthorizationRoles UserRoles) { - var DataList = DataListFactory.GetAyaDataList(DataListKey); //was the name not found as a list? @@ -30,6 +29,12 @@ namespace AyaNova.DataList if (!UserRoles.HasAnyFlags(DataList.AllowedRoles)) throw new System.UnauthorizedAccessException("User roles insufficient for this datalist"); + //do we need to default the listView? + if (string.IsNullOrWhiteSpace(listOptions.ListView)) + { + listOptions.ListView = DataList.DefaultListView; + } + //parse the list view var ListViewArray = JArray.Parse(listOptions.ListView);