@@ -10,7 +10,7 @@ public static class GriddlyFilterExtensions
10
10
// ********
11
11
// NOTE: these methods can be called with null column by the ones on GriddlySettings
12
12
// ********
13
- public static GriddlyFilterBox FilterBox ( this GriddlyColumn column , FilterDataType dataType = FilterDataType . Decimal , string field = null , string caption = null , string htmlClass = null , string captionPlural = null )
13
+ public static GriddlyFilterBox FilterBox ( this GriddlyColumn column , FilterDataType dataType = FilterDataType . Decimal , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , string group = null )
14
14
{
15
15
if ( caption == null )
16
16
caption = column . Caption ;
@@ -28,7 +28,8 @@ public static GriddlyFilterBox FilterBox(this GriddlyColumn column, FilterDataTy
28
28
Field = field ,
29
29
Caption = caption ,
30
30
DataType = dataType ,
31
- HtmlClass = htmlClass
31
+ HtmlClass = htmlClass ,
32
+ Group = group
32
33
} ;
33
34
34
35
if ( captionPlural != null )
@@ -37,7 +38,7 @@ public static GriddlyFilterBox FilterBox(this GriddlyColumn column, FilterDataTy
37
38
return filter ;
38
39
}
39
40
40
- public static GriddlyFilterRange FilterRange ( this GriddlyColumn column , FilterDataType dataType = FilterDataType . Decimal , string field = null , string fieldEnd = null , string caption = null , string htmlClass = null , string captionPlural = null )
41
+ public static GriddlyFilterRange FilterRange ( this GriddlyColumn column , FilterDataType dataType = FilterDataType . Decimal , string field = null , string fieldEnd = null , string caption = null , string htmlClass = null , string captionPlural = null , string group = null )
41
42
{
42
43
if ( caption == null )
43
44
caption = column . Caption ;
@@ -60,7 +61,8 @@ public static GriddlyFilterRange FilterRange(this GriddlyColumn column, FilterDa
60
61
FieldEnd = fieldEnd ,
61
62
Caption = caption ,
62
63
DataType = dataType ,
63
- HtmlClass = htmlClass
64
+ HtmlClass = htmlClass ,
65
+ Group = group
64
66
} ;
65
67
66
68
if ( captionPlural != null )
@@ -69,7 +71,7 @@ public static GriddlyFilterRange FilterRange(this GriddlyColumn column, FilterDa
69
71
return filter ;
70
72
}
71
73
72
- public static GriddlyFilterList FilterList ( this GriddlyColumn column , IEnumerable < SelectListItem > items , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false )
74
+ public static GriddlyFilterList FilterList ( this GriddlyColumn column , IEnumerable < SelectListItem > items , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false , string group = null )
73
75
{
74
76
if ( caption == null )
75
77
caption = column . Caption ;
@@ -105,7 +107,8 @@ public static GriddlyFilterList FilterList(this GriddlyColumn column, IEnumerabl
105
107
IsNullable = ! string . IsNullOrWhiteSpace ( nullItemText ) ,
106
108
DefaultSelectAll = defaultSelectAll ,
107
109
HtmlClass = htmlClass ,
108
- DisplayIncludeCaption = displayIncludeCaption
110
+ DisplayIncludeCaption = displayIncludeCaption ,
111
+ Group = group
109
112
} ;
110
113
111
114
if ( captionPlural != null )
@@ -129,21 +132,21 @@ public static string GetField(GriddlyColumn column)
129
132
return value ;
130
133
}
131
134
132
- public static GriddlyFilterList FilterEnum < T > ( this GriddlyColumn column , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false )
135
+ public static GriddlyFilterList FilterEnum < T > ( this GriddlyColumn column , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false , string group = null )
133
136
where T : struct
134
137
{
135
- return column . FilterList ( Extensions . ToSelectListItems < T > ( ) . OrderBy ( x => x . Text ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption ) ;
138
+ return column . FilterList ( Extensions . ToSelectListItems < T > ( ) . OrderBy ( x => x . Text ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption , group ) ;
136
139
}
137
140
138
- public static GriddlyFilterList FilterEnum < T > ( this GriddlyColumn column , IEnumerable < T > items , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false )
141
+ public static GriddlyFilterList FilterEnum < T > ( this GriddlyColumn column , IEnumerable < T > items , bool isMultiple = true , bool defaultSelectAll = false , string nullItemText = null , bool isNoneAll = true , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = false , string group = null )
139
142
where T : struct
140
143
{
141
- return column . FilterList ( Extensions . ToSelectListItems ( items ) . OrderBy ( x => x . Text ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption ) ;
144
+ return column . FilterList ( Extensions . ToSelectListItems ( items ) . OrderBy ( x => x . Text ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption , group ) ;
142
145
}
143
146
144
- public static GriddlyFilterList FilterBool ( this GriddlyColumn column , string trueLabel = "Yes" , string falseLabel = "No" , string nullItemText = null , bool isMultiple = false , bool defaultSelectAll = false , bool isNoneAll = false , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = true )
147
+ public static GriddlyFilterList FilterBool ( this GriddlyColumn column , string trueLabel = "Yes" , string falseLabel = "No" , string nullItemText = null , bool isMultiple = false , bool defaultSelectAll = false , bool isNoneAll = false , string field = null , string caption = null , string htmlClass = null , string captionPlural = null , bool displayIncludeCaption = true , string group = null )
145
148
{
146
- return column . FilterList ( BuildBoolItems ( trueLabel , falseLabel ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption ) ;
149
+ return column . FilterList ( BuildBoolItems ( trueLabel , falseLabel ) , isMultiple , defaultSelectAll , nullItemText , isNoneAll , field , caption , htmlClass , captionPlural , displayIncludeCaption , group ) ;
147
150
}
148
151
149
152
static List < SelectListItem > BuildBoolItems ( string trueLabel , string falseLabel )
0 commit comments