use of org.ambraproject.rhino.view.journal.JournalInputView in project rhino by PLOS.
the class JournalCrudController method update.
@Transactional(rollbackFor = { Throwable.class })
@RequestMapping(value = "/journals/{journalKey}", method = RequestMethod.PATCH)
@ApiImplicitParam(name = "body", paramType = "body", dataType = "JournalInputView", value = "example: {\"currentIssueDoi\": \"10.1371/issue.pmed.v13.i09\"}")
public ResponseEntity<?> update(@RequestHeader(value = HttpHeaders.IF_MODIFIED_SINCE, required = false) Date ifModifiedSince, HttpServletRequest request, @PathVariable String journalKey) throws IOException {
JournalInputView input = readJsonFromRequest(request, JournalInputView.class);
journalCrudService.update(journalKey, input);
return journalCrudService.serve(journalKey).getIfModified(ifModifiedSince).asJsonResponse(entityGson);
}
Aggregations