Search in sources :

Example 1 with PopoverTextCell

use of org.uberfire.ext.widgets.common.client.tables.PopoverTextCell in project kie-wb-common by kiegroup.

the class NotificationWidgetViewImpl method initBody.

private void initBody() {
    PopoverTextCell typeCell = new PopoverTextCell();
    Column<NotificationRow, String> bodyColumn = new Column<NotificationRow, String>(typeCell) {

        @Override
        public String getValue(NotificationRow object) {
            if (object.getBody() != null) {
                return object.getBody();
            }
            return "";
        }
    };
    bodyColumn.setSortable(false);
    table.addColumn(bodyColumn, presenter.getBodyLabel());
    table.setColumnWidth(bodyColumn, 160, Style.Unit.PX);
}
Also used : Column(com.google.gwt.user.cellview.client.Column) PopoverTextCell(org.uberfire.ext.widgets.common.client.tables.PopoverTextCell) NotificationRow(org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.NotificationRow)

Example 2 with PopoverTextCell

use of org.uberfire.ext.widgets.common.client.tables.PopoverTextCell in project kie-wb-common by kiegroup.

the class NotificationWidgetViewImpl method initExpiresAt.

private void initExpiresAt() {
    PopoverTextCell expiresAt = new PopoverTextCell();
    Column<NotificationRow, String> expiresAtColumn = new Column<NotificationRow, String>(expiresAt) {

        @Override
        public String getValue(NotificationRow object) {
            if (object.getExpiresAt() != null) {
                return object.getExpiresAt();
            }
            return "";
        }
    };
    expiresAtColumn.setSortable(false);
    table.addColumn(expiresAtColumn, presenter.getExpiresAtLabel());
    table.setColumnWidth(expiresAtColumn, 80, Style.Unit.PX);
}
Also used : Column(com.google.gwt.user.cellview.client.Column) PopoverTextCell(org.uberfire.ext.widgets.common.client.tables.PopoverTextCell) NotificationRow(org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.NotificationRow)

Example 3 with PopoverTextCell

use of org.uberfire.ext.widgets.common.client.tables.PopoverTextCell in project kie-wb-common by kiegroup.

the class ReassignmentWidgetViewImpl method initGroups.

private void initGroups() {
    PopoverTextCell toGroups = new PopoverTextCell();
    Column<ReassignmentRow, String> toGroupsColumn = new Column<ReassignmentRow, String>(toGroups) {

        @Override
        public String getValue(ReassignmentRow object) {
            if (object.getGroups() != null) {
                return object.getGroups().stream().collect(Collectors.joining(","));
            } else {
                return "";
            }
        }
    };
    toGroupsColumn.setSortable(false);
    table.addColumn(toGroupsColumn, presenter.getToGroupsLabel());
    table.setColumnWidth(toGroupsColumn, 150, Style.Unit.PX);
}
Also used : Column(com.google.gwt.user.cellview.client.Column) PopoverTextCell(org.uberfire.ext.widgets.common.client.tables.PopoverTextCell) ReassignmentRow(org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.ReassignmentRow)

Example 4 with PopoverTextCell

use of org.uberfire.ext.widgets.common.client.tables.PopoverTextCell in project kie-wb-common by kiegroup.

the class NotificationWidgetViewImpl method initEmails.

private void initEmails() {
    PopoverTextCell toEmails = new PopoverTextCell();
    Column<NotificationRow, String> toEmailsColumn = new Column<NotificationRow, String>(toEmails) {

        @Override
        public String getValue(NotificationRow object) {
            if (object.getEmails() != null) {
                return join(",", object.getEmails());
            }
            return "";
        }
    };
    toEmailsColumn.setSortable(false);
    table.addColumn(toEmailsColumn, presenter.getToEmailsLabel());
    table.setColumnWidth(toEmailsColumn, 160, Style.Unit.PX);
}
Also used : Column(com.google.gwt.user.cellview.client.Column) PopoverTextCell(org.uberfire.ext.widgets.common.client.tables.PopoverTextCell) NotificationRow(org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.NotificationRow)

Example 5 with PopoverTextCell

use of org.uberfire.ext.widgets.common.client.tables.PopoverTextCell in project kie-wb-common by kiegroup.

the class NotificationWidgetViewImpl method initUsers.

private void initUsers() {
    PopoverTextCell toUsers = new PopoverTextCell();
    Column<NotificationRow, String> toUsersColumn = new Column<NotificationRow, String>(toUsers) {

        @Override
        public String getValue(NotificationRow object) {
            if (object.getUsers() != null) {
                return join(",", object.getUsers());
            } else {
                return "";
            }
        }
    };
    toUsersColumn.setSortable(false);
    table.addColumn(toUsersColumn, presenter.getToUsersLabel());
    table.setColumnWidth(toUsersColumn, 160, Style.Unit.PX);
}
Also used : Column(com.google.gwt.user.cellview.client.Column) PopoverTextCell(org.uberfire.ext.widgets.common.client.tables.PopoverTextCell) NotificationRow(org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.NotificationRow)

Aggregations

Column (com.google.gwt.user.cellview.client.Column)8 PopoverTextCell (org.uberfire.ext.widgets.common.client.tables.PopoverTextCell)8 NotificationRow (org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.NotificationRow)6 ReassignmentRow (org.kie.workbench.common.stunner.bpmn.client.forms.fields.model.ReassignmentRow)2