/// <summary>
 /// Renders the model state in the current form.
 /// </summary>
 public static MvcHtmlString ModelState(this HtmlHelper html)
 {
     string serializedModel = new MvcSerializer().Serialize(html.ViewData.Model);
     return html.Hidden(BaseController<object>.ModelStateKey, serializedModel);
 }
        /// <summary>
        /// Renders the model state in the current form.
        /// </summary>
        public static MvcHtmlString ModelState(this HtmlHelper html)
        {
            string serializedModel = new MvcSerializer().Serialize(html.ViewData.Model);

            return(html.Hidden(BaseController <object> .ModelStateKey, serializedModel));
        }