2024-11-21 18:59:07 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Form class for user selection
|
|
|
|
*/
|
|
|
|
class usergrades_form extends moodleform
|
|
|
|
{
|
|
|
|
public function definition()
|
|
|
|
{
|
|
|
|
$mform = $this->_form;
|
|
|
|
|
|
|
|
// User selector
|
|
|
|
$user_selector = new user_selector('userid', array('multiselect' => false));
|
|
|
|
$users = $user_selector->find_users('');
|
|
|
|
|
|
|
|
$mform->addElement('select', 'userid', get_string('selectuser', 'report_usergrades'), $users[get_string('users')]);
|
|
|
|
|
2024-11-25 09:09:36 +00:00
|
|
|
// XLSX Export checkbox
|
|
|
|
$mform->addElement('checkbox', 'exportxls', get_string('exportxls', 'report_usergrades'));
|
|
|
|
|
2024-11-21 18:59:07 +00:00
|
|
|
// Add form action buttons
|
|
|
|
$this->add_action_buttons(false, get_string('showgrades', 'report_usergrades'));
|
|
|
|
}
|
|
|
|
}
|