Inheritance: extends DAO
 /**
  * Internal function to return a ReviewerSubmission object from a row.
  * @param $row array
  * @return ReviewerSubmission
  */
 function _fromRow($row)
 {
     // Get the ReviewerSubmission object, populated with Monograph data
     $reviewerSubmission = parent::_fromRow($row);
     // Editor Decisions
     $editDecisionDao = DAORegistry::getDAO('EditDecisionDAO');
     $decisions = $editDecisionDao->getEditorDecisions($row['submission_id']);
     $reviewerSubmission->setDecisions($decisions);
     // Review Assignment
     $reviewerSubmission->setReviewId($row['review_id']);
     $reviewerSubmission->setReviewerId($row['reviewer_id']);
     $reviewerSubmission->setReviewerFullName($row['first_name'] . ' ' . $row['last_name']);
     $reviewerSubmission->setCompetingInterests($row['competing_interests']);
     $reviewerSubmission->setRecommendation($row['recommendation']);
     $reviewerSubmission->setDateAssigned($this->datetimeFromDB($row['date_assigned']));
     $reviewerSubmission->setDateNotified($this->datetimeFromDB($row['date_notified']));
     $reviewerSubmission->setDateConfirmed($this->datetimeFromDB($row['date_confirmed']));
     $reviewerSubmission->setDateCompleted($this->datetimeFromDB($row['date_completed']));
     $reviewerSubmission->setDateAcknowledged($this->datetimeFromDB($row['date_acknowledged']));
     $reviewerSubmission->setDateDue($this->datetimeFromDB($row['date_due']));
     $reviewerSubmission->setDateResponseDue($this->datetimeFromDB($row['date_response_due']));
     $reviewerSubmission->setDeclined($row['declined']);
     $reviewerSubmission->setReplaced($row['replaced']);
     $reviewerSubmission->setCancelled((int) $row['cancelled']);
     $reviewerSubmission->setQuality($row['quality']);
     $reviewerSubmission->setRound($row['round']);
     $reviewerSubmission->setStep($row['step']);
     $reviewerSubmission->setStageId($row['stage_id']);
     $reviewerSubmission->setReviewMethod($row['review_method']);
     HookRegistry::call('ReviewerSubmissionDAO::_fromRow', array(&$reviewerSubmission, &$row));
     return $reviewerSubmission;
 }
Example #2
0
 /**
  * Creates and returns a published monograph object from a row
  * @param $row array
  * @return PublishedMonograph object
  */
 function _fromRow($row)
 {
     // Get the PublishedMonograph object, populated with Monograph data
     $publishedMonograph = parent::_fromRow($row);
     // Add the additional PublishedMonograph data
     $publishedMonograph->setDatePublished($this->datetimeFromDB($row['date_published']));
     $publishedMonograph->setAudience($row['audience']);
     $publishedMonograph->setAudienceRangeQualifier($row['audience_range_qualifier']);
     $publishedMonograph->setAudienceRangeFrom($row['audience_range_from']);
     $publishedMonograph->setAudienceRangeTo($row['audience_range_to']);
     $publishedMonograph->setAudienceRangeExact($row['audience_range_exact']);
     $publishedMonograph->setCoverImage(unserialize($row['cover_image']));
     HookRegistry::call('PublishedMonographDAO::_fromRow', array(&$publishedMonograph, &$row));
     return $publishedMonograph;
 }