1 implementation of ViewData
Microsoft.AspNetCore.Mvc.ViewFeatures (1)
HtmlHelper.cs (1)
113
public ViewDataDictionary
ViewData
=> ViewContext.ViewData;
104 references to ViewData
Microsoft.AspNetCore.Mvc.ViewFeatures (104)
DefaultDisplayTemplates.cs (27)
21
if (htmlHelper.
ViewData
.Model != null)
23
value = Convert.ToBoolean(htmlHelper.
ViewData
.Model, CultureInfo.InvariantCulture);
26
return htmlHelper.
ViewData
.ModelMetadata.IsNullableValueType ?
74
var model = htmlHelper.
ViewData
.Model;
88
var elementMetadata = htmlHelper.
ViewData
.ModelMetadata.ElementMetadata;
101
var oldPrefix = htmlHelper.
ViewData
.TemplateInfo.HtmlFieldPrefix;
104
htmlHelper.
ViewData
.TemplateInfo.HtmlFieldPrefix = string.Empty;
122
container: htmlHelper.
ViewData
.ModelExplorer,
131
htmlHelper.
ViewData
,
144
htmlHelper.
ViewData
.TemplateInfo.HtmlFieldPrefix = oldPrefix;
150
if (htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue == htmlHelper.
ViewData
.Model)
152
htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue =
153
string.Format(CultureInfo.CurrentCulture, "{0:0.00}", htmlHelper.
ViewData
.Model);
161
var uriString = "mailto:" + ((htmlHelper.
ViewData
.Model == null) ?
163
htmlHelper.
ViewData
.Model.ToString());
164
var linkedText = (htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue == null) ?
166
htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue.ToString();
173
if (htmlHelper.
ViewData
.ModelMetadata.HideSurroundingHtml)
183
return new HtmlString(htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue.ToString());
188
var viewData = htmlHelper.
ViewData
;
225
htmlHelper.
ViewData
,
268
var value = htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue;
279
var uriString = (htmlHelper.
ViewData
.Model == null) ? string.Empty : htmlHelper.
ViewData
.Model.ToString();
280
var linkedText = (htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue == null) ?
282
htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue.ToString();
DefaultEditorTemplates.cs (22)
27
if (htmlHelper.
ViewData
.Model != null)
29
value = Convert.ToBoolean(htmlHelper.
ViewData
.Model, CultureInfo.InvariantCulture);
32
return htmlHelper.
ViewData
.ModelMetadata.IsNullableValueType ?
56
var viewData = htmlHelper.
ViewData
;
71
var elementMetadata = htmlHelper.
ViewData
.ModelMetadata.ElementMetadata;
105
container: htmlHelper.
ViewData
.ModelExplorer,
114
htmlHelper.
ViewData
,
133
if (htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue == htmlHelper.
ViewData
.Model)
135
htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue =
136
string.Format(CultureInfo.CurrentCulture, "{0:0.00}", htmlHelper.
ViewData
.Model);
144
var viewData = htmlHelper.
ViewData
;
174
var htmlAttributesObject = htmlHelper.
ViewData
[HtmlAttributeKey];
231
var viewData = htmlHelper.
ViewData
;
268
htmlHelper.
ViewData
,
318
value = htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue;
412
return GenerateTextBox(htmlHelper, htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue, htmlAttributes);
422
var metadata = htmlHelper.
ViewData
.ModelMetadata;
423
var value = htmlHelper.
ViewData
.Model;
424
if (htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue != value && metadata.HasNonDefaultEditFormat)
431
htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue =
438
return GenerateTextBox(htmlHelper, inputType, htmlHelper.
ViewData
.TemplateInfo.FormattedModelValue);
Rendering\HtmlHelperInputExtensions.cs (16)
19
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
44
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
73
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
130
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
154
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
277
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
309
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
349
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
417
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
441
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
469
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
502
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name,
629
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
654
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
686
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
714
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
Rendering\HtmlHelperPartialExtensions.cs (8)
32
return htmlHelper.PartialAsync(partialViewName, htmlHelper.
ViewData
.Model, viewData: null);
55
return htmlHelper.PartialAsync(partialViewName, htmlHelper.
ViewData
.Model, viewData);
97
return Partial(htmlHelper, partialViewName, htmlHelper.
ViewData
.Model, viewData: null);
120
return Partial(htmlHelper, partialViewName, htmlHelper.
ViewData
.Model, viewData);
184
RenderPartial(htmlHelper, partialViewName, htmlHelper.
ViewData
.Model, viewData: null);
203
RenderPartial(htmlHelper, partialViewName, htmlHelper.
ViewData
.Model, viewData);
265
return htmlHelper.RenderPartialAsync(partialViewName, htmlHelper.
ViewData
.Model, viewData: null);
288
return htmlHelper.RenderPartialAsync(partialViewName, htmlHelper.
ViewData
.Model, viewData);
Rendering\HtmlHelperSelectExtensions.cs (18)
16
/// <option> elements based on the <see cref="IHtmlHelper.
ViewData
"/> entry with full name. Adds a
33
/// The <see cref="IHtmlHelper.
ViewData
"/> entry with full name must be a non-<c>null</c> collection of
46
/// <option> elements based on <paramref name="optionLabel"/> and the <see cref="IHtmlHelper.
ViewData
"/>
67
/// The <see cref="IHtmlHelper.
ViewData
"/> entry with full name must be a non-<c>null</c> collection of
91
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name (unless used instead of
100
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
125
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name (unless used instead of
134
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
164
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name (unless used instead of
173
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
209
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
244
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
288
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
316
/// <option> elements based on the <see cref="IHtmlHelper.
ViewData
"/> entry with full name. Adds a
333
/// The <see cref="IHtmlHelper.
ViewData
"/> entry with full name must be a non-<c>null</c> collection of
350
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name (unless used instead of
359
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
391
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="IHtmlHelper.
ViewData
"/>
Rendering\HtmlHelperValueExtensions.cs (3)
17
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
63
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
83
/// the <see cref="IHtmlHelper.
ViewData
"/> entry with full name, or
Rendering\IHtmlHelper.cs (10)
173
/// the <see cref="
ViewData
"/> entry with full name, or
257
/// the <see cref="
ViewData
"/> entry with full name (unless used instead of <paramref name="selectList"/>), or
264
/// <optgroup> and <option> elements. If <c>null</c>, uses the <see cref="
ViewData
"/> entry with
404
/// the <see cref="
ViewData
"/> entry with full name,
448
/// the <see cref="
ViewData
"/> entry with full name (unless used instead of <paramref name="selectList"/>), or
456
/// collection with name <paramref name="expression"/> in <see cref="
ViewData
"/>.
522
/// the <see cref="
ViewData
"/> entry with full name, or
615
/// the <see cref="
ViewData
"/> entry with full name, or
640
/// the <see cref="
ViewData
"/> entry with full name,
719
/// the <see cref="
ViewData
"/> entry with full name, or