Skip to content

Commit

Permalink
Merge branch 'feature/shibui-1848' of bitbucket.org:unicon/shib-idp-u…
Browse files Browse the repository at this point in the history
…i into feature/shibui-1848
  • Loading branch information
rmathis committed Jul 1, 2021
2 parents eb4f325 + 40017bb commit e69f569
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.security.access.annotation.Secured;
import org.springframework.stereotype.Controller;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.DeleteMapping;
Expand All @@ -25,6 +26,7 @@ public class GroupController {
@Autowired
private IGroupService groupService;

@Secured("ROLE_ADMIN")
@PostMapping
@Transactional
public ResponseEntity<?> create(@RequestBody Group group) {
Expand All @@ -45,6 +47,7 @@ public ResponseEntity<?> create(@RequestBody Group group) {
return ResponseEntity.status(HttpStatus.CREATED).body(result);
}

@Secured("ROLE_ADMIN")
@PutMapping
@Transactional
public ResponseEntity<?> update(@RequestBody Group group) {
Expand Down Expand Up @@ -85,7 +88,8 @@ public ResponseEntity<?> getOne(@PathVariable String resourceId) {
}
return ResponseEntity.ok(g);
}


@Secured("ROLE_ADMIN")
@DeleteMapping("/{resourceId}")
@Transactional
public ResponseEntity<?> delete(@PathVariable String resourceId) {
Expand Down

0 comments on commit e69f569

Please sign in to comment.