diff --git a/classes/log/SubmissionEmailLogEntry.php b/classes/log/SubmissionEmailLogEntry.php index dfd0deba588..3d9cebaa2e4 100644 --- a/classes/log/SubmissionEmailLogEntry.php +++ b/classes/log/SubmissionEmailLogEntry.php @@ -39,6 +39,8 @@ class SubmissionEmailLogEntry extends EmailLogEntry public const SUBMISSION_EMAIL_REVIEW_CONFIRM = 0x40000005; public const SUBMISSION_EMAIL_REVIEW_DECLINE = 0x40000006; public const SUBMISSION_EMAIL_REVIEW_CONFIRM_ACK = 0x40000008; + public const SUBMISSION_EMAIL_REVIEW_REQUEST = 0x40000009; + public const SUBMISSION_EMAIL_REVIEW_REQUEST_SUBSEQUENT = 0x4000000A; // Copyeditor events 0x50000000 public const SUBMISSION_EMAIL_COPYEDIT_NOTIFY_COPYEDITOR = 0x50000001; diff --git a/classes/submission/action/EditorAction.php b/classes/submission/action/EditorAction.php index a325fefae52..61eff43fe79 100644 --- a/classes/submission/action/EditorAction.php +++ b/classes/submission/action/EditorAction.php @@ -29,6 +29,8 @@ use PKP\core\PKPString; use PKP\db\DAORegistry; use PKP\log\event\PKPSubmissionEventLogEntry; +use PKP\log\SubmissionEmailLogDAO; +use PKP\log\SubmissionEmailLogEntry; use PKP\mail\mailables\ReviewRequest; use PKP\mail\mailables\ReviewRequestSubsequent; use PKP\mail\variables\ReviewAssignmentEmailVariable; @@ -137,6 +139,13 @@ public function addReviewer($request, $submission, $reviewerId, &$reviewRound, $ try { Mail::send($mailable); + + /** @var SubmissionEmailLogDAO $submissionEmailLogDao */ + $submissionEmailLogDao = DAORegistry::getDAO('SubmissionEmailLogDAO'); + $submissionEmailLogDao->logMailable( + $round === ReviewRound::REVIEW_ROUND_STATUS_REVISIONS_REQUESTED + ? SubmissionEmailLogEntry::SUBMISSION_EMAIL_REVIEW_REQUEST + : SubmissionEmailLogEntry::SUBMISSION_EMAIL_REVIEW_REQUEST_SUBSEQUENT, $mailable, $submission, $user); } catch (TransportException $e) { $notificationMgr = new PKPNotificationManager(); $notificationMgr->createTrivialNotification(