Exemple #1
0
 public void AddButtonToLeftToolbar(Action<bsTreeToolbarButton> settings)
 {
     var button = new bsTreeToolbarButton(Model);
     button.Tree = this;
     settings(button);
     leftToolbar.Add(button);
 }
        public static MvcHtmlString bsTreeToolbarButton(this HtmlHelper helper, Action<bsTreeToolbarButton> settings)
        {
            var Settings = new bsTreeToolbarButton(helper.ViewData.Model as BaseModel);
            settings(Settings);

            (helper.ViewData.Model as BaseModel).Helper = helper;
            //var script = new StringBuilder();
            //var html = new StringBuilder();

            return new MvcHtmlString(Settings.GetHtml());
            //return new MvcHtmlString(Settings.EmitScriptAndHtml(script, html));
        }