Example #1
0
        public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, object htmlAttributes, bool withoutScript)
        {
            // Create tag builder
            var builder = new TagBuilder("div");

            // Create valid id
            builder.GenerateId(id);

            // Add attributes
            builder.MergeAttributes(new RouteValueDictionary(htmlAttributes));

            // Render tag
            return "<!-- " + id + " Progressbar Control //-->" + "\n    " + builder.ToString(TagRenderMode.Normal)
                + (withoutScript == true ? string.Empty : "\n    " + RenderProgressbar(htmlHelper, new string[] { id }, progressbarType));
        }
Example #2
0
        public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, object htmlAttributes, bool withoutScript)
        {
            // Create tag builder
            var builder = new TagBuilder("div");

            // Create valid id
            builder.GenerateId(id);

            // Add attributes
            builder.MergeAttributes(new RouteValueDictionary(htmlAttributes));

            // Render tag
            return("<!-- " + id + " Progressbar Control //-->" + "\n    " + builder.ToString(TagRenderMode.Normal)
                   + (withoutScript == true ? string.Empty : "\n    " + RenderProgressbar(htmlHelper, new string[] { id }, progressbarType)));
        }
Example #3
0
 public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, object htmlAttributes)
 {
     return(Progressbar(htmlHelper, id, value, progressbarType, htmlAttributes, false /*withoutScript*/));
 }
Example #4
0
 public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, bool withoutScript)
 {
     return(Progressbar(htmlHelper, id, value, progressbarType, null /*htmlAttributes*/, withoutScript));
 }
Example #5
0
        public static string RenderProgressbar(this HtmlHelper htmlHelper, string[] progressbarIds, ProgressbarTypes progressbarType)
        {
            switch (progressbarType)
            {
            case ProgressbarTypes.Recommendation:
                return(RenderProgressbar(htmlHelper, progressbarIds, new {  }));

            case ProgressbarTypes.DefaultFuntionality:
                return(RenderProgressbar(htmlHelper, progressbarIds, new { }));

            default:        // Recommendation
                return(RenderProgressbar(htmlHelper, progressbarIds, new { }));
            }
        }
Example #6
0
 public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, object htmlAttributes)
 {
     return Progressbar(htmlHelper, id, value, progressbarType, htmlAttributes, false/*withoutScript*/);
 }
Example #7
0
 public static string Progressbar(this HtmlHelper htmlHelper, string id, string value, ProgressbarTypes progressbarType, bool withoutScript)
 {
     return Progressbar(htmlHelper, id, value, progressbarType, null/*htmlAttributes*/, withoutScript);
 }
Example #8
0
 public static string RenderProgressbar(this HtmlHelper htmlHelper, string[] progressbarIds, ProgressbarTypes progressbarType)
 {
     switch (progressbarType)
     {
         case ProgressbarTypes.Recommendation:
             return RenderProgressbar(htmlHelper, progressbarIds, new {  });
         case ProgressbarTypes.DefaultFuntionality:
             return RenderProgressbar(htmlHelper, progressbarIds, new { });
         default:    // Recommendation
             return RenderProgressbar(htmlHelper, progressbarIds, new { });
     }
 }