Пример #1
0
 @Checked("SpacePredicates.checkIfLoggedPersonHasPermissionsToManageBlueprints")
 @FenixDomainObjectActionLogAnnotation(
     actionName = "Deleted space blueprint",
     parameters = {})
 public void delete() {
   Space space = getSpace();
   refreshBlueprintsDates(space);
   super.setSpace(null);
   super.setCreationPerson(null);
   removeBlueprintFile();
   removeRootDomainObject();
   openCurrentSpaceBlueprint(space);
   deleteDomainObject();
 }
Пример #2
0
 @Override
 public void setCreationPerson(Person creationPerson) {
   if (creationPerson == null) {
     throw new DomainException("error.blueprint.no.person");
   }
   super.setCreationPerson(creationPerson);
 }
Пример #3
0
 @Override
 public void setSpace(Space space) {
   if (space == null) {
     throw new DomainException("error.blueprint.no.space");
   }
   super.setSpace(space);
 }
Пример #4
0
 @Checked("SpacePredicates.checkIfLoggedPersonHasPermissionsToManageBlueprints")
 @FenixDomainObjectActionLogAnnotation(
     actionName = "Created space blueprint",
     parameters = {"space", "person"})
 public Blueprint(Space space, Person person) {
   super();
   setRootDomainObject(RootDomainObject.getInstance());
   checkNewBluePrintDates(space);
   closeCurrentSpaceBlueprint(space);
   setSpace(space);
   setCreationPerson(person);
   super.setValidFrom(new YearMonthDay());
 }
Пример #5
0
 private void updateValidFromDate(YearMonthDay yearMonthDay) {
   super.setValidFrom(yearMonthDay);
 }
Пример #6
0
 private void closeBlueprint() {
   super.setValidUntil(new YearMonthDay());
 }
Пример #7
0
 private void openBlueprint() {
   super.setValidUntil(null);
 }