Add registration workflow

Update unobtrusive Validation
This commit is contained in:
2020-01-10 14:52:11 -05:00
parent e0464cb77c
commit 8452a9cce0
34 changed files with 235 additions and 898 deletions
@@ -1,29 +1,30 @@
@using LeafWeb.WebCms.Utility
@model object
@{
Layout = "~/Views/Shared/EditorTemplates/_FieldLayout.cshtml";
Layout = "_FieldLayout.cshtml";
}
@{
var htmlAttributes = new RouteValueDictionary();
htmlAttributes.Add("type", "email");
var controlClass = "form-control";
if (ViewBag.@class != null)
{
htmlAttributes.Add("class", "form-control " + ViewBag.@class);
}
else
{
htmlAttributes.Add("class", "form-control");
}
if (ViewBag.@type != null)
{
htmlAttributes.Add("type", ViewBag.@type);
}
else
{
htmlAttributes.Add("type", "email");
controlClass = string.Concat(controlClass, " ", ViewBag.@class);
}
if (ViewBag.placeholder != null)
{
htmlAttributes.Add("placeholder", ViewBag.placeholder);
}
if (Html.HasError())
{
controlClass = string.Concat(controlClass, " ", "is-invalid");
}
htmlAttributes.Add("class", controlClass);
}
@Html.TextBox("", ViewData.TemplateInfo.FormattedModelValue, htmlAttributes)