Browse Source

Melhorias na apresentação

master
Sesostris Vieira 11 years ago
parent
commit
d084ed6e95
  1. 10
      index.php
  2. 1
      lang/en/report_ilbenrol.php
  3. 1
      lang/pt_br/report_ilbenrol.php
  4. 5
      report_form.php

10
index.php

@ -202,9 +202,15 @@ if ($csv && $userlist) { // Only show CSV if there are some users
groups_print_course_menu($course,$CFG->wwwroot.'/report/ilbenrol/?course='.$course->id); groups_print_course_menu($course,$CFG->wwwroot.'/report/ilbenrol/?course='.$course->id);
// Print filter form // Print filter form
echo $OUTPUT->box_start();
echo '<strong>'.get_string('filter', 'report_ilbenrol').'</strong>';
$mform->display(); $mform->display();
echo $OUTPUT->box_end();
echo '<br/>';
// Print summary table // Print summary table
echo $OUTPUT->box_start();
echo '<strong>'.get_string('summary', 'report_ilbenrol').'</strong>';
$thead = array(''); $thead = array('');
$talign = array('left'); $talign = array('left');
foreach ($roles as $role) { foreach ($roles as $role) {
@ -236,6 +242,8 @@ if ($csv && $userlist) { // Only show CSV if there are some users
echo html_writer::table($table); echo html_writer::table($table);
} }
echo $OUTPUT->box_end();
echo '<br/>';
} }
// If no users in this filter // If no users in this filter
@ -352,7 +360,7 @@ if ($total > ILBENROL_REPORT_PAGE) {
// Start of table // Start of table
if (!$csv) { if (!$csv) {
print '<br class="clearer"/>'; // ugh print '<br/>'; // ugh
print $pagingbar; print $pagingbar;

1
lang/en/report_ilbenrol.php

@ -26,6 +26,7 @@
$string['pluginname'] = 'ILB Enrol Confirmation'; $string['pluginname'] = 'ILB Enrol Confirmation';
$string['title'] = 'ILB Enrol Confirmation Report'; $string['title'] = 'ILB Enrol Confirmation Report';
$string['filter'] = 'Filters'; $string['filter'] = 'Filters';
$string['summary'] = 'Summaries';
$string['filterfields'] = 'Filter fields'; $string['filterfields'] = 'Filter fields';
$string['userroles'] = 'User roles'; $string['userroles'] = 'User roles';
$string['confirmed'] = 'Role to confirmed enrollment'; $string['confirmed'] = 'Role to confirmed enrollment';

1
lang/pt_br/report_ilbenrol.php

@ -26,6 +26,7 @@
$string['pluginname'] = 'Confirmação de matrícula ILB'; $string['pluginname'] = 'Confirmação de matrícula ILB';
$string['title'] = 'Relatório de confirmação de matrícula'; $string['title'] = 'Relatório de confirmação de matrícula';
$string['filter'] = 'Filtros'; $string['filter'] = 'Filtros';
$string['summary'] = 'Sumários';
$string['filterfields'] = 'Campos de filtragem'; $string['filterfields'] = 'Campos de filtragem';
$string['userroles'] = 'Funções'; $string['userroles'] = 'Funções';
$string['confirmed'] = 'Função para matrícula confirmada'; $string['confirmed'] = 'Função para matrícula confirmada';

5
report_form.php

@ -49,10 +49,10 @@ class filter_form extends moodleform {
$courseid = $this->_courseid; $courseid = $this->_courseid;
$filterfields = $this->_filterfields; $filterfields = $this->_filterfields;
$mform->addElement('header', 'filter', get_string('filter', 'report_ilbenrol')); // $mform->addElement('header', 'filter', get_string('filter', 'report_ilbenrol'));
foreach ($filterfields as $field) { foreach ($filterfields as $field) {
$mform->addElement('static', $field->shortname, $field->name, ''); $mform->addElement('header', $field->shortname, $field->name);
$options = explode("\n", $field->param1); $options = explode("\n", $field->param1);
foreach ($options as $option) { foreach ($options as $option) {
$mform->addElement('checkbox', "{$field->shortname}[$option]", $option); $mform->addElement('checkbox', "{$field->shortname}[$option]", $option);
@ -61,5 +61,6 @@ class filter_form extends moodleform {
$mform->addElement('submit', 'filterbutton', get_string('applyfilter', 'report_ilbenrol')); $mform->addElement('submit', 'filterbutton', get_string('applyfilter', 'report_ilbenrol'));
$mform->addElement('hidden', 'course', $courseid); $mform->addElement('hidden', 'course', $courseid);
$mform->closeHeaderBefore('filterbutton');
} }
} }

Loading…
Cancel
Save