original_string: public function display() {
          global $OUTPUT;
          groups_print_activity_menu($this->feedbackstructure->get_cm(), $this->baseurl->out());
          $grandtotal = $this->get_total_responses_count();
          if (!$grandtotal) {
              echo $OUTPUT->box(get_string('nothingtodisplay'), 'generalbox nothingtodisplay');
              return;
          }
  
          if (count($this->feedbackstructure->get_items(true)) > self::PREVIEWCOLUMNSLIMIT) {
              echo $OUTPUT->notification(get_string('questionslimited', 'feedback', self::PREVIEWCOLUMNSLIMIT), 'info');
          }
  
          $this->out($this->showall ? $grandtotal : FEEDBACK_DEFAULT_PAGE_COUNT,
                  $grandtotal > FEEDBACK_DEFAULT_PAGE_COUNT);
  
          // Toggle 'Show all' link.
          if ($this->totalrows > FEEDBACK_DEFAULT_PAGE_COUNT) {
              if (!$this->use_pages) {
                  echo html_writer::div(html_writer::link(new moodle_url($this->baseurl, [$this->showallparamname => 0]),
                          get_string('showperpage', '', FEEDBACK_DEFAULT_PAGE_COUNT)), 'showall');
              } else {
                  echo html_writer::div(html_writer::link(new moodle_url($this->baseurl, [$this->showallparamname => 1]),
                          get_string('showall', '', $this->totalrows)), 'showall');
              }
          }
      }
code: public function display() {
          global $OUTPUT;
          groups_print_activity_menu($this->feedbackstructure->get_cm(), $this->baseurl->out());
          $grandtotal = $this->get_total_responses_count();
          if (!$grandtotal) {
              echo $OUTPUT->box(get_string('nothingtodisplay'), 'generalbox nothingtodisplay');
              return;
          }
  
          if (count($this->feedbackstructure->get_items(true)) > self::PREVIEWCOLUMNSLIMIT) {
              echo $OUTPUT->notification(get_string('questionslimited', 'feedback', self::PREVIEWCOLUMNSLIMIT), 'info');
          }
  
          $this->out($this->showall ? $grandtotal : FEEDBACK_DEFAULT_PAGE_COUNT,
                  $grandtotal > FEEDBACK_DEFAULT_PAGE_COUNT);
  
          // Toggle 'Show all' link.
          if ($this->totalrows > FEEDBACK_DEFAULT_PAGE_COUNT) {
              if (!$this->use_pages) {
                  echo html_writer::div(html_writer::link(new moodle_url($this->baseurl, [$this->showallparamname => 0]),
                          get_string('showperpage', '', FEEDBACK_DEFAULT_PAGE_COUNT)), 'showall');
              } else {
                  echo html_writer::div(html_writer::link(new moodle_url($this->baseurl, [$this->showallparamname => 1]),
                          get_string('showall', '', $this->totalrows)), 'showall');
              }
          }
      }
code_tokens: public function display ( ) { global $ OUTPUT ; groups_print_activity_menu ( $ this -> feedbackstructure -> get_cm ( ) , $ this -> baseurl -> out ( ) ) ; $ grandtotal = $ this -> get_total_responses_count ( ) ; if ( ! $ grandtotal ) { echo $ OUTPUT -> box ( get_string ( 'nothingtodisplay' ) , 'generalbox nothingtodisplay' ) ; return ; } if ( count ( $ this -> feedbackstructure -> get_items ( true ) ) > self :: PREVIEWCOLUMNSLIMIT ) { echo $ OUTPUT -> notification ( get_string ( 'questionslimited' , 'feedback' , self :: PREVIEWCOLUMNSLIMIT ) , 'info' ) ; } $ this -> out ( $ this -> showall ? $ grandtotal : FEEDBACK_DEFAULT_PAGE_COUNT , $ grandtotal > FEEDBACK_DEFAULT_PAGE_COUNT ) ; // Toggle 'Show all' link. if ( $ this -> totalrows > FEEDBACK_DEFAULT_PAGE_COUNT ) { if ( ! $ this -> use_pages ) { echo html_writer :: div ( html_writer :: link ( new moodle_url ( $ this -> baseurl , [ $ this -> showallparamname => 0 ] ) , get_string ( 'showperpage' , '' , FEEDBACK_DEFAULT_PAGE_COUNT ) ) , 'showall' ) ; } else { echo html_writer :: div ( html_writer :: link ( new moodle_url ( $ this -> baseurl , [ $ this -> showallparamname => 1 ] ) , get_string ( 'showall' , '' , $ this -> totalrows ) ) , 'showall' ) ; } } }
docstring: Displays the table
docstring_tokens: Displays the table