Skip to content

Commit

Permalink
pkp/pkp-lib#10508 Apply getLocalizedForm method to TitleAbstractForm …
Browse files Browse the repository at this point in the history
…form
  • Loading branch information
taslangraham committed Oct 7, 2024
1 parent 4141296 commit 876b969
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion api/v1/submissions/SubmissionController.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ protected function getPublicationTitleAbstractForm(Request $illuminateRequest):

$section = Repo::section()->get($publication->getData('sectionId'), $context->getId());
$locales = $this->getPublicationFormLocales($context, $submission);
$submissionLocale = $submission->getData('locale');

$titleAbstract = new TitleAbstractForm(
$publicationApiUrl,
Expand All @@ -172,6 +173,7 @@ protected function getPublicationTitleAbstractForm(Request $illuminateRequest):
$section->getData('wordCount'),
!$section->getData('abstractsNotRequired')
);
return response()->json($titleAbstract->getConfig(), Response::HTTP_OK);

return response()->json($this->getLocalizedForm($titleAbstract, $submissionLocale, $locales), Response::HTTP_OK);
}
}

0 comments on commit 876b969

Please sign in to comment.