| Línea 31... |
Línea 31... |
| 31 |
* Assignment grading options form
|
31 |
* Assignment grading options form
|
| 32 |
*
|
32 |
*
|
| 33 |
* @package mod_assign
|
33 |
* @package mod_assign
|
| 34 |
* @copyright 2012 NetSpot {@link http://www.netspot.com.au}
|
34 |
* @copyright 2012 NetSpot {@link http://www.netspot.com.au}
|
| 35 |
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
35 |
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
| - |
|
36 |
* @deprecated since 4.5
|
| - |
|
37 |
* @todo Final deprecation in Moodle 6.0. See MDL-82869.
|
| 36 |
*/
|
38 |
*/
|
| - |
|
39 |
#[\core\attribute\deprecated(
|
| - |
|
40 |
replacement: null,
|
| - |
|
41 |
since: '4.5',
|
| - |
|
42 |
reason: 'It is no longer used.',
|
| - |
|
43 |
mdl: 'MDL-80750',
|
| - |
|
44 |
)]
|
| 37 |
class mod_assign_grading_batch_operations_form extends moodleform {
|
45 |
class mod_assign_grading_batch_operations_form extends moodleform {
|
| 38 |
/**
|
46 |
/**
|
| 39 |
* Define this form - called by the parent constructor.
|
47 |
* Define this form - called by the parent constructor.
|
| - |
|
48 |
*
|
| - |
|
49 |
* @deprecated since 4.5
|
| 40 |
*/
|
50 |
*/
|
| - |
|
51 |
#[\core\attribute\deprecated(
|
| - |
|
52 |
replacement: null,
|
| - |
|
53 |
since: '4.5',
|
| - |
|
54 |
reason: 'It is no longer used.',
|
| - |
|
55 |
mdl: 'MDL-80750'
|
| - |
|
56 |
)]
|
| 41 |
public function definition() {
|
57 |
public function definition() {
|
| - |
|
58 |
\core\deprecation::emit_deprecation([$this, __FUNCTION__]);
|
| - |
|
59 |
|
| 42 |
global $CFG;
|
60 |
global $CFG;
|
| 43 |
$mform = $this->_form;
|
61 |
$mform = $this->_form;
|
| 44 |
$instance = $this->_customdata;
|
62 |
$instance = $this->_customdata;
|
| Línea 45... |
Línea 63... |
| 45 |
|
63 |
|
| Línea 60... |
Línea 78... |
| 60 |
$options['removesubmission'] = get_string('removesubmission', 'assign');
|
78 |
$options['removesubmission'] = get_string('removesubmission', 'assign');
|
| 61 |
}
|
79 |
}
|
| 62 |
if ($instance['duedate'] && has_capability('mod/assign:grantextension', $instance['context'])) {
|
80 |
if ($instance['duedate'] && has_capability('mod/assign:grantextension', $instance['context'])) {
|
| 63 |
$options['grantextension'] = get_string('grantextension', 'assign');
|
81 |
$options['grantextension'] = get_string('grantextension', 'assign');
|
| 64 |
}
|
82 |
}
|
| - |
|
83 |
$multipleattemptsallowed = $instance['maxattempts'] > 1 ||
|
| - |
|
84 |
$instance['maxattempts'] == ASSIGN_UNLIMITED_ATTEMPTS;
|
| - |
|
85 |
|
| 65 |
if ($instance['attemptreopenmethod'] == ASSIGN_ATTEMPT_REOPEN_METHOD_MANUAL) {
|
86 |
if ($multipleattemptsallowed && $instance['attemptreopenmethod'] == ASSIGN_ATTEMPT_REOPEN_METHOD_MANUAL) {
|
| 66 |
$options['addattempt'] = get_string('addattempt', 'assign');
|
87 |
$options['addattempt'] = get_string('addattempt', 'assign');
|
| 67 |
}
|
88 |
}
|
| Línea 68... |
Línea 89... |
| 68 |
|
89 |
|
| 69 |
foreach ($instance['feedbackplugins'] as $plugin) {
|
90 |
foreach ($instance['feedbackplugins'] as $plugin) {
|
| Línea 95... |
Línea 116... |
| 95 |
$objs[] =& $mform->createElement('submit', 'submit', get_string('go'));
|
116 |
$objs[] =& $mform->createElement('submit', 'submit', get_string('go'));
|
| 96 |
$batchdescription = get_string('batchoperationsdescription', 'assign');
|
117 |
$batchdescription = get_string('batchoperationsdescription', 'assign');
|
| 97 |
$mform->addElement('group', 'actionsgrp', $batchdescription, $objs, ' ', false);
|
118 |
$mform->addElement('group', 'actionsgrp', $batchdescription, $objs, ' ', false);
|
| 98 |
}
|
119 |
}
|
| 99 |
}
|
120 |
}
|
| 100 |
|
- |
|