Search in sources :

Example 1 with GetRichTaskResultsByTask

use of cz.metacentrum.perun.webgui.json.propagationStatsReader.GetRichTaskResultsByTask in project perun by CESNET.

the class TaskResultsTabItem method draw.

public Widget draw() {
    this.titleWidget.setText("Tasks results: " + task.getExecService().getService().getName() + " " + task.getExecService().getType());
    VerticalPanel vp = new VerticalPanel();
    vp.setSize("100%", "100%");
    final GetRichTaskResultsByTask callback = new GetRichTaskResultsByTask(task.getId());
    TabMenu menu = new TabMenu();
    menu.addWidget(UiElements.getRefreshButton(this));
    menu.addFilterWidget(new ExtendedSuggestBox(callback.getOracle()), new PerunSearchEvent() {

        @Override
        public void searchFor(String text) {
            callback.filterTable(text);
        }
    }, "Filter results by destination");
    CellTable<TaskResult> table = callback.getTable();
    table.addStyleName("perun-table");
    ScrollPanel sp = new ScrollPanel(table);
    sp.addStyleName("perun-tableScrollPanel");
    vp.add(menu);
    vp.setCellHeight(menu, "30px");
    vp.add(sp);
    session.getUiElements().resizePerunTable(sp, 350, this);
    this.contentWidget.setWidget(vp);
    return getWidget();
}
Also used : PerunSearchEvent(cz.metacentrum.perun.webgui.client.resources.PerunSearchEvent) ExtendedSuggestBox(cz.metacentrum.perun.webgui.widgets.ExtendedSuggestBox) TaskResult(cz.metacentrum.perun.webgui.model.TaskResult) GetRichTaskResultsByTask(cz.metacentrum.perun.webgui.json.propagationStatsReader.GetRichTaskResultsByTask) TabMenu(cz.metacentrum.perun.webgui.widgets.TabMenu)

Aggregations

PerunSearchEvent (cz.metacentrum.perun.webgui.client.resources.PerunSearchEvent)1 GetRichTaskResultsByTask (cz.metacentrum.perun.webgui.json.propagationStatsReader.GetRichTaskResultsByTask)1 TaskResult (cz.metacentrum.perun.webgui.model.TaskResult)1 ExtendedSuggestBox (cz.metacentrum.perun.webgui.widgets.ExtendedSuggestBox)1 TabMenu (cz.metacentrum.perun.webgui.widgets.TabMenu)1