mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 13:38:32 +01:00
MDL-43628 mod_assign: fixed formatting of statement
This commit is contained in:
parent
4067991016
commit
2949dedcda
@ -3739,7 +3739,13 @@ class assign {
|
||||
|
||||
$submissionstatement = '';
|
||||
if (!empty($adminconfig->submissionstatement)) {
|
||||
$submissionstatement = $adminconfig->submissionstatement;
|
||||
// Format the submissino statement before its sent. We turn off para because this is going within
|
||||
// a form element.
|
||||
$options = array(
|
||||
'context' => $this->get_context(),
|
||||
'para' => false
|
||||
);
|
||||
$submissionstatement = format_text($adminconfig->submissionstatement, FORMAT_MOODLE, $options);
|
||||
}
|
||||
|
||||
if ($mform == null) {
|
||||
@ -4996,7 +5002,13 @@ class assign {
|
||||
|
||||
$submissionstatement = '';
|
||||
if (!empty($adminconfig->submissionstatement)) {
|
||||
$submissionstatement = $adminconfig->submissionstatement;
|
||||
// Format the submissino statement before its sent. We turn off para because this is going within
|
||||
// a form element.
|
||||
$options = array(
|
||||
'context' => $this->get_context(),
|
||||
'para' => false
|
||||
);
|
||||
$submissionstatement = format_text($adminconfig->submissionstatement, FORMAT_MOODLE, $options);
|
||||
}
|
||||
|
||||
if ($mform == null) {
|
||||
@ -6196,9 +6208,15 @@ class assign {
|
||||
|
||||
$submissionstatement = '';
|
||||
if (!empty($adminconfig->submissionstatement)) {
|
||||
$submissionstatement = $adminconfig->submissionstatement;
|
||||
// Format the submissino statement before its sent. We turn off para because this is going within
|
||||
// a form element.
|
||||
$options = array(
|
||||
'context' => $this->get_context(),
|
||||
'para' => false
|
||||
);
|
||||
$submissionstatement = format_text($adminconfig->submissionstatement, FORMAT_MOODLE, $options);
|
||||
}
|
||||
$mform->addElement('checkbox', 'submissionstatement', '', ' ' . $submissionstatement);
|
||||
$mform->addElement('checkbox', 'submissionstatement', '', $submissionstatement);
|
||||
$mform->addRule('submissionstatement', get_string('required'), 'required', null, 'client');
|
||||
}
|
||||
|
||||
|
@ -301,3 +301,10 @@
|
||||
.path-mod-assign .gradingtable .menu-action img {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.path-mod-assign .editsubmissionform input[name="submissionstatement"] {
|
||||
vertical-align: top;
|
||||
}
|
||||
.path-mod-assign .editsubmissionform label[for="id_submissionstatement"] {
|
||||
display: inline-block;
|
||||
}
|
@ -47,7 +47,7 @@ class mod_assign_confirm_submission_form extends moodleform {
|
||||
$data) = $this->_customdata;
|
||||
|
||||
if ($requiresubmissionstatement) {
|
||||
$mform->addElement('checkbox', 'submissionstatement', '', ' ' . format_text($submissionstatement));
|
||||
$mform->addElement('checkbox', 'submissionstatement', '', $submissionstatement);
|
||||
$mform->addRule('submissionstatement', get_string('required'), 'required', null, 'client');
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user