This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using AyaNova.Biz;
|
||||
namespace AyaNova.DataList
|
||||
{
|
||||
@@ -15,17 +16,31 @@ namespace AyaNova.DataList
|
||||
|
||||
public TestWidgetUserEmailDataList()
|
||||
{
|
||||
ListKey = nameof(TestWidgetUserEmailDataList);
|
||||
|
||||
SQLFrom = "from awidget left outer join auser on (awidget.userid=auser.id) left outer join auseroptions on (auser.id=auseroptions.userid)";
|
||||
FullListAllowedRoles = BizRoles.GetRoleSet(DefaultListObjectType).ReadFullRecord;
|
||||
MiniListAllowedRoles = AuthorizationRoles.AllExceptCustomers;//anyone but clients who shouldn't see users email addresses (so can select on forms)
|
||||
AllowedRoles = BizRoles.GetRoleSet(DefaultListObjectType).ReadFullRecord;
|
||||
DefaultListObjectType = AyaType.Widget;
|
||||
DefaultDataListDisplayTemplate = @"
|
||||
{
|
||||
""full"":[""widgetname"",""username"",""emailaddress"",""widgetactive""],
|
||||
""mini"":[""widgetname"",""username"",""emailaddress""]
|
||||
}
|
||||
";
|
||||
//Default ListView
|
||||
dynamic dlistView = new JArray();
|
||||
|
||||
dynamic cm = new JObject();
|
||||
cm.fld = "widgetname";
|
||||
dlistView.Add(cm);
|
||||
|
||||
cm = new JObject();
|
||||
cm.fld = "username";
|
||||
dlistView.Add(cm);
|
||||
|
||||
cm = new JObject();
|
||||
cm.fld = "emailaddress";
|
||||
dlistView.Add(cm);
|
||||
|
||||
cm = new JObject();
|
||||
cm.fld = "widgetactive";
|
||||
dlistView.Add(cm);
|
||||
|
||||
DefaultListView = dlistView.ToString();
|
||||
|
||||
|
||||
//NOTE: First field after df is used as the title above the narrow grid view so it should be the name of the item to be shown that is most identifiable
|
||||
FieldDefinitions = new List<AyaDataListFieldDefinition>();
|
||||
|
||||
Reference in New Issue
Block a user