Package energy.eddie.aiida.web
Class PermissionController
java.lang.Object
energy.eddie.aiida.web.PermissionController
@CrossOrigin(origins="http://localhost:5173")
@RestController
@RequestMapping("/permissions")
public class PermissionController
extends Object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<List<Permission>> org.springframework.http.ResponseEntity<Permission> setupNewPermission(@Valid QrCodeDto qrCodeDto) org.springframework.http.ResponseEntity<Permission> updatePermission(@Valid PatchPermissionDto patchDto, UUID permissionId)
-
Constructor Details
-
PermissionController
-
-
Method Details
-
getAllPermissions
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<List<Permission>> getAllPermissions() throws InvalidUserException- Throws:
InvalidUserException
-
setupNewPermission
@PostMapping(consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Permission> setupNewPermission(@Valid @RequestBody @Valid QrCodeDto qrCodeDto) throws PermissionAlreadyExistsException, PermissionUnfulfillableException, DetailFetchingFailedException, InvalidUserException -
updatePermission
@PatchMapping(value="/{permissionId}", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<Permission> updatePermission(@Valid @RequestBody @Valid PatchPermissionDto patchDto, @PathVariable UUID permissionId) throws PermissionStateTransitionException, PermissionNotFoundException, DetailFetchingFailedException, UnauthorizedException, InvalidUserException
-