Search in sources :

Example 11 with AnnouncementWorkspace

use of fi.otavanopisto.muikku.plugins.announcer.workspace.model.AnnouncementWorkspace in project muikku by otavanopisto.

the class AnnouncementWorkspaceDAO method create.

public AnnouncementWorkspace create(Announcement announcement, Long workspaceEntityId, Boolean archived) {
    AnnouncementWorkspace announcemenWorkspace = new AnnouncementWorkspace();
    announcemenWorkspace.setAnnouncement(announcement);
    announcemenWorkspace.setWorkspaceEntityId(workspaceEntityId);
    announcemenWorkspace.setArchived(archived);
    return persist(announcemenWorkspace);
}
Also used : AnnouncementWorkspace(fi.otavanopisto.muikku.plugins.announcer.workspace.model.AnnouncementWorkspace)

Aggregations

AnnouncementWorkspace (fi.otavanopisto.muikku.plugins.announcer.workspace.model.AnnouncementWorkspace)11 WorkspaceEntity (fi.otavanopisto.muikku.model.workspace.WorkspaceEntity)5 Announcement (fi.otavanopisto.muikku.plugins.announcer.model.Announcement)5 AnnouncementUserGroup (fi.otavanopisto.muikku.plugins.announcer.model.AnnouncementUserGroup)5 UserEntity (fi.otavanopisto.muikku.model.users.UserEntity)4 RESTPermit (fi.otavanopisto.security.rest.RESTPermit)4 EntityManager (javax.persistence.EntityManager)4 CriteriaBuilder (javax.persistence.criteria.CriteriaBuilder)4 Path (javax.ws.rs.Path)4 ArrayList (java.util.ArrayList)3 UserGroupEntity (fi.otavanopisto.muikku.model.users.UserGroupEntity)2 AnnouncementEnvironmentRestriction (fi.otavanopisto.muikku.plugins.announcer.dao.AnnouncementEnvironmentRestriction)2 WorkspaceBasicInfo (fi.otavanopisto.muikku.plugins.workspace.rest.model.WorkspaceBasicInfo)2 Date (java.util.Date)2 GET (javax.ws.rs.GET)2 AnnouncementTimeFrame (fi.otavanopisto.muikku.plugins.announcer.dao.AnnouncementTimeFrame)1 Predicate (javax.persistence.criteria.Predicate)1 DELETE (javax.ws.rs.DELETE)1 PUT (javax.ws.rs.PUT)1 RequestAction (org.ocpsoft.rewrite.annotation.RequestAction)1