Package edu.ucsb.cs.scaffold.controller
Class InstructorsController
java.lang.Object
edu.ucsb.cs.scaffold.controller.ApiController
edu.ucsb.cs.scaffold.controller.InstructorsController
@RequestMapping("/api/admin/instructors")
@RestController
public class InstructorsController
extends ApiController
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<String> deleteInstructor(String email) postInstructor(String email) Methods inherited from class edu.ucsb.cs.scaffold.controller.ApiController
genericMessage, getCurrentUser, handleEntityNotFoundException, handleForbiddenException, handleIllegalArgument, handleUnsupportedOperation
-
Constructor Details
-
InstructorsController
public InstructorsController()
-
-
Method Details
-
postInstructor
@PreAuthorize("hasRole(\'ROLE_ADMIN\')") @PostMapping("/post") public Instructor postInstructor(@RequestParam String email) -
allInstructors
@PreAuthorize("hasRole(\'ROLE_ADMIN\')") @GetMapping("/get") public Iterable<Instructor> allInstructors() -
deleteInstructor
-