Search in sources :

Example 6 with RepositoryEntryUpgradeToGroupRelation

use of org.olat.upgrade.model.RepositoryEntryUpgradeToGroupRelation in project openolat by klemens.

the class OLATUpgrade_10_0_0 method create.

public RepositoryEntryUpgradeToGroupRelation create(RepositoryEntryUpgrade entry, Group group, boolean defaultRelation) {
    RepositoryEntryUpgradeToGroupRelation rel = new RepositoryEntryUpgradeToGroupRelation();
    rel.setCreationDate(new Date());
    rel.setDefaultGroup(defaultRelation);
    rel.setGroup(group);
    rel.setEntry(entry);
    dbInstance.getCurrentEntityManager().persist(rel);
    return rel;
}
Also used : RepositoryEntryUpgradeToGroupRelation(org.olat.upgrade.model.RepositoryEntryUpgradeToGroupRelation) Date(java.util.Date)

Aggregations

RepositoryEntryUpgradeToGroupRelation (org.olat.upgrade.model.RepositoryEntryUpgradeToGroupRelation)6 Group (org.olat.basesecurity.Group)4 SecurityGroup (org.olat.basesecurity.SecurityGroup)4 Date (java.util.Date)2 HashSet (java.util.HashSet)2 BGResourceRelation (org.olat.upgrade.model.BGResourceRelation)2 RepositoryEntryUpgrade (org.olat.upgrade.model.RepositoryEntryUpgrade)2