block_tasksummary.php 671 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. class block_tasksummary extends block_base {
  3. public function init() {
  4. $this->title = get_string('block_title', 'block_tasksummary');
  5. }
  6. public function get_content() {
  7. global $USER;
  8. $this->content = new stdClass;
  9. $this->content->text = 'Exemplo Bloco Educação e Dados';
  10. $url = new moodle_url('/blocks/tasksummary/pages/tasksummary.php', [
  11. #'var1' => $var1,
  12. ]);
  13. $attr = [
  14. 'class'=>'btn btn-xs btn-success'
  15. ];
  16. $this->content->text .= html_writer::link($url, 'Ver resumo completo', $attr) . '<br><br>';
  17. return $this->content;
  18. }
  19. }