TSK-360: added links to workbasket and removed distributiontargets from workbasketsummary.

This commit is contained in:
Holger Hagen 2018-03-06 11:58:13 +01:00 committed by Martin Rojas Miguel Angel
parent d751c43a2f
commit d25e846fd5
2 changed files with 4 additions and 10 deletions

View File

@ -48,14 +48,10 @@ public class WorkbasketMapper {
private WorkbasketResource addLinks(WorkbasketResource resource, Workbasket wb) throws NotAuthorizedException {
resource.add(linkTo(methodOn(WorkbasketController.class).getWorkbasket(wb.getId())).withSelfRel());
resource
.add(linkTo(methodOn(WorkbasketController.class).createWorkbasket(resource)).withRel("createWorkbasket"));
resource
.add(linkTo(methodOn(WorkbasketController.class).updateWorkbasket(wb.getId(), resource))
.withRel("updateWorkbasket"));
resource
.add(linkTo(methodOn(WorkbasketController.class).deleteWorkbasket(wb.getId()))
.withRel("deleteWorkbasket"));
resource.add(linkTo(methodOn(WorkbasketController.class).getDistributionTargetsForWorkbasketId(wb.getId()))
.withRel("distributionTargets"));
resource.add(linkTo(methodOn(WorkbasketController.class).getWorkbasketAccessItems(wb.getId()))
.withRel("accessItems"));
return resource;
}
}

View File

@ -27,8 +27,6 @@ public class WorkbasketSummaryMapper {
private WorkbasketSummaryResource addLinks(WorkbasketSummaryResource resource, WorkbasketSummary summary) {
resource.add(linkTo(methodOn(WorkbasketController.class).getWorkbasket(summary.getId())).withSelfRel());
resource.add(linkTo(methodOn(WorkbasketController.class).getDistributionTargetsForWorkbasketId(summary.getId()))
.withRel("getDistributionTargetsForWorkbasketId"));
return resource;
}
}