Пример #1
0
 private static HtmlBuilder DisplayControl(this HtmlBuilder hb, string id, string icon)
 {
     return(hb.Div(
                attributes: new HtmlAttributes()
                .Id(id)
                .Class("display-control")
                .OnClick("$p.send($(this));")
                .DataMethod("post"),
                action: () => hb
                .Span(css: "ui-icon " + icon)
                .Text(text: Displays.Aggregations() + ":")));
 }
Пример #2
0
 private static HtmlBuilder DisplayControl(
     this HtmlBuilder hb,
     Context context,
     View view,
     string id,
     string icon)
 {
     if (view?.AggregationsDisplayType == View.DisplayTypes.AlwaysDisplayed)
     {
         return(hb);
     }
     return(hb.Div(
                attributes: new HtmlAttributes()
                .Id(id)
                .Class("display-control")
                .OnClick("$p.send($(this));")
                .DataMethod("post"),
                action: () => hb
                .Span(css: "ui-icon " + icon)
                .Text(text: Displays.Aggregations(context: context) + ":")));
 }