示例#1
0
        public virtual IHtmlContent GetInputControl(string componentName)
        {
            InputModel.Attributes += AddInputControlAttributes();
            InputModel.Attributes += RazorUtils.ToAttributeString(InputModel.AttributeObject);
            InputModel.Attributes += RazorUtils.ToAttributeStringDynamic(InputModelExtraAttrs);
            string template = Helper.GetTheme().GetInputControl(componentName);

            return(Partial(template, InputModel));
        }
示例#2
0
 public virtual IHtmlContent Write(string componentName, bool localizable = false)
 {
     if (InputModel != null)
     {
         InputModel.Attributes += AddInputControlAttributes();
         InputModel.Attributes += RazorUtils.ToAttributeString(InputModel.AttributeObject);
         return(Partial(Helper.GetTheme().GetTemplate(componentName), InputModel));
     }
     else if (Model != null)
     {
         return(Partial(Helper.GetTheme().GetTemplate(componentName), InputModel));
     }
     return(Partial(Helper.GetTheme().GetTemplate(componentName)));
 }