Search in sources :

Example 1 with RenderReportHtml

use of org.activityinfo.legacy.shared.command.RenderReportHtml in project activityinfo by bedatadriven.

the class ElementWidget method loadHtml.

private void loadHtml() {
    contentElement.setInnerHTML("");
    loadingElement.getStyle().setDisplay(Display.BLOCK);
    if (model instanceof TextReportElement) {
        renderStaticHtml();
    } else {
        dispatcher.execute(new RenderReportHtml(model), new AsyncCallback<HtmlResult>() {

            @Override
            public void onFailure(Throwable caught) {
            // TODO Auto-generated method stub
            }

            @Override
            public void onSuccess(HtmlResult result) {
                updateHtml(result.getHtml());
            }
        });
    }
}
Also used : HtmlResult(org.activityinfo.legacy.shared.command.result.HtmlResult) RenderReportHtml(org.activityinfo.legacy.shared.command.RenderReportHtml) TextReportElement(org.activityinfo.legacy.shared.reports.model.TextReportElement)

Aggregations

RenderReportHtml (org.activityinfo.legacy.shared.command.RenderReportHtml)1 HtmlResult (org.activityinfo.legacy.shared.command.result.HtmlResult)1 TextReportElement (org.activityinfo.legacy.shared.reports.model.TextReportElement)1