/** * Retrieve a formatted HTML string that displays the state of the review * with the review recommendation if one exists. Or return just the state. * Only works with some states. * * @param string $statusKey Locale key for status text * @param ReviewAssignment $reviewAssignment * @return string */ function _getStatusWithRecommendation($statusKey, $reviewAssignment) { if (!$reviewAssignment->getRecommendation()) { return __($statusKey); } return '<span class="state">' . __($statusKey) . '</span><span class="details">' . __('submission.recommendation', array('recommendation' => $reviewAssignment->getLocalizedRecommendation())) . '</span>'; }