104 instantiations of SelectListItem
IdentitySample.Mvc (1)
Controllers\AccountController.cs (1)
355
var factorOptions = userFactors.Select(purpose => new
SelectListItem
{ Text = purpose, Value = purpose }).ToList();
Microsoft.AspNetCore.Mvc.TagHelpers.Test (1)
SelectTagHelperTest.cs (1)
95
var arrayItems = new[] { new
SelectListItem
() };
Microsoft.AspNetCore.Mvc.ViewFeatures (7)
DefaultDisplayTemplates.cs (3)
66
new
SelectListItem
(Resources.Common_TriState_NotSet, string.Empty, !value.HasValue),
67
new
SelectListItem
(Resources.Common_TriState_True, "true", (value == true)),
68
new
SelectListItem
(Resources.Common_TriState_False, "false", (value == false)),
DefaultHtmlGenerator.cs (1)
1581
new
SelectListItem
()
HtmlHelper.cs (1)
1385
var selectListItem = new
SelectListItem
Rendering\MultiSelectList.cs (2)
164
var newListItem = new
SelectListItem
189
var newListItem = new
SelectListItem
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (95)
Rendering\HtmlHelperDropDownListExtensionsTest.cs (16)
14
new
SelectListItem
("Zero", "0"),
15
new
SelectListItem
("One", "1"),
16
new
SelectListItem
("Two", "2"),
17
new
SelectListItem
("Three", "3"),
77
new
SelectListItem
("Four", "4"),
78
new
SelectListItem
("Five", "5"),
102
new
SelectListItem
("Four", "4"),
103
new
SelectListItem
("Five", "5"),
129
new
SelectListItem
("Four", "4"),
130
new
SelectListItem
("Five", "5"),
177
new
SelectListItem
("Four", "4"),
178
new
SelectListItem
("Five", "5"),
203
new
SelectListItem
("Four", "4"),
204
new
SelectListItem
("Five", "5"),
229
new
SelectListItem
("Four", "4"),
230
new
SelectListItem
("Five", "5"),
Rendering\HtmlHelperListBoxExtensionsTest.cs (12)
14
new
SelectListItem
("Zero", "0"),
15
new
SelectListItem
("One", "1"),
16
new
SelectListItem
("Two", "2"),
17
new
SelectListItem
("Three", "3"),
53
new
SelectListItem
("Four", "4"),
54
new
SelectListItem
("Five", "5"),
78
new
SelectListItem
("Four", "4"),
79
new
SelectListItem
("Five", "5"),
125
new
SelectListItem
("Four", "4"),
126
new
SelectListItem
("Five", "5"),
150
new
SelectListItem
("Four", "4"),
151
new
SelectListItem
("Five", "5"),
Rendering\HtmlHelperSelectTest.cs (67)
29
new
SelectListItem
("Zero", "0"),
30
new
SelectListItem
("One", "1"),
31
new
SelectListItem
("Two", "2"),
32
new
SelectListItem
("Three", "3"),
36
new
SelectListItem
("Zero", "0", false, false),
37
new
SelectListItem
("One", "1", true, true),
38
new
SelectListItem
("Two", "2", false, false),
39
new
SelectListItem
("Three", "3", false, true),
43
new
SelectListItem
("Zero", "0", true) { Group = GroupOne },
44
new
SelectListItem
("One", "1", false) { Group = GroupTwo },
45
new
SelectListItem
("Two", "2", true) { Group = GroupOne },
46
new
SelectListItem
("Three", "3", false) { Group = null },
50
new
SelectListItem
("Zero", "0", true) { Group = GroupOne },
51
new
SelectListItem
("One", "1", true) { Group = GroupOne },
52
new
SelectListItem
("Two", "2", false) { Group = GroupOne },
53
new
SelectListItem
("Three", "3", false) { Group = GroupOne },
57
new
SelectListItem
("Zero", "0", true) { Group = DisabledGroup },
58
new
SelectListItem
("One", "1", true) { Group = DisabledGroup },
59
new
SelectListItem
("Two", "2", true) { Group = DisabledGroup },
60
new
SelectListItem
("Three", "3", true) { Group = DisabledGroup },
64
new
SelectListItem
{ Text = SelectSources.ModelStateEntry.ToString() },
65
new
SelectListItem
{ Text = SelectSources.ModelStateEntryWithPrefix.ToString() },
66
new
SelectListItem
{ Text = SelectSources.ViewDataEntry.ToString() },
67
new
SelectListItem
{ Text = SelectSources.PropertyOfViewDataEntry.ToString() },
68
new
SelectListItem
{ Text = SelectSources.ViewDataEntryWithPrefix.ToString() },
69
new
SelectListItem
{ Text = SelectSources.PropertyOfViewDataEntryWithPrefix.ToString() },
70
new
SelectListItem
{ Text = SelectSources.ModelValue.ToString() },
71
new
SelectListItem
{ Text = SelectSources.PropertyOfModel.ToString() },
1414
new
SelectListItem
{ Text = "cero", Value = "0" },
1415
new
SelectListItem
{ Text = nameof(EnumWithDisplayNames.One), Value = "1" },
1416
new
SelectListItem
{ Text = "dos", Value = "2" },
1417
new
SelectListItem
{ Text = "tres", Value = "3" },
1418
new
SelectListItem
{ Text = "name from resources", Value = "-2" },
1419
new
SelectListItem
{ Text = "menos uno", Value = "-1" },
1426
new
SelectListItem
{ Text = "cero", Value = "0" },
1427
new
SelectListItem
{ Text = nameof(EnumWithDisplayNames.One), Value = "1" },
1428
new
SelectListItem
{ Text = "dos", Value = "2" },
1429
new
SelectListItem
{ Text = "tres", Value = "3" },
1430
new
SelectListItem
{ Text = "name from resources", Value = "-2" },
1431
new
SelectListItem
{ Text = "menos uno", Value = "-1" },
1438
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Zero), Value = "0" },
1439
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.None), Value = "0" },
1440
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.One), Value = "1" },
1441
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Duece), Value = "2" },
1442
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Two), Value = "2" },
1443
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.MoreThanTwo), Value = "3" },
1444
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Three), Value = "3" },
1451
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Zero), Value = "0" },
1452
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.None), Value = "0" },
1453
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.One), Value = "1" },
1454
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Duece), Value = "2" },
1455
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Two), Value = "2" },
1456
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.MoreThanTwo), Value = "3" },
1457
new
SelectListItem
{ Text = nameof(EnumWithDuplicates.Three), Value = "3" },
1464
new
SelectListItem
{ Text = nameof(EnumWithFields.Zero), Value = "0" },
1465
new
SelectListItem
{ Text = nameof(EnumWithFields.One), Value = "1" },
1466
new
SelectListItem
{ Text = nameof(EnumWithFields.Two), Value = "2" },
1467
new
SelectListItem
{ Text = nameof(EnumWithFields.Three), Value = "3" },
1468
new
SelectListItem
{ Text = nameof(EnumWithFields.MinusTwo), Value = "-2" },
1469
new
SelectListItem
{ Text = nameof(EnumWithFields.MinusOne), Value = "-1" },
1476
new
SelectListItem
{ Text = nameof(EnumWithFields.Zero), Value = "0" },
1477
new
SelectListItem
{ Text = nameof(EnumWithFields.One), Value = "1" },
1478
new
SelectListItem
{ Text = nameof(EnumWithFields.Two), Value = "2" },
1479
new
SelectListItem
{ Text = nameof(EnumWithFields.Three), Value = "3" },
1480
new
SelectListItem
{ Text = nameof(EnumWithFields.MinusTwo), Value = "-2" },
1481
new
SelectListItem
{ Text = nameof(EnumWithFields.MinusOne), Value = "-1" },
1600
var copy = new
SelectListItem
248 references to SelectListItem
HtmlGenerationWebSite (2)
Controllers\HtmlGeneration_HomeController.cs (2)
32
private readonly IEnumerable<
SelectListItem
> _productsList;
33
private readonly IEnumerable<
SelectListItem
> _productsListWithSelection;
IdentitySample.Mvc (2)
Models\AccountViewModels\SendCodeViewModel.cs (1)
12
public ICollection<
SelectListItem
> Providers { get; set; }
Models\ManageViewModels\ConfigureTwoFactorViewModel.cs (1)
12
public ICollection<
SelectListItem
> Providers { get; set; }
Microsoft.AspNetCore.Mvc.TagHelpers (3)
SelectTagHelper.cs (3)
57
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
61
public IEnumerable<
SelectListItem
> Items { get; set; }
124
var items = Items ?? Enumerable.Empty<
SelectListItem
>();
Microsoft.AspNetCore.Mvc.TagHelpers.Test (11)
SelectTagHelperTest.cs (11)
90
public static TheoryData<IEnumerable<
SelectListItem
>, string, string, IEnumerable<
SelectListItem
>>
96
var listItems = new List<
SelectListItem
>();
101
new[] { (IEnumerable<
SelectListItem
>)null, Enumerable.Empty<
SelectListItem
>() },
129
new TheoryData<IEnumerable<
SelectListItem
>, string, string, IEnumerable<
SelectListItem
>>();
539
IEnumerable<
SelectListItem
> inputItems,
542
IEnumerable<
SelectListItem
> expectedItems)
675
It.IsAny<IEnumerable<
SelectListItem
>>(),
786
var selectList = Array.Empty<
SelectListItem
>();
Microsoft.AspNetCore.Mvc.ViewFeatures (149)
DefaultDisplayTemplates.cs (3)
53
foreach (
var
item in TriStateValues(value))
62
internal static List<
SelectListItem
> TriStateValues(bool? value)
64
return new List<
SelectListItem
>
DefaultHtmlGenerator.cs (15)
510
IEnumerable<
SelectListItem
> selectList,
534
IEnumerable<
SelectListItem
> selectList,
919
if (rawValue is IEnumerable<
SelectListItem
>)
1036
internal static TagBuilder GenerateOption(
SelectListItem
item, string text)
1041
internal static TagBuilder GenerateOption(
SelectListItem
item, string text, bool selected)
1485
private static IEnumerable<
SelectListItem
> GetSelectListItems(
1500
$"IEnumerable<{nameof(
SelectListItem
)}>",
1505
if (!(value is IEnumerable<
SelectListItem
> selectList))
1510
$"IEnumerable<{nameof(
SelectListItem
)}>"));
1548
public IHtmlContent GenerateGroupsAndOptions(string optionLabel, IEnumerable<
SelectListItem
> selectList)
1555
IEnumerable<
SelectListItem
> selectList,
1558
if (!(selectList is IList<
SelectListItem
> itemsList))
1598
var
item = itemsList[i];
1617
var
groupItem = itemsList[j];
1640
private static IHtmlContent GenerateOption(
SelectListItem
item, ICollection<string> currentValues)
HtmlHelper.cs (10)
337
IEnumerable<
SelectListItem
> selectList,
366
public IEnumerable<
SelectListItem
> GetEnumSelectList<TEnum>() where TEnum : struct
383
public IEnumerable<
SelectListItem
> GetEnumSelectList(Type enumType)
429
public IHtmlContent ListBox(string expression, IEnumerable<
SelectListItem
> selectList, object htmlAttributes)
819
IEnumerable<
SelectListItem
> selectList,
1085
/// <param name="selectList">An enumeration of <see cref="
SelectListItem
"/>.</param>
1094
IEnumerable<
SelectListItem
> selectList,
1368
protected virtual IEnumerable<
SelectListItem
> GetEnumSelectList(ModelMetadata metadata)
1381
var selectList = new List<
SelectListItem
>();
1385
var
selectListItem = new SelectListItem
HtmlHelperOfT.cs (2)
108
IEnumerable<
SelectListItem
> selectList,
226
IEnumerable<
SelectListItem
> selectList,
IHtmlGenerator.cs (7)
368
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
396
IEnumerable<
SelectListItem
> selectList,
411
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
417
/// <c>null</c>, selects <option> elements based on <see cref="
SelectListItem
.Selected"/> values in
445
IEnumerable<
SelectListItem
> selectList,
455
/// A collection of <see cref="
SelectListItem
"/> objects used to generate <optgroup> and <option>
461
IHtmlContent GenerateGroupsAndOptions(string optionLabel, IEnumerable<
SelectListItem
> selectList);
Rendering\HtmlHelperSelectExtensions.cs (49)
17
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
18
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
34
/// <see cref="
SelectListItem
"/> objects.
48
/// <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or <see cref="
SelectListItem
.Text"/> matches the
68
/// <see cref="
SelectListItem
"/> objects.
88
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
89
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
99
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
101
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
112
IEnumerable<
SelectListItem
> selectList)
122
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
123
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
133
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
135
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
150
IEnumerable<
SelectListItem
> selectList,
161
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
162
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
172
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
174
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
188
IEnumerable<
SelectListItem
> selectList,
199
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
200
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
208
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
210
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
223
IEnumerable<
SelectListItem
> selectList)
234
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
235
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
243
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
245
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
262
IEnumerable<
SelectListItem
> selectList,
278
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
279
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
287
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
289
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
305
IEnumerable<
SelectListItem
> selectList,
317
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
318
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
334
/// <see cref="
SelectListItem
"/> objects.
347
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
348
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
358
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
360
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
371
IEnumerable<
SelectListItem
> selectList)
381
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
382
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
390
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
392
/// entry with full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
405
IEnumerable<
SelectListItem
> selectList)
Rendering\IHtmlHelper.cs (14)
254
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
255
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
263
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
265
/// full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
282
IEnumerable<
SelectListItem
> selectList,
376
/// with a decimal representation of the ordinal as <see cref="
SelectListItem
.Value"/>
377
/// and the display name as <see cref="
SelectListItem
.Text"/>.
383
IEnumerable<
SelectListItem
> GetEnumSelectList<TEnum>() where TEnum : struct;
397
IEnumerable<
SelectListItem
> GetEnumSelectList(Type enumType);
445
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
446
/// <see cref="
SelectListItem
.Text"/> matches an entry in the first non-<c>null</c> collection found in:
454
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
455
/// <optgroup> and <option> elements. If <c>null</c>, finds the <see cref="
SelectListItem
"/>
468
IHtmlContent ListBox(string expression, IEnumerable<
SelectListItem
> selectList, object htmlAttributes);
Rendering\IHtmlHelperOfT.cs (10)
116
/// "selected" attribute to an <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
117
/// <see cref="
SelectListItem
.Text"/> matches the first non-<c>null</c> value found in:
124
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
126
/// full name and that entry must be a collection of <see cref="
SelectListItem
"/> objects.
144
IEnumerable<
SelectListItem
> selectList,
238
/// <option> if its <see cref="
SelectListItem
.Value"/> (if non-<c>null</c>) or
239
/// <see cref="
SelectListItem
.Text"/> matches an entry in the first non-<c>null</c> collection found in:
246
/// A collection of <see cref="
SelectListItem
"/> objects used to populate the <select> element with
247
/// <optgroup> and <option> elements. If <c>null</c>, finds the <see cref="
SelectListItem
"/>
263
IEnumerable<
SelectListItem
> selectList,
Rendering\MultiSelectList.cs (16)
14
/// of <see cref="
SelectListItem
"/> objects.
16
public class MultiSelectList : IEnumerable<
SelectListItem
>
19
private IList<
SelectListItem
> _selectListItems;
75
/// <param name="items">The items used to build each <see cref="
SelectListItem
"/> of the list.</param>
77
/// <see cref="
SelectListItem
"/>.</param>
79
/// <see cref="
SelectListItem
"/>.</param>
81
/// corresponding <see cref="
SelectListItem
"/>.</param>
83
/// <see cref="
SelectListItem
"/>.</param>
131
public virtual IEnumerator<
SelectListItem
> GetEnumerator()
141
private IList<
SelectListItem
> GetListItems()
148
private IList<
SelectListItem
> GetListItemsWithValueField()
160
var listItems = new List<
SelectListItem
>();
164
var
newListItem = new SelectListItem
178
private IList<
SelectListItem
> GetListItemsWithoutValueField()
186
var listItems = new List<
SelectListItem
>();
189
var
newListItem = new SelectListItem
Rendering\SelectList.cs (6)
11
/// of <see cref="
SelectListItem
"/> objects.
71
/// <param name="items">The items used to build each <see cref="
SelectListItem
"/> of the list.</param>
73
/// <see cref="
SelectListItem
"/>.</param>
75
/// <see cref="
SelectListItem
"/>.</param>
77
/// <see cref="
SelectListItem
"/>.</param>
79
/// <see cref="
SelectListItem
"/>.</param>
Rendering\SelectListItem.cs (17)
14
/// Initializes a new instance of <see cref="
SelectListItem
"/>.
19
/// Initializes a new instance of <see cref="
SelectListItem
"/>.
21
/// <param name="text">The display text of this <see cref="
SelectListItem
"/>.</param>
22
/// <param name="value">The value of this <see cref="
SelectListItem
"/>.</param>
31
/// Initializes a new instance of <see cref="
SelectListItem
"/>.
33
/// <param name="text">The display text of this <see cref="
SelectListItem
"/>.</param>
34
/// <param name="value">The value of this <see cref="
SelectListItem
"/>.</param>
35
/// <param name="selected">Value that indicates whether this <see cref="
SelectListItem
"/> is selected.</param>
43
/// Initializes a new instance of <see cref="
SelectListItem
"/>.
45
/// <param name="text">The display text of this <see cref="
SelectListItem
"/>.</param>
46
/// <param name="value">The value of this <see cref="
SelectListItem
"/>.</param>
47
/// <param name="selected">Value that indicates whether this <see cref="
SelectListItem
"/> is selected.</param>
48
/// <param name="disabled">Value that indicates whether this <see cref="
SelectListItem
"/> is disabled.</param>
56
/// Gets or sets a value that indicates whether this <see cref="
SelectListItem
"/> is disabled.
70
/// Gets or sets a value that indicates whether this <see cref="
SelectListItem
"/> is selected.
77
/// Gets or sets a value that indicates the display text of this <see cref="
SelectListItem
"/>.
83
/// Gets or sets a value that indicates the value of this <see cref="
SelectListItem
"/>.
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (81)
DefaultEditorTemplatesTest.cs (4)
1474
IEnumerable<
SelectListItem
> selectList,
1515
public IEnumerable<
SelectListItem
> GetEnumSelectList<TEnum>() where TEnum : struct
1520
public IEnumerable<
SelectListItem
> GetEnumSelectList(Type enumType)
1540
public IHtmlContent ListBox(string name, IEnumerable<
SelectListItem
> selectList, object htmlAttributes)
DefaultHtmlGeneratorTest.cs (3)
100
selectList: new List<
SelectListItem
>(),
127
selectList: new List<
SelectListItem
>(),
499
viewContext.ViewData[nameof(Model.Name)] = Enumerable.Empty<
SelectListItem
>();
Rendering\HtmlHelperDropDownListExtensionsTest.cs (8)
12
private static readonly List<
SelectListItem
> BasicSelectList = new List<
SelectListItem
>
75
var selectList = new List<
SelectListItem
>
100
var selectList = new List<
SelectListItem
>
127
var selectList = new List<
SelectListItem
>
175
var selectList = new List<
SelectListItem
>
201
var selectList = new List<
SelectListItem
>
227
var selectList = new List<
SelectListItem
>
Rendering\HtmlHelperListBoxExtensionsTest.cs (6)
12
private static readonly List<
SelectListItem
> BasicSelectList = new List<
SelectListItem
>
51
var selectList = new List<
SelectListItem
>
76
var selectList = new List<
SelectListItem
>
123
var selectList = new List<
SelectListItem
>
148
var selectList = new List<
SelectListItem
>
Rendering\HtmlHelperSelectTest.cs (60)
27
private static readonly List<
SelectListItem
> BasicSelectList = new List<
SelectListItem
>
34
private static readonly List<
SelectListItem
> SomeDisabledOneSelectedSelectList = new List<
SelectListItem
>
41
private static readonly List<
SelectListItem
> SomeGroupedSomeSelectedSelectList = new List<
SelectListItem
>
48
private static readonly List<
SelectListItem
> OneGroupSomeSelectedSelectList = new List<
SelectListItem
>
55
private static readonly List<
SelectListItem
> OneDisabledGroupAllSelectedSelectList = new List<
SelectListItem
>
62
private static readonly List<
SelectListItem
> SourcesSelectList = new List<
SelectListItem
>
75
public static TheoryData<IEnumerable<
SelectListItem
>, string, string> DropDownListDataSet
79
return new TheoryData<IEnumerable<
SelectListItem
>, string, string>
178
public static TheoryData<IEnumerable<
SelectListItem
>, string, string, string> ListBoxDataSet
182
return new TheoryData<IEnumerable<
SelectListItem
>, string, string, string>
321
IEnumerable<
SelectListItem
> selectList,
348
IEnumerable<
SelectListItem
> selectList,
368
IEnumerable<
SelectListItem
> selectList,
388
IEnumerable<
SelectListItem
> selectList,
594
IEnumerable<
SelectListItem
> selectList,
617
IEnumerable<
SelectListItem
> selectList,
641
IEnumerable<
SelectListItem
> selectList,
665
IEnumerable<
SelectListItem
> selectList,
741
IEnumerable<
SelectListItem
> selectList,
769
IEnumerable<
SelectListItem
> selectList,
790
IEnumerable<
SelectListItem
> selectList,
997
IEnumerable<
SelectListItem
> selectList,
1017
IEnumerable<
SelectListItem
> selectList,
1062
IEnumerable<
SelectListItem
> selectList,
1083
IEnumerable<
SelectListItem
> selectList,
1115
IEnumerable<
SelectListItem
> selectList,
1139
IEnumerable<
SelectListItem
> selectList,
1159
IEnumerable<
SelectListItem
> selectList,
1179
IEnumerable<
SelectListItem
> selectList,
1208
IEnumerable<
SelectListItem
> selectList,
1230
IEnumerable<
SelectListItem
> selectList,
1251
IEnumerable<
SelectListItem
> selectList,
1320
var
zeroSelect = Assert.Single(result, s => s.Value.Equals("0", StringComparison.Ordinal));
1402
public static TheoryData<Type, IEnumerable<
SelectListItem
>> GetEnumSelectListData
1406
return new TheoryData<Type, IEnumerable<
SelectListItem
>>
1408
{ typeof(EmptyEnum), Enumerable.Empty<
SelectListItem
>() },
1409
{ typeof(EmptyEnum?), Enumerable.Empty<
SelectListItem
>() },
1412
new List<
SelectListItem
>
1424
new List<
SelectListItem
>
1436
new List<
SelectListItem
>
1449
new List<
SelectListItem
>
1462
new List<
SelectListItem
>
1474
new List<
SelectListItem
>
1490
public void GetEnumSelectList_ReturnsExpectedItems(Type type, IEnumerable<
SelectListItem
> expected)
1553
private void VerifySelectList(IEnumerable<
SelectListItem
> expected, IEnumerable<
SelectListItem
> actual)
1559
var
expectedItem = expected.ElementAt(i);
1560
var
actualItem = actual.ElementAt(i);
1585
public IEnumerable<
SelectListItem
> SelectListItems { get; private set; }
1587
public IEnumerable<
SelectListItem
> CopiedSelectListItems { get; private set; }
1589
protected override IEnumerable<
SelectListItem
> GetEnumSelectList(ModelMetadata metadata)
1596
var copiedSelectListItems = new List<
SelectListItem
>();
1598
foreach (
var
item in SelectListItems)
1600
var
copy = new SelectListItem