use of com.odysseusinc.arachne.portal.api.v1.dto.SubmissionInsightDTO in project ArachneCentralAPI by OHDSI.
the class BaseAnalysisController method updateSubmissionInsight.
@ApiOperation("Update submission insight")
@RequestMapping(value = "/api/v1/analysis-management/submissions/{submissionId}/insight", method = PUT)
public JsonResult<SubmissionInsightDTO> updateSubmissionInsight(@PathVariable("submissionId") Long submissionId, @RequestBody SubmissionInsightUpdateDTO insightDTO) throws NotExistException {
final SubmissionInsight insight = conversionService.convert(insightDTO, SubmissionInsight.class);
final SubmissionInsight updatedInsight = submissionInsightService.updateSubmissionInsight(submissionId, insight);
final SubmissionInsightDTO updatedInsightDTO = conversionService.convert(updatedInsight, SubmissionInsightDTO.class);
final JsonResult<SubmissionInsightDTO> result = new JsonResult<>(NO_ERROR);
result.setResult(updatedInsightDTO);
return result;
}
Aggregations