Files
raven/server/AyaNova/DataList/TaskGroupDataList.cs
2021-05-25 15:17:36 +00:00

48 lines
1.7 KiB
C#

using System.Collections.Generic;
using AyaNova.Biz;
namespace AyaNova.DataList
{
internal class TaskGroupDataList : DataListProcessingBase
{
public TaskGroupDataList()
{
DefaultListAType = AyaType.TaskGroup;
SQLFrom = "from ataskgroup";
var RoleSet = BizRoles.GetRoleSet(DefaultListAType);
AllowedRoles = RoleSet.ReadFullRecord | RoleSet.Change;
DefaultColumns = new List<string>() { "taskgroupname" };
DefaultSortBy = new Dictionary<string, string>() { { "taskgroupname", "+" } };
FieldDefinitions = new List<DataListFieldDefinition>();
FieldDefinitions.Add(new DataListFieldDefinition
{
TKey = "TaskGroupName",
FieldKey = "taskgroupname",
AType = (int)AyaType.TaskGroup,
UiFieldDataType = (int)UiFieldDataType.Text,
SqlIdColumnName = "ataskgroup.id",
SqlValueColumnName = "ataskgroup.name",
IsRowId = true
});
FieldDefinitions.Add(new DataListFieldDefinition
{
TKey = "TaskGroupNotes",
FieldKey = "Notes",
UiFieldDataType = (int)UiFieldDataType.Text,
SqlValueColumnName = "ataskgroup.notes"
});
FieldDefinitions.Add(new DataListFieldDefinition
{
TKey = "Active",
FieldKey = "taskgroupactive",
UiFieldDataType = (int)UiFieldDataType.Bool,
SqlValueColumnName = "ataskgroup.active"
});
}
}//eoc
}//eons