Search in sources :

Example 1 with SharedPageRow

use of org.olat.modules.portfolio.ui.shared.SharedPageRow in project OpenOLAT by OpenOLAT.

the class SharedPageStatusCellRenderer method render.

@Override
public void render(Renderer renderer, StringOutput target, Object cellValue, int row, FlexiTableComponent source, URLBuilder ubu, Translator trans) {
    if (cellValue instanceof SharedPageRow) {
        SharedPageRow pageRow = (SharedPageRow) cellValue;
        PageStatus status = pageRow.getStatus();
        PageUserStatus userStatus = pageRow.getUserStatus();
        render(target, status, userStatus);
    } else if (cellValue instanceof PortfolioElementRow) {
        PortfolioElementRow elementRow = (PortfolioElementRow) cellValue;
        if (elementRow.getPage() != null) {
            PageStatus status = elementRow.getPageStatus();
            PageUserStatus userStatus = elementRow.getUserInfosStatus();
            render(target, status, userStatus);
        }
    }
}
Also used : PortfolioElementRow(org.olat.modules.portfolio.ui.model.PortfolioElementRow) PageStatus(org.olat.modules.portfolio.PageStatus) PageUserStatus(org.olat.modules.portfolio.PageUserStatus) SharedPageRow(org.olat.modules.portfolio.ui.shared.SharedPageRow)

Example 2 with SharedPageRow

use of org.olat.modules.portfolio.ui.shared.SharedPageRow in project OpenOLAT by OpenOLAT.

the class PageTitleCellRenderer method render.

@Override
public void render(Renderer renderer, StringOutput target, Object cellValue, int row, FlexiTableComponent source, URLBuilder ubu, Translator translator) {
    FlexiTableElementImpl tEl = source.getFlexiTableElement();
    Object rowValue = tEl.getTableDataModel().getObject(row);
    if (rowValue instanceof SharedPageRow) {
        SharedPageRow page = (SharedPageRow) rowValue;
        target.append(StringHelper.escapeHtml(page.getPageTitle()));
    }
}
Also used : FlexiTableElementImpl(org.olat.core.gui.components.form.flexible.impl.elements.table.FlexiTableElementImpl) SharedPageRow(org.olat.modules.portfolio.ui.shared.SharedPageRow)

Example 3 with SharedPageRow

use of org.olat.modules.portfolio.ui.shared.SharedPageRow in project openolat by klemens.

the class SharedPageStatusCellRenderer method render.

@Override
public void render(Renderer renderer, StringOutput target, Object cellValue, int row, FlexiTableComponent source, URLBuilder ubu, Translator trans) {
    if (cellValue instanceof SharedPageRow) {
        SharedPageRow pageRow = (SharedPageRow) cellValue;
        PageStatus status = pageRow.getStatus();
        PageUserStatus userStatus = pageRow.getUserStatus();
        render(target, status, userStatus);
    } else if (cellValue instanceof PortfolioElementRow) {
        PortfolioElementRow elementRow = (PortfolioElementRow) cellValue;
        if (elementRow.getPage() != null) {
            PageStatus status = elementRow.getPageStatus();
            PageUserStatus userStatus = elementRow.getUserInfosStatus();
            render(target, status, userStatus);
        }
    }
}
Also used : PortfolioElementRow(org.olat.modules.portfolio.ui.model.PortfolioElementRow) PageStatus(org.olat.modules.portfolio.PageStatus) PageUserStatus(org.olat.modules.portfolio.PageUserStatus) SharedPageRow(org.olat.modules.portfolio.ui.shared.SharedPageRow)

Example 4 with SharedPageRow

use of org.olat.modules.portfolio.ui.shared.SharedPageRow in project openolat by klemens.

the class PageTitleCellRenderer method render.

@Override
public void render(Renderer renderer, StringOutput target, Object cellValue, int row, FlexiTableComponent source, URLBuilder ubu, Translator translator) {
    FlexiTableElementImpl tEl = source.getFlexiTableElement();
    Object rowValue = tEl.getTableDataModel().getObject(row);
    if (rowValue instanceof SharedPageRow) {
        SharedPageRow page = (SharedPageRow) rowValue;
        target.append(StringHelper.escapeHtml(page.getPageTitle()));
    }
}
Also used : FlexiTableElementImpl(org.olat.core.gui.components.form.flexible.impl.elements.table.FlexiTableElementImpl) SharedPageRow(org.olat.modules.portfolio.ui.shared.SharedPageRow)

Aggregations

SharedPageRow (org.olat.modules.portfolio.ui.shared.SharedPageRow)4 FlexiTableElementImpl (org.olat.core.gui.components.form.flexible.impl.elements.table.FlexiTableElementImpl)2 PageStatus (org.olat.modules.portfolio.PageStatus)2 PageUserStatus (org.olat.modules.portfolio.PageUserStatus)2 PortfolioElementRow (org.olat.modules.portfolio.ui.model.PortfolioElementRow)2