Skip to content

Commit

Permalink
DDLS-224 : Add a check for submitted reports in report review page (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ndasmoj committed May 16, 2024
1 parent 64a3ab6 commit 7947def
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions client/app/src/Controller/Report/ReportController.php
Original file line number Diff line number Diff line change
Expand Up @@ -464,11 +464,13 @@ public function reviewAction($reportId)
$backLink = $this->generateUrl('lay_home');
}

// Redirect deputy to doc re-upload page if docs do not exist in S3
$documentsNotInS3 = $this->checkIfDocumentsExistInS3($report);
if (!$report->isSubmitted()) {
// Redirect deputy to doc re-upload page if docs do not exist in S3
$documentsNotInS3 = $this->checkIfDocumentsExistInS3($report);

if (!empty($documentsNotInS3)) {
return $this->redirectToRoute('report_documents_reupload', ['reportId' => $reportId]);
if (!empty($documentsNotInS3)) {
return $this->redirectToRoute('report_documents_reupload', ['reportId' => $reportId]);
}
}

return [
Expand Down

0 comments on commit 7947def

Please sign in to comment.