Ejemplo n.º 1
0
 public static IHtmlContent CheckboxValue(this IHtmlHelper htmlHelper, string expression, bool inline, string value, string text, bool isChecked, object divHtmlAttributes, object inputHtmlAttributes, object labelHtmlAttributes)
 {
     return(SelectListHtmlGenerator.GenerateCheckboxValue(htmlHelper.ViewContext, null, expression, inline, value, text, isChecked, divHtmlAttributes, inputHtmlAttributes, labelHtmlAttributes));
 }
Ejemplo n.º 2
0
        public static IHtmlContent CheckboxValueFor <TModel, TResult>(this IHtmlHelper <TModel> htmlHelper, Expression <Func <TModel, TResult> > expression, bool inline, string value, string text, bool isChecked, object divHtmlAttributes = null, object inputHtmlAttributes = null, object labelHtmlAttributes = null)
        {
            var modelExpression = GetModelExpression(htmlHelper, expression);

            return(SelectListHtmlGenerator.GenerateCheckboxValue(htmlHelper.ViewContext, modelExpression.ModelExplorer, modelExpression.Name, inline, value, text, isChecked, divHtmlAttributes, inputHtmlAttributes, labelHtmlAttributes));
        }