original_string: public function get_assessments_of_submission($submissionid) {
          global $DB;
  
          $reviewerfields = user_picture::fields('reviewer', null, 'revieweridx', 'reviewer');
          $overbyfields   = user_picture::fields('overby', null, 'gradinggradeoverbyx', 'overby');
          list($sort, $params) = users_order_by_sql('reviewer');
          $sql = "SELECT a.*, s.title, $reviewerfields, $overbyfields
                    FROM {workshop_assessments} a
              INNER JOIN {user} reviewer ON (a.reviewerid = reviewer.id)
              INNER JOIN {workshop_submissions} s ON (a.submissionid = s.id)
               LEFT JOIN {user} overby ON (a.gradinggradeoverby = overby.id)
                   WHERE s.example = 0 AND s.id = :submissionid AND s.workshopid = :workshopid
                ORDER BY $sort";
          $params['submissionid'] = $submissionid;
          $params['workshopid']   = $this->id;
  
          return $DB->get_records_sql($sql, $params);
      }
code: public function get_assessments_of_submission($submissionid) {
          global $DB;
  
          $reviewerfields = user_picture::fields('reviewer', null, 'revieweridx', 'reviewer');
          $overbyfields   = user_picture::fields('overby', null, 'gradinggradeoverbyx', 'overby');
          list($sort, $params) = users_order_by_sql('reviewer');
          $sql = "SELECT a.*, s.title, $reviewerfields, $overbyfields
                    FROM {workshop_assessments} a
              INNER JOIN {user} reviewer ON (a.reviewerid = reviewer.id)
              INNER JOIN {workshop_submissions} s ON (a.submissionid = s.id)
               LEFT JOIN {user} overby ON (a.gradinggradeoverby = overby.id)
                   WHERE s.example = 0 AND s.id = :submissionid AND s.workshopid = :workshopid
                ORDER BY $sort";
          $params['submissionid'] = $submissionid;
          $params['workshopid']   = $this->id;
  
          return $DB->get_records_sql($sql, $params);
      }
code_tokens: public function get_assessments_of_submission ( $ submissionid ) { global $ DB ; $ reviewerfields = user_picture :: fields ( 'reviewer' , null , 'revieweridx' , 'reviewer' ) ; $ overbyfields = user_picture :: fields ( 'overby' , null , 'gradinggradeoverbyx' , 'overby' ) ; list ( $ sort , $ params ) = users_order_by_sql ( 'reviewer' ) ; $ sql = "SELECT a.*, s.title, $reviewerfields, $overbyfields
                    FROM {workshop_assessments} a
              INNER JOIN {user} reviewer ON (a.reviewerid = reviewer.id)
              INNER JOIN {workshop_submissions} s ON (a.submissionid = s.id)
               LEFT JOIN {user} overby ON (a.gradinggradeoverby = overby.id)
                   WHERE s.example = 0 AND s.id = :submissionid AND s.workshopid = :workshopid
                ORDER BY $sort" ; $ params [ 'submissionid' ] = $ submissionid ; $ params [ 'workshopid' ] = $ this -> id ; return $ DB -> get_records_sql ( $ sql , $ params ) ; }
docstring: Get the complete information about all assessments of the given submission
  
  @param int $submissionid
  @return array
docstring_tokens: Get the complete information about all assessments of the given submission