original_string: public function view_summary(stdClass $submission, & $showviewlink) {
  
          // Never show a link to view full submission.
          $showviewlink = false;
          // Need to used this init() otherwise it does not have the javascript includes.
          comment::init();
  
          $options = new stdClass();
          $options->area    = 'submission_comments';
          $options->course    = $this->assignment->get_course();
          $options->context = $this->assignment->get_context();
          $options->itemid  = $submission->id;
          $options->component = 'assignsubmission_comments';
          $options->showcount = true;
          $options->displaycancel = true;
  
          $comment = new comment($options);
  
          $o = $this->assignment->get_renderer()->container($comment->output(true), 'commentscontainer');
          return $o;
      }
code: public function view_summary(stdClass $submission, & $showviewlink) {
  
          // Never show a link to view full submission.
          $showviewlink = false;
          // Need to used this init() otherwise it does not have the javascript includes.
          comment::init();
  
          $options = new stdClass();
          $options->area    = 'submission_comments';
          $options->course    = $this->assignment->get_course();
          $options->context = $this->assignment->get_context();
          $options->itemid  = $submission->id;
          $options->component = 'assignsubmission_comments';
          $options->showcount = true;
          $options->displaycancel = true;
  
          $comment = new comment($options);
  
          $o = $this->assignment->get_renderer()->container($comment->output(true), 'commentscontainer');
          return $o;
      }
code_tokens: public function view_summary ( stdClass $ submission , & $ showviewlink ) { // Never show a link to view full submission. $ showviewlink = false ; // Need to used this init() otherwise it does not have the javascript includes. comment :: init ( ) ; $ options = new stdClass ( ) ; $ options -> area = 'submission_comments' ; $ options -> course = $ this -> assignment -> get_course ( ) ; $ options -> context = $ this -> assignment -> get_context ( ) ; $ options -> itemid = $ submission -> id ; $ options -> component = 'assignsubmission_comments' ; $ options -> showcount = true ; $ options -> displaycancel = true ; $ comment = new comment ( $ options ) ; $ o = $ this -> assignment -> get_renderer ( ) -> container ( $ comment -> output ( true ) , 'commentscontainer' ) ; return $ o ; }
docstring: Display AJAX based comment in the submission status table
  
  @param stdClass $submission
  @param bool $showviewlink - If the comments are long this is
  set to true so they can be shown in a separate page
  @return string
docstring_tokens: Display AJAX based comment in the submission status table