This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
namespace AyaNova.Biz
|
namespace AyaNova.Biz
|
||||||
{
|
{
|
||||||
static class AyDataTypes
|
public static class AyDataType
|
||||||
{
|
{
|
||||||
public const string Date = "date";
|
public const string Date = "date";
|
||||||
public const string Text = "text";
|
public const string Text = "text";
|
||||||
@@ -17,6 +17,12 @@ namespace AyaNova.Biz
|
|||||||
Key = key;
|
Key = key;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public FilterOptions AddField(string FieldName, string LocaleKey, string DataType)
|
||||||
|
{
|
||||||
|
Flds.Add(new FilterField() { Fld = FieldName, Lt = LocaleKey, Type = DataType });
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public class FilterField
|
public class FilterField
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ namespace AyaNova.Biz
|
|||||||
{
|
{
|
||||||
|
|
||||||
//FILTEROPTIONS COLLECTION
|
//FILTEROPTIONS COLLECTION
|
||||||
FilterOptions FilterOptions { get; set; }
|
FilterOptions FilterOptions { get; }
|
||||||
|
|
||||||
|
|
||||||
//VALIDATE FILTER?
|
//VALIDATE FILTER?
|
||||||
|
|||||||
@@ -14,8 +14,28 @@ namespace AyaNova.Biz
|
|||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
internal class WidgetBiz : BizObject, IJobObject
|
internal class WidgetBiz : BizObject, IJobObject, IFilterableObject
|
||||||
{
|
{
|
||||||
|
private FilterOptions filterOptions = null;
|
||||||
|
public FilterOptions FilterOptions
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (filterOptions == null)
|
||||||
|
{
|
||||||
|
filterOptions = new FilterOptions("Widget");
|
||||||
|
filterOptions.
|
||||||
|
AddField("Name", "WidgetName", AyDataType.Text).
|
||||||
|
AddField("Serial", "WidgetSerial", AyDataType.Text).
|
||||||
|
AddField("DollarAmount", "WidgetDollarAmount", AyDataType.Decimal).
|
||||||
|
AddField("Active", "WidgetActive", AyDataType.Bool).
|
||||||
|
AddField("StartDate", "WidgetStartDate", AyDataType.Date).
|
||||||
|
AddField("EndDate", "WidgetEndDate", AyDataType.Date);
|
||||||
|
|
||||||
|
}
|
||||||
|
return filterOptions;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
internal WidgetBiz(AyContext dbcontext, long currentUserId, long userLocaleId, AuthorizationRoles UserRoles)
|
internal WidgetBiz(AyContext dbcontext, long currentUserId, long userLocaleId, AuthorizationRoles UserRoles)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user