Search in sources :

Example 1 with DenseTreeGrid

use of io.imunity.furms.ui.views.project.resource_access.DenseTreeGrid in project furms by unity-idm.

the class ProjectsView method createCommunityGrid.

private TreeGrid<ProjectViewGridModel> createCommunityGrid() {
    TreeGrid<ProjectViewGridModel> grid = new DenseTreeGrid<>();
    grid.addComponentHierarchyColumn(this::createNameComponent).setHeader(getTranslation("view.community-admin.projects.grid.column.1")).setSortable(true).setComparator(x -> x.name.toLowerCase());
    grid.addColumn(c -> c.description).setHeader(getTranslation("view.community-admin.projects.grid.column.2")).setSortable(true);
    grid.addColumn(c -> c.siteName).setHeader(getTranslation("view.community-admin.projects.grid.column.3")).setSortable(true);
    grid.addComponentColumn(c -> new StatusLayout(c.status, c.message, getContent())).setHeader(getTranslation("view.community-admin.projects.grid.column.4")).setSortable(true);
    grid.addComponentColumn(this::createLastColumnContent).setHeader(getTranslation("view.community-admin.projects.grid.column.5")).setTextAlign(ColumnTextAlign.END);
    return grid;
}
Also used : DenseTreeGrid(io.imunity.furms.ui.views.project.resource_access.DenseTreeGrid) StatusLayout(io.imunity.furms.ui.components.StatusLayout)

Aggregations

StatusLayout (io.imunity.furms.ui.components.StatusLayout)1 DenseTreeGrid (io.imunity.furms.ui.views.project.resource_access.DenseTreeGrid)1