Updated code
This commit is contained in:
@@ -41,7 +41,7 @@ public interface EvaluationCriteriaApi {
|
|||||||
@ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
@ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
||||||
@ExampleObject(value = ErrorConstants.UNAUTHORIZED_ERROR_EXAMPLE) }))
|
@ExampleObject(value = ErrorConstants.UNAUTHORIZED_ERROR_EXAMPLE) }))
|
||||||
})
|
})
|
||||||
@GetMapping(value = "/{id}", produces = MediaType.APPLICATION_JSON_VALUE)
|
@GetMapping(value = "/criteria/{id}", produces = MediaType.APPLICATION_JSON_VALUE)
|
||||||
ResponseEntity<Response<EvaluationCriteriaResponseBean>> getEvaluationCriteriaById(HttpServletRequest request,
|
ResponseEntity<Response<EvaluationCriteriaResponseBean>> getEvaluationCriteriaById(HttpServletRequest request,
|
||||||
@Parameter(description = "evaluation criteria id", required = true)
|
@Parameter(description = "evaluation criteria id", required = true)
|
||||||
@PathVariable Long id);
|
@PathVariable Long id);
|
||||||
@@ -56,7 +56,7 @@ public interface EvaluationCriteriaApi {
|
|||||||
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
||||||
@ExampleObject(value = ErrorConstants.BADREQUEST_ERROR_EXAMPLE) }))
|
@ExampleObject(value = ErrorConstants.BADREQUEST_ERROR_EXAMPLE) }))
|
||||||
})
|
})
|
||||||
@PutMapping(value = "/{id}", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE)
|
@PutMapping(value = "/criteria/{id}", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE)
|
||||||
ResponseEntity<Response<EvaluationCriteriaResponseBean>> updateEvaluationCriteria(HttpServletRequest request,
|
ResponseEntity<Response<EvaluationCriteriaResponseBean>> updateEvaluationCriteria(HttpServletRequest request,
|
||||||
@Parameter(description = "evaluation criteria id", required = true)
|
@Parameter(description = "evaluation criteria id", required = true)
|
||||||
@PathVariable Long id,
|
@PathVariable Long id,
|
||||||
@@ -71,7 +71,7 @@ public interface EvaluationCriteriaApi {
|
|||||||
@ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
@ApiResponse(responseCode = "401", description = "Unauthorized", content = @Content(mediaType = MediaType.APPLICATION_JSON_VALUE, examples = {
|
||||||
@ExampleObject(value = ErrorConstants.UNAUTHORIZED_ERROR_EXAMPLE) }))
|
@ExampleObject(value = ErrorConstants.UNAUTHORIZED_ERROR_EXAMPLE) }))
|
||||||
})
|
})
|
||||||
@DeleteMapping(value = "/{id}", produces = MediaType.APPLICATION_JSON_VALUE)
|
@DeleteMapping(value = "/criteria/{id}", produces = MediaType.APPLICATION_JSON_VALUE)
|
||||||
ResponseEntity<Void> deleteEvaluationCriteria(HttpServletRequest request,
|
ResponseEntity<Void> deleteEvaluationCriteria(HttpServletRequest request,
|
||||||
@Parameter(description = "evaluation criteria id", required = true)
|
@Parameter(description = "evaluation criteria id", required = true)
|
||||||
@PathVariable Long id);
|
@PathVariable Long id);
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ public interface LookUpDataApi {
|
|||||||
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Bad Request\" }"))),
|
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Bad Request\" }"))),
|
||||||
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
||||||
})
|
})
|
||||||
@PostMapping(value = "/lookupdata", consumes = "application/json", produces = "application/json")
|
@PostMapping(value = "", consumes = "application/json", produces = "application/json")
|
||||||
ResponseEntity<Response<LookUpDataResponseBean>> createLookUpData(HttpServletRequest request, @Valid @RequestBody LookUpDataRequest lookUpDataReq);
|
ResponseEntity<Response<LookUpDataResponseBean>> createLookUpData(HttpServletRequest request, @Valid @RequestBody LookUpDataRequest lookUpDataReq);
|
||||||
|
|
||||||
@Operation(summary = "API to get LookUp Data by id",
|
@Operation(summary = "API to get LookUp Data by id",
|
||||||
@@ -29,7 +29,7 @@ public interface LookUpDataApi {
|
|||||||
@ApiResponse(responseCode = "200", description = "OK"),
|
@ApiResponse(responseCode = "200", description = "OK"),
|
||||||
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
||||||
})
|
})
|
||||||
@GetMapping(value = "/lookupdata/{id}", produces = "application/json")
|
@GetMapping(value = "/{id}", produces = "application/json")
|
||||||
ResponseEntity<Response<LookUpDataResponseBean>> getLookUpDataById(HttpServletRequest request, @PathVariable Long id);
|
ResponseEntity<Response<LookUpDataResponseBean>> getLookUpDataById(HttpServletRequest request, @PathVariable Long id);
|
||||||
|
|
||||||
@Operation(summary = "API to update LookUp Data",
|
@Operation(summary = "API to update LookUp Data",
|
||||||
@@ -38,7 +38,7 @@ public interface LookUpDataApi {
|
|||||||
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Bad Request\" }"))),
|
@ApiResponse(responseCode = "400", description = "Bad Request", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Bad Request\" }"))),
|
||||||
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
||||||
})
|
})
|
||||||
@PutMapping(value = "/lookupdata/{id}", consumes = "application/json", produces = "application/json")
|
@PutMapping(value = "/{id}", consumes = "application/json", produces = "application/json")
|
||||||
ResponseEntity<Response<LookUpDataResponseBean>> updateLookUpData(HttpServletRequest request, @PathVariable Long id, @Valid @RequestBody LookUpDataRequest lookUpDataReq);
|
ResponseEntity<Response<LookUpDataResponseBean>> updateLookUpData(HttpServletRequest request, @PathVariable Long id, @Valid @RequestBody LookUpDataRequest lookUpDataReq);
|
||||||
|
|
||||||
@Operation(summary = "API to delete LookUp Data",
|
@Operation(summary = "API to delete LookUp Data",
|
||||||
@@ -46,6 +46,6 @@ public interface LookUpDataApi {
|
|||||||
@ApiResponse(responseCode = "204", description = "No Content"),
|
@ApiResponse(responseCode = "204", description = "No Content"),
|
||||||
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
@ApiResponse(responseCode = "404", description = "Not Found", content = @Content(mediaType = "application/json", examples = @ExampleObject(value = "{ \"error\": \"Not Found\" }")))
|
||||||
})
|
})
|
||||||
@DeleteMapping(value = "/lookupdata/{id}")
|
@DeleteMapping(value = "/{id}")
|
||||||
ResponseEntity<Response<Void>> deleteLookUpData(HttpServletRequest request, @PathVariable Long id);
|
ResponseEntity<Response<Void>> deleteLookUpData(HttpServletRequest request, @PathVariable Long id);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user