Search in sources :

Example 6 with PoolItemsSource

use of org.olat.modules.qpool.ui.datasource.PoolItemsSource in project openolat by klemens.

the class ItemListMySharesController method doSelectPool.

private void doSelectPool(UserRequest ureq, Long poolKey) {
    Pool myPool = null;
    for (Pool pool : myPools) {
        if (poolKey.equals(pool.getKey())) {
            myPool = pool;
        }
    }
    if (myPool == null) {
        updateSource(new EmptyItemsSource());
    } else {
        PoolItemsSource source = new PoolItemsSource(getIdentity(), ureq.getUserSession().getRoles(), myPool);
        source.getDefaultParams().setFormat(restrictToFormat);
        updateSource(source);
    }
}
Also used : PoolItemsSource(org.olat.modules.qpool.ui.datasource.PoolItemsSource) EmptyItemsSource(org.olat.modules.qpool.ui.datasource.EmptyItemsSource) Pool(org.olat.modules.qpool.Pool)

Aggregations

PoolItemsSource (org.olat.modules.qpool.ui.datasource.PoolItemsSource)6 Pool (org.olat.modules.qpool.Pool)4 WindowControl (org.olat.core.gui.control.WindowControl)2 Roles (org.olat.core.id.Roles)2 BusinessGroup (org.olat.group.BusinessGroup)2 QuestionsController (org.olat.modules.qpool.ui.QuestionsController)2 EmptyItemsSource (org.olat.modules.qpool.ui.datasource.EmptyItemsSource)2 SharedItemsSource (org.olat.modules.qpool.ui.datasource.SharedItemsSource)2