Example #1
0
 public DttFieldAttribute(bool hidden             = false,
                          string columnName       = null,
                          bool renderChild        = false,
                          bool overrideRender     = false,
                          string renderFunction   = null,
                          DttFiledType type       = DttFiledType.Auto,
                          string[] renderChildren = null,
                          bool export             = true,
                          bool orderable          = true,
                          bool searchable         = true,
                          bool showParentLabel    = false,
                          bool renderAllChildren  = false,
                          bool isCustom           = false)
 {
     this.Hidden            = hidden;
     this.ColumnName        = columnName;
     this.RenderFunction    = renderFunction;
     this.Type              = type;
     this.RenderChildren    = renderChildren;
     this.Export            = export;
     this.Orderable         = orderable;
     this.Searchable        = searchable;
     this.RenderAllChildren = renderAllChildren;
     this.ShowParentLabel   = showParentLabel;
     this.isCustom          = isCustom;
 }
Example #2
0
        public void SetType(DttFiledType type)
        {
            switch (type)
            {
            case DttFiledType.String:
                this.type = "string";
                break;

            case DttFiledType.Date:
                this.type = "date";
                break;

            case DttFiledType.DateTime:
                this.type = "datetime";
                break;

            case DttFiledType.Number:
                this.type = "number";
                break;

            case DttFiledType.Status:
                this.type = "status";
                break;

            case DttFiledType.Bool:
                this.type = "bool";
                break;

            case DttFiledType.NullableDateTime:
                this.type = "nullabledatetime";
                break;

            default:
                this.type = "string";
                break;
            }
        }