@Html.AntiForgeryToken()
@if (Context.Request.Query.ContainsKey("iframe")||(Context.Request.Method=="POST"&&Context.Request.Form.ContainsKey("iframe")))
{
@Html.Hidden("iframe","")
}
@foreach (var prop in props)
{
var metadata = prop as Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.DefaultModelMetadata;
var isReadOnly = metadata.Attributes.Attributes.Any(o => o.GetType() == typeof(ReadOnlyAttribute));
var isDisplayOnly = metadata.Attributes.Attributes.Any(o => o.GetType() == typeof(DisplayOnlyAttribute));
var isHidden = metadata.Attributes.Attributes.Any(o => o.GetType() == typeof(HiddenInputAttribute));
var desc = (metadata.Attributes.Attributes.OfType
().FirstOrDefault() as DescriptionAttribute)?.Description;
var isRequired = metadata.Attributes.Attributes.Any(o => o.GetType() == typeof(RequiredAttribute));
var labelCalss = "col-sm-4 col-form-label" + (isRequired ? " required" : "");
if (prop.PropertyName.EndsWith("Checked") || prop.PropertyName.EndsWith("Comment"))
{
continue;
}
if (isHidden)
{
@Html.Hidden(prop.PropertyName)
continue;
}
if (prop.HideSurroundingHtml || isDisplayOnly)
{
@Html.Hidden(prop.PropertyName)
continue;
}
var uihit = prop.DataTypeName ?? prop.TemplateHint;
}