MDL-81872 course: Improve wording and workflow for reset

This commit is contained in:
Sara Arjona 2024-05-08 18:20:01 +02:00
parent b2e325836b
commit 22cc975705
No known key found for this signature in database
40 changed files with 115 additions and 82 deletions

View File

@ -0,0 +1,12 @@
issueNumber: MDL-81872
notes:
core_course:
- message: >+
The reset course page has been improved. The "Delete" or "Remove" wording have been removed from all the options to make it easier to focus on the data to be removed and avoid inconsistencies and duplicated information.
Third party plugins implementing reset methods might need to:
- Add static element in the _reset_course_form_definition method before all the options with the Delete string:
`$mform->addElement('static', 'assigndelete', get_string('delete'));`
- Review all the strings used in the reset page to remove the "Delete" or "Remove" words from them.
type: changed

View File

@ -41,6 +41,7 @@ class course_reset_form extends moodleform {
$mform->addHelpButton('reset_start_date', 'startdate');
$mform->addElement('date_time_selector', 'reset_end_date', get_string('enddate'), ['optional' => true]);
$mform->addHelpButton('reset_end_date', 'enddate');
$mform->addElement('static', 'generaldelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_events', get_string('deleteevents', 'calendar'));
$mform->addElement('checkbox', 'reset_notes', get_string('deletenotes', 'notes'));
$mform->addElement('checkbox', 'reset_comments', get_string('deleteallcomments', 'moodle'));
@ -53,12 +54,17 @@ class course_reset_form extends moodleform {
$roles = get_assignable_roles(context_course::instance($COURSE->id));
$roles[0] = get_string('noroles', 'role');
$roles = array_reverse($roles, true);
$mform->addElement('select', 'unenrol_users', get_string('unenrolroleusers', 'enrol'), $roles, ['multiple' => 'multiple']);
$mform->addElement('checkbox', 'reset_roles_overrides', get_string('deletecourseoverrides', 'role'));
$mform->setAdvanced('reset_roles_overrides');
$attributes = [
'multiple' => 1,
'size' => min(count($roles), 10),
];
$mform->addElement('select', 'unenrol_users', get_string('unenrolroleusers', 'enrol'), $roles, $attributes);
$mform->addElement('static', 'rolesdelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_roles_local', get_string('deletelocalroles', 'role'));
$mform->addElement('checkbox', 'reset_roles_overrides', get_string('deletecourseoverrides', 'role'));
$mform->addElement('header', 'gradebookheader', get_string('gradebook', 'grades'));
$mform->addElement('static', 'gradebookdelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_gradebook_items', get_string('removeallcourseitems', 'grades'));
$mform->addHelpButton('reset_gradebook_items', 'removeallcourseitems', 'grades');
$mform->addElement('checkbox', 'reset_gradebook_grades', get_string('removeallcoursegrades', 'grades'));
@ -66,6 +72,7 @@ class course_reset_form extends moodleform {
$mform->disabledIf('reset_gradebook_grades', 'reset_gradebook_items', 'checked');
$mform->addElement('header', 'groupheader', get_string('groups'));
$mform->addElement('static', 'groupdelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_groups_remove', get_string('deleteallgroups', 'group'));
$mform->addElement('checkbox', 'reset_groups_members', get_string('removegroupsmembers', 'group'));
$mform->disabledIf('reset_groups_members', 'reset_groups_remove', 'checked');
@ -98,9 +105,9 @@ class course_reset_form extends moodleform {
// Mention unsupported mods.
if (!empty($unsupportedmods)) {
$mform->addElement('header', 'unsupportedheader', get_string('resetnotimplemented'));
$mform->addElement('static', 'unsupportedinfo', get_string('resetnotimplementedinfo'));
foreach ($unsupportedmods as $mod) {
$mform->addElement('static', 'unsup'.$mod->name, get_string('modulenameplural', $mod->name));
$mform->setAdvanced('unsup'.$mod->name);
}
}

View File

@ -229,4 +229,3 @@ class grade_export_form extends moodleform {
return $data;
}
}

View File

@ -68,7 +68,7 @@ $string['configuseexternalblogs'] = 'Enables users to specify external blog feed
$string['courseblog'] = 'Course blog: {$a}';
$string['courseblogdisable'] = 'Course blogs are not enabled';
$string['courseblogs'] = 'Users can only see blogs for people who share a course';
$string['deleteblogassociations'] = 'Delete blog associations';
$string['deleteblogassociations'] = 'Blog associations';
$string['deleteblogassociations_help'] = 'If ticked then blog entries will no longer be associated with this course or any course activities or resources. The blog entries themselves will not be deleted.';
$string['deleteentry'] = 'Delete entry';
$string['deleteexternalblog'] = 'Unregister this external blog';

View File

@ -66,7 +66,7 @@ $string['dayviewtitle'] = 'Day view: {$a}';
$string['daywithnoevents'] = 'There are no events this day.';
$string['default'] = 'Default';
$string['deleteevent'] = 'Delete event';
$string['deleteevents'] = 'Delete events';
$string['deleteevents'] = 'Events';
$string['deleteoneevent'] = 'Delete this event';
$string['deleteallevents'] = 'Delete all events';
$string['detailedmonthviewfor'] = 'Detailed month view for:';

View File

@ -37,7 +37,7 @@ $string['coursemodulecompetencyoutcome_complete'] = 'Complete the competency';
$string['coursemodulecompetencyoutcome_evidence'] = 'Attach evidence';
$string['coursemodulecompetencyoutcome_none'] = 'Do nothing';
$string['coursemodulecompetencyoutcome_recommend'] = 'Send for review';
$string['deletecompetencyratings'] = 'Delete competency ratings';
$string['deletecompetencyratings'] = 'Competency ratings';
$string['duplicateditemname'] = '{$a} (copy)';
$string['enablecompetencies'] = 'Enable competencies';
$string['enablecompetencies_desc'] = 'Competencies allow users to be assessed according to learning plans.';
@ -200,4 +200,3 @@ $string['usercompetencystatus_idle'] = 'Idle';
$string['usercompetencystatus_inreview'] = 'In review';
$string['usercompetencystatus_waitingforreview'] = 'Waiting for review';
$string['userplans'] = 'Learning plans';

View File

@ -145,7 +145,7 @@ $string['defaultactivitycompletionsite'] = 'These are the default completion con
$string['defaultactivitycompletioncourse'] = 'These are the default completion conditions for activities in this course.';
$string['defaultcompletion'] = 'Default activity completion';
$string['defaultcompletionupdated'] = 'Changes saved';
$string['deletecompletiondata'] = 'Delete completion data';
$string['deletecompletiondata'] = 'Completion data';
$string['dependencies'] = 'Dependencies';
$string['dependenciescompleted'] = 'Completion of other courses';
$string['detail_desc:receivegrade'] = 'Receive a grade';

View File

@ -715,9 +715,9 @@ $string['recovergradesdefault'] = 'Recover grades default';
$string['recovergradesdefault_help'] = 'By default recover old grades when re-enrolling a user in a course.';
$string['refreshpreview'] = 'Refresh preview';
$string['regradeanyway'] = 'Regrade anyway';
$string['removeallcoursegrades'] = 'Delete all grades';
$string['removeallcoursegrades'] = 'All grades';
$string['removeallcoursegrades_help'] = 'If ticked, all grade items and grades that were manually added to the gradebook will be deleted, as well as data on overridden, excluded, hidden and locked grades. Only grade items and grades associated with activities will remain.';
$string['removeallcourseitems'] = 'Delete all items and categories';
$string['removeallcourseitems'] = 'All items and categories';
$string['removeallcourseitems_help'] = 'If ticked, all categories and grade items which were manually added to the gradebook will be deleted, together with grades and data on overridden, excluded, hidden and locked grades. Only grade items associated with activities will remain.';
$string['report'] = 'Report';
$string['reportdefault'] = 'Report default ({$a})';

View File

@ -48,8 +48,8 @@ $string['databaseupgradegroups'] = 'Groups version is now {$a}';
$string['defaultgrouping'] = 'Default grouping';
$string['defaultgroupingname'] = 'Grouping';
$string['defaultgroupname'] = 'Group';
$string['deleteallgroupings'] = 'Delete all groupings';
$string['deleteallgroups'] = 'Delete all groups';
$string['deleteallgroupings'] = 'All groupings';
$string['deleteallgroups'] = 'All groups';
$string['deletegroupconfirm'] = 'Are you sure you want to delete group \'{$a}\'?';
$string['deletegrouping'] = 'Delete grouping';
$string['deletegroupingconfirm'] = 'Are you sure you want to delete grouping \'{$a}\'? (Groups in the grouping are not deleted.)';
@ -196,8 +196,8 @@ $string['random'] = 'Randomly';
$string['removegroupfromselectedgrouping'] = 'Remove group from grouping';
$string['removefromgroup'] = 'Remove user from group {$a}';
$string['removefromgroupconfirm'] = 'Do you really want to remove user "{$a->user}" from group "{$a->group}"?';
$string['removegroupingsmembers'] = 'Remove all groups from groupings';
$string['removegroupsmembers'] = 'Remove all group members';
$string['removegroupingsmembers'] = 'All groups from groupings';
$string['removegroupsmembers'] = 'All group members';
$string['removeselectedusers'] = 'Remove selected users';
$string['selectfromgroup'] = 'Select members from group';
$string['selectfromgrouping'] = 'Select members from grouping';

View File

@ -520,8 +520,8 @@ $string['delete'] = 'Delete';
$string['deleteablock'] = 'Delete a block';
$string['deleteall'] = 'Delete all';
$string['deleteallcannotundo'] = 'Delete all - cannot be undone';
$string['deleteallcomments'] = 'Delete all comments';
$string['deleteallratings'] = 'Delete all ratings';
$string['deleteallcomments'] = 'All comments';
$string['deleteallratings'] = 'All ratings';
$string['deletecategory'] = 'Delete category: {$a}';
$string['deletecategoryempty'] = 'This category is empty.';
$string['deletecategorycheck'] = 'Are you absolutely sure you want to completely delete this category <b>\'{$a}\'</b>?<br />This will move all courses into the parent category if there is one, or into Miscellaneous.';
@ -1864,7 +1864,8 @@ $string['reset'] = 'Reset';
$string['resetcomponent'] = 'Component';
$string['resetcourse'] = 'Reset course';
$string['resetinfo'] = 'Delete all user data and reset this course to its original state, keeping activities and settings intact.';
$string['resetnotimplemented'] = 'Reset not implemented';
$string['resetnotimplemented'] = 'Reset not supported';
$string['resetnotimplementedinfo'] = 'These activities can\'t be reset:';
$string['resetrecordexpired'] = 'The password reset link you used is more than {$a} minutes old and has expired. Please initiate a new password reset.';
$string['resetstartdate'] = 'Reset start date';
$string['resetstatus'] = 'Status';

View File

@ -37,7 +37,7 @@ $string['course'] = 'course';
$string['coursenotes'] = 'Course notes';
$string['created'] = 'created';
$string['deleteconfirm'] = 'Delete this note?';
$string['deletenotes'] = 'Delete all notes';
$string['deletenotes'] = 'All notes';
$string['editnote'] = 'Edit note';
$string['enablenotes'] = 'Enable notes';
$string['eventnotecreated'] = 'Note created';

View File

@ -226,8 +226,8 @@ $string['defaultrole'] = 'Default role';
$string['defaultx'] = 'Default: {$a}';
$string['defineroles'] = 'Define roles';
$string['definitionofrolex'] = 'Definition of role \'{$a}\'';
$string['deletecourseoverrides'] = 'Delete all overrides in course';
$string['deletelocalroles'] = 'Delete all local role assignments';
$string['deletecourseoverrides'] = 'All overrides in course';
$string['deletelocalroles'] = 'All local role assignments';
$string['deleterolesure'] = '<p>Are you sure that you want to delete role "{$a->name} ({$a->shortname})"?</p><p>Currently this role is assigned to {$a->count} users.</p>';
$string['deletexrole'] = 'Delete {$a} role';
$string['duplicaterole'] = 'Duplicate role';

View File

@ -157,7 +157,7 @@ $string['defaultlayout'] = 'Restore default layout';
$string['defaultsettings'] = 'Default assignment settings';
$string['defaultsettings_help'] = 'These settings define the defaults for all new assignments.';
$string['defaultteam'] = 'Default group';
$string['deleteallsubmissions'] = 'Delete all submissions';
$string['deleteallsubmissions'] = 'All submissions';
$string['description'] = 'Description';
$string['disabled'] = 'Disabled';
$string['downloadall'] = 'Download all submissions';
@ -469,8 +469,8 @@ $string['quickgradingresult'] = 'Quick grading';
$string['quickgradingchangessaved'] = 'The grade changes were saved';
$string['quickgrading_help'] = 'Quick grading allows you to assign grades (and outcomes) directly in the submissions table. Quick grading is not compatible with advanced grading and is not recommended when there are multiple markers.';
$string['relativedatessubmissiontimeleft'] = 'Calculated for each student';
$string['removeallgroupoverrides'] = 'Delete all group overrides';
$string['removealluseroverrides'] = 'Delete all user overrides';
$string['removeallgroupoverrides'] = 'All group overrides';
$string['removealluseroverrides'] = 'All user overrides';
$string['reopenuntilpassincompatiblewithblindmarking'] = 'Reopen until pass option is incompatible with anonymous submissions, because the grades are not released to the gradebook until the student identities are revealed.';
$string['requiresubmissionstatement'] = 'Require that students accept the submission statement';
$string['requiresubmissionstatement_help'] = 'Require that students accept the submission statement for all submissions to this assignment.';

View File

@ -207,6 +207,7 @@ function assign_reset_gradebook($courseid, $type='') {
*/
function assign_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'assignheader', get_string('modulenameplural', 'assign'));
$mform->addElement('static', 'assigndelete', get_string('delete'));
$name = get_string('deleteallsubmissions', 'assign');
$mform->addElement('advcheckbox', 'reset_assign_submissions', $name);
$mform->addElement('advcheckbox', 'reset_assign_user_overrides',

View File

@ -111,7 +111,7 @@ $string['subchapternotice'] = '(Only available once the first chapter has been c
$string['subplugintype_booktool'] = 'Book tool';
$string['subplugintype_booktool_plural'] = 'Book tools';
$string['removeallbooktags'] = 'Remove all book tags';
$string['removeallbooktags'] = 'All book tags';
$string['tagarea_book_chapters'] = 'Book chapters';
$string['tagsdeleted'] = 'Book tags have been deleted';

View File

@ -171,6 +171,7 @@ function book_reset_userdata($data) {
*/
function book_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'bookheader', get_string('modulenameplural', 'book'));
$mform->addElement('static', 'bookdelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_book_tags', get_string('removeallbooktags', 'book'));
}

View File

@ -142,7 +142,7 @@ $string['privacy:metadata:messages:timestamp'] = 'The time when the message was
$string['privacy:metadata:messages:userid'] = 'The user ID of the author of the message';
$string['refreshroom'] = 'Refresh room';
$string['refreshuserlist'] = 'Refresh user list';
$string['removemessages'] = 'Remove all messages';
$string['removemessages'] = 'All messages';
$string['repeatdaily'] = 'At the same time every day';
$string['repeatnone'] = 'No repeats - publish the specified time only';
$string['repeattimes'] = 'Repeat/publish session times';

View File

@ -1208,6 +1208,7 @@ function chat_print_overview() {
*/
function chat_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'chatheader', get_string('modulenameplural', 'chat'));
$mform->addElement('static', 'chatdelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_chat', get_string('removemessages', 'chat'));
}

View File

@ -137,7 +137,7 @@ $string['publishinfonever'] = 'The results of this activity will not be publishe
$string['publishnames'] = 'Publish full results, showing names and their choices';
$string['publishnot'] = 'Do not publish results to students';
$string['removemychoice'] = 'Remove my choice';
$string['removeresponses'] = 'Remove all responses';
$string['removeresponses'] = 'All responses';
$string['responses'] = 'Responses';
$string['responsesresultgraphheader'] = 'Graph display';
$string['responsesa'] = 'Responses: {$a}';

View File

@ -725,7 +725,8 @@ function choice_get_post_actions() {
*/
function choice_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'choiceheader', get_string('modulenameplural', 'choice'));
$mform->addElement('advcheckbox', 'reset_choice', get_string('removeresponses','choice'));
$mform->addElement('static', 'choicedelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_choice', get_string('removeresponses', 'choice'));
}
/**

View File

@ -114,13 +114,13 @@ $string['defaultfieldenclosure'] = '(default is none)';
$string['defaultsortfield'] = 'Default sort field';
$string['delcheck'] = 'Bulk delete checkbox';
$string['delete'] = 'Delete';
$string['deleteallentries'] = 'Delete all entries';
$string['deleteallentries'] = 'All entries';
$string['deletecomment'] = 'Are you sure you want to delete this comment?';
$string['deleteconfirm'] = 'Delete preset {$a}?';
$string['deleted'] = 'deleted';
$string['deleteentry'] = 'Delete entry';
$string['deletefield'] = 'Delete field';
$string['deletenotenrolled'] = 'Delete entries by users not enrolled';
$string['deletenotenrolled'] = 'Entries by users not enrolled';
$string['deletewarning'] = 'Deleting a preset removes it from the list of available presets in all courses.';
$string['descending'] = 'Descending';
$string['directorynotapreset'] = '{$a->directory} Not a preset: missing files: {$a->missing_files}';
@ -381,7 +381,7 @@ $string['recorddeleted'] = 'Entry deleted';
$string['recorddisapproved'] = 'Entry unapproved';
$string['recordsnotsaved'] = 'No entry was saved. Please check the format of the uploaded file.';
$string['recordssaved'] = 'entries saved';
$string['removealldatatags'] = 'Remove all database tags';
$string['removealldatatags'] = 'All database tags';
$string['requireapproval'] = 'Approval required';
$string['requireapproval_help'] = 'A teacher has to approve entries before theyre visible to everyone.';
$string['required'] = 'Required';

View File

@ -2833,6 +2833,7 @@ function data_preset_path($course, $userid, $shortname) {
*/
function data_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'dataheader', get_string('modulenameplural', 'data'));
$mform->addElement('static', 'datadelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_data', get_string('deleteallentries','data'));
$mform->addElement('checkbox', 'reset_data_notenrolled', get_string('deletenotenrolled', 'data'));

View File

@ -613,7 +613,7 @@ $string['qandaforum'] = 'Q and A forum';
$string['qandanotify'] = 'This is a question and answer forum. To see other replies, you must first post your reply.';
$string['re'] = 'Re:';
$string['readtherest'] = 'Read the rest of this topic';
$string['removeallforumtags'] = 'Remove all forum tags';
$string['removeallforumtags'] = 'All forum tags';
$string['removefromfavourites'] = 'Unstar this discussion';
$string['replies'] = 'Replies';
$string['repliesmany'] = '{$a} replies so far';
@ -628,10 +628,10 @@ $string['replytouser'] = 'Use email address in reply';
$string['reply_handler'] = 'Reply to forum posts via email';
$string['reply_handler_name'] = 'Reply to forum posts';
$string['resetforums'] = 'Delete posts from';
$string['resetforumsall'] = 'Delete all posts';
$string['resetdigests'] = 'Delete all per-user forum digest preferences';
$string['resetsubscriptions'] = 'Delete all forum subscriptions';
$string['resettrackprefs'] = 'Delete all forum tracking preferences';
$string['resetforumsall'] = 'All posts';
$string['resetdigests'] = 'All per-user forum digest preferences';
$string['resetsubscriptions'] = 'All forum subscriptions';
$string['resettrackprefs'] = 'All forum tracking preferences';
$string['rsssubscriberssdiscussions'] = 'RSS feed of discussions';
$string['rsssubscriberssposts'] = 'RSS feed of posts';
$string['rssarticles'] = 'Number of RSS recent articles';

View File

@ -5255,28 +5255,31 @@ function forum_reset_userdata($data) {
*/
function forum_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'forumheader', get_string('modulenameplural', 'forum'));
$mform->addElement('static', 'forumdelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_forum_all', get_string('resetforumsall','forum'));
$mform->addElement('checkbox', 'reset_forum_digests', get_string('resetdigests', 'forum'));
$mform->addElement('select', 'reset_forum_types', get_string('resetforums', 'forum'), forum_get_forum_types_all(), array('multiple' => 'multiple'));
$mform->setAdvanced('reset_forum_types');
$mform->disabledIf('reset_forum_types', 'reset_forum_all', 'checked');
$mform->addElement('checkbox', 'reset_forum_subscriptions', get_string('resetsubscriptions', 'forum'));
$mform->addElement('checkbox', 'reset_forum_digests', get_string('resetdigests','forum'));
$mform->setAdvanced('reset_forum_digests');
$mform->addElement('checkbox', 'reset_forum_all', get_string('resetforumsall', 'forum'));
$mform->addElement('checkbox', 'reset_forum_subscriptions', get_string('resetsubscriptions','forum'));
$mform->setAdvanced('reset_forum_subscriptions');
$mform->addElement(
'select',
'reset_forum_types',
get_string('resetforums', 'forum'),
forum_get_forum_types_all(),
['multiple' => 'multiple'],
);
$mform->hideIf('reset_forum_types', 'reset_forum_all', 'checked');
$mform->addElement('checkbox', 'reset_forum_track_prefs', get_string('resettrackprefs','forum'));
$mform->setAdvanced('reset_forum_track_prefs');
$mform->disabledIf('reset_forum_track_prefs', 'reset_forum_all', 'checked');
$mform->addElement('checkbox', 'reset_forum_track_prefs', get_string('resettrackprefs', 'forum'));
$mform->hideIf('reset_forum_track_prefs', 'reset_forum_all', 'checked');
$mform->addElement('checkbox', 'reset_forum_ratings', get_string('deleteallratings'));
$mform->disabledIf('reset_forum_ratings', 'reset_forum_all', 'checked');
$mform->hideIf('reset_forum_ratings', 'reset_forum_all', 'checked');
$mform->addElement('checkbox', 'reset_forum_tags', get_string('removeallforumtags', 'forum'));
$mform->disabledIf('reset_forum_tags', 'reset_forum_all', 'checked');
$mform->hideIf('reset_forum_tags', 'reset_forum_all', 'checked');
}
/**

View File

@ -109,7 +109,7 @@ $string['definitions'] = 'Definitions';
$string['deleteentry'] = 'Delete entry';
$string['deletecategory'] = 'Delete category';
$string['deleteentrya'] = 'Delete entry: {$a}';
$string['deletenotenrolled'] = 'Delete entries by users not enrolled';
$string['deletenotenrolled'] = 'Entries by users not enrolled';
$string['deletingcomment'] = 'Deleting comment';
$string['deletingnoneemptycategory'] = 'Deleting this category will not delete the entries it contains - they will be marked as uncategorised.';
$string['descending'] = 'descending';
@ -301,9 +301,9 @@ $string['privacy:metadata:glossary_entries:timemodified'] = 'The timestamp indic
$string['question'] = 'Question';
$string['rejectedentries'] = 'Rejected entries';
$string['rejectionrpt'] = 'Rejection report';
$string['removeallglossarytags'] = 'Remove all glossary tags';
$string['removeallglossarytags'] = 'All glossary tags';
$string['resetglossaries'] = 'Delete entries from';
$string['resetglossariesall'] = 'Delete entries from all glossaries';
$string['resetglossariesall'] = 'Entries from all glossaries';
$string['rssarticles'] = 'Number of RSS recent articles';
$string['rssarticles_help'] = 'This setting specifies the number of glossary entry concepts to include in the RSS feed. Between 5 and 20 generally acceptable.';
$string['rsssubscriberss'] = 'Display the RSS feed for \'{$a}\' concepts';

View File

@ -2795,24 +2795,24 @@ function glossary_get_post_actions() {
*/
function glossary_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'glossaryheader', get_string('modulenameplural', 'glossary'));
$mform->addElement('static', 'glossarydelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_glossary_all', get_string('resetglossariesall','glossary'));
$mform->addElement('select', 'reset_glossary_types', get_string('resetglossaries', 'glossary'),
array('main'=>get_string('mainglossary', 'glossary'), 'secondary'=>get_string('secondaryglossary', 'glossary')), array('multiple' => 'multiple'));
$mform->setAdvanced('reset_glossary_types');
$mform->disabledIf('reset_glossary_types', 'reset_glossary_all', 'checked');
$mform->hideIf('reset_glossary_types', 'reset_glossary_all', 'checked');
$mform->addElement('checkbox', 'reset_glossary_notenrolled', get_string('deletenotenrolled', 'glossary'));
$mform->disabledIf('reset_glossary_notenrolled', 'reset_glossary_all', 'checked');
$mform->hideIf('reset_glossary_notenrolled', 'reset_glossary_all', 'checked');
$mform->addElement('checkbox', 'reset_glossary_ratings', get_string('deleteallratings'));
$mform->disabledIf('reset_glossary_ratings', 'reset_glossary_all', 'checked');
$mform->hideIf('reset_glossary_ratings', 'reset_glossary_all', 'checked');
$mform->addElement('checkbox', 'reset_glossary_comments', get_string('deleteallcomments'));
$mform->disabledIf('reset_glossary_comments', 'reset_glossary_all', 'checked');
$mform->hideIf('reset_glossary_comments', 'reset_glossary_all', 'checked');
$mform->addElement('checkbox', 'reset_glossary_tags', get_string('removeallglossarytags', 'glossary'));
$mform->disabledIf('reset_glossary_tags', 'reset_glossary_all', 'checked');
$mform->hideIf('reset_glossary_tags', 'reset_glossary_all', 'checked');
}
/**

View File

@ -58,7 +58,7 @@ $string['completion'] = 'Completion';
$string['contentbank'] = 'More information about the content bank';
$string['contentbank_help'] = 'In the content bank you can create and store content using several authoring tools, including an integrated H5P creator.';
$string['correct_answer'] = 'Correct answer';
$string['deleteallattempts'] = 'Delete all H5P attempts';
$string['deleteallattempts'] = 'All H5P attempts';
$string['displayexport'] = 'Allow download';
$string['displayembed'] = 'Embed button';
$string['displaycopyright'] = 'Copyright button';

View File

@ -253,6 +253,7 @@ function h5pactivity_rescale_activity_grades(stdClass $course, stdClass $cm, flo
*/
function h5pactivity_reset_course_form_definition(&$mform): void {
$mform->addElement('header', 'h5pactivityheader', get_string('modulenameplural', 'mod_h5pactivity'));
$mform->addElement('static', 'h5pactivitydelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_h5pactivity', get_string('deleteallattempts', 'mod_h5pactivity'));
}

View File

@ -146,7 +146,7 @@ $string['customscoring'] = 'Custom scoring';
$string['customscoring_help'] = 'If enabled, a whole number value (positive or negative) may be entered for each answer.';
$string['deadline'] = 'Deadline';
$string['defaultessayresponse'] = 'Your essay will be graded by your teacher.';
$string['deleteallattempts'] = 'Delete all lesson attempts';
$string['deleteallattempts'] = 'All lesson attempts';
$string['deletedefaults'] = 'Deleted {$a} x lesson default';
$string['deletedpage'] = 'Deleted page';
$string['deletepagenamed'] = 'Delete page: {$a}';
@ -515,8 +515,8 @@ $string['rank'] = 'Rank';
$string['rawgrade'] = 'Raw grade';
$string['receivedcredit'] = 'Received credit';
$string['redisplaypage'] = 'Redisplay page';
$string['removeallgroupoverrides'] = 'Delete all group overrides';
$string['removealluseroverrides'] = 'Delete all user overrides';
$string['removeallgroupoverrides'] = 'All group overrides';
$string['removealluseroverrides'] = 'All user overrides';
$string['report'] = 'Report';
$string['reports'] = 'Reports';
$string['response'] = 'Response';

View File

@ -836,7 +836,8 @@ function lesson_process_post_save(&$lesson) {
*/
function lesson_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'lessonheader', get_string('modulenameplural', 'lesson'));
$mform->addElement('advcheckbox', 'reset_lesson', get_string('deleteallattempts','lesson'));
$mform->addElement('static', 'lessondelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_lesson', get_string('deleteallattempts', 'lesson'));
$mform->addElement('advcheckbox', 'reset_lesson_user_overrides',
get_string('removealluseroverrides', 'lesson'));
$mform->addElement('advcheckbox', 'reset_lesson_group_overrides',

View File

@ -867,9 +867,9 @@ $string['regradenotallowed'] = 'You do not have permission to regrade this quiz'
$string['regradingquestion'] = 'Regrading "{$a}".';
$string['regradingquiz'] = 'Regrading quiz "{$a}"';
$string['remove'] = 'Remove';
$string['removeallgroupoverrides'] = 'Delete all group overrides';
$string['removeallquizattempts'] = 'Delete all quiz attempts';
$string['removealluseroverrides'] = 'Delete all user overrides';
$string['removeallgroupoverrides'] = 'All group overrides';
$string['removeallquizattempts'] = 'All quiz attempts';
$string['removealluseroverrides'] = 'All user overrides';
$string['removeemptypage'] = 'Remove empty page';
$string['removepagebreak'] = 'Remove page break';
$string['removeselected'] = 'Remove selected';

View File

@ -1415,6 +1415,7 @@ function quiz_questions_in_use($questionids) {
*/
function quiz_reset_course_form_definition($mform) {
$mform->addElement('header', 'quizheader', get_string('modulenameplural', 'quiz'));
$mform->addElement('static', 'quizdelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_quiz_attempts',
get_string('removeallquizattempts', 'quiz'));
$mform->addElement('advcheckbox', 'reset_quiz_user_overrides',

View File

@ -107,7 +107,7 @@ $string['defaultdisplaysettings'] = 'Default display settings';
$string['defaultgradesettings'] = 'Default grade settings';
$string['defaultothersettings'] = 'Other default settings';
$string['deleteattemptcheck'] = 'Are you absolutely sure you want to completely delete these attempts?';
$string['deleteallattempts'] = 'Delete all SCORM attempts';
$string['deleteallattempts'] = 'All SCORM attempts';
$string['deleteselected'] = 'Delete selected attempts';
$string['deleteuserattemptcheck'] = 'Are you absolutely sure you want to completely delete all your attempts?';
$string['details'] = 'Track details';

View File

@ -776,6 +776,7 @@ function scorm_option2text($scorm) {
*/
function scorm_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'scormheader', get_string('modulenameplural', 'scorm'));
$mform->addElement('static', 'scormdelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_scorm', get_string('deleteallattempts', 'scorm'));
}

View File

@ -188,8 +188,8 @@ $string['colles8short'] = 'I\'m critical of readings';
$string['colles9'] = 'I explain my ideas to other students.';
$string['colles9short'] = 'I explain my ideas';
$string['customintro'] = 'Description';
$string['deleteallanswers'] = 'Delete all survey responses';
$string['deleteanalysis'] = 'Delete response analysis';
$string['deleteallanswers'] = 'All survey responses';
$string['deleteanalysis'] = 'Response analysis';
$string['done'] = 'Done';
$string['download'] = 'Download';
$string['downloadexcel'] = 'Download data as Excel spreadsheet';

View File

@ -726,9 +726,10 @@ function survey_get_post_actions() {
*/
function survey_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'surveyheader', get_string('modulenameplural', 'survey'));
$mform->addElement('checkbox', 'reset_survey_answers', get_string('deleteallanswers','survey'));
$mform->addElement('checkbox', 'reset_survey_analysis', get_string('deleteanalysis','survey'));
$mform->disabledIf('reset_survey_analysis', 'reset_survey_answers', 'checked');
$mform->addElement('static', 'surveydelete', get_string('delete'));
$mform->addElement('checkbox', 'reset_survey_answers', get_string('deleteallanswers', 'survey'));
$mform->addElement('checkbox', 'reset_survey_analysis', get_string('deleteanalysis', 'survey'));
$mform->hideIf('reset_survey_analysis', 'reset_survey_answers', 'checked');
}
/**

View File

@ -44,7 +44,7 @@ $string['defaultformat_help'] = 'This setting determines the default format used
* HTML - The HTML editor is available
* Creole - A common wiki markup language for which a small edit toolbar is available
* Nwiki - Mediawiki-like markup language used in the contributed Nwiki module';
$string['deleteallpages'] = 'Delete all wiki pages';
$string['deleteallpages'] = 'All wiki pages';
$string['deletecomment'] = 'Deleting comment';
$string['deletecommentcheck'] = 'Delete comment';
$string['deletecommentcheckfull'] = 'Are you sure you want to delete the comment?';
@ -237,7 +237,7 @@ $string['ratingmode'] = 'Rating mode';
$string['reparsetimeout'] = 'Reparsing default timeout';
$string['repeatedsection'] = 'Wiki error: Section name cannot be repeated \'{$a}\'';
$string['restore'] = 'Restore';
$string['removeallwikitags'] = 'Remove all wiki tags';
$string['removeallwikitags'] = 'All wiki tags';
$string['removepages'] = 'Remove pages';
$string['restoreconfirm'] = 'Are you sure you want to restore version #{$a}?';
$string['restoreerror'] = 'Version #{$a} could not be restored';
@ -311,4 +311,3 @@ $string['wiki:viewpage'] = 'View wiki pages';
$string['wikipages'] = 'Wiki pages';
$string['wrongversionlock'] = 'Another user has edited this page while you were editing and your content is obsolete.';
$string['wrongversionsave'] = 'Another user has created a version while you were editing and you have overwritten his changes, check the page history.';

View File

@ -257,6 +257,7 @@ function wiki_reset_userdata($data) {
function wiki_reset_course_form_definition(&$mform) {
$mform->addElement('header', 'wikiheader', get_string('modulenameplural', 'wiki'));
$mform->addElement('static', 'wikidelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_wiki_pages', get_string('deleteallpages', 'wiki'));
$mform->addElement('advcheckbox', 'reset_wiki_tags', get_string('removeallwikitags', 'wiki'));
$mform->addElement('advcheckbox', 'reset_wiki_comments', get_string('deleteallcomments'));

View File

@ -318,9 +318,9 @@ $string['reassess'] = 'Re-assess';
$string['receivedgrades'] = 'Grades received';
$string['recentassessments'] = 'Workshop assessments:';
$string['recentsubmissions'] = 'Workshop submissions:';
$string['resetassessments'] = 'Delete all assessments';
$string['resetassessments'] = 'All assessments';
$string['resetassessments_help'] = 'You can choose to delete just allocated assessments without affecting submissions. If submissions are to be deleted, their assessments will be deleted implicitly and this option is ignored. Note this also includes assessments of example submissions.';
$string['resetsubmissions'] = 'Delete all submissions';
$string['resetsubmissions'] = 'All submissions';
$string['resetsubmissions_help'] = 'All the submissions and their assessments will be deleted. This does not affect example submissions.';
$string['resetphase'] = 'Switch to the setup phase';
$string['resetphase_help'] = 'If enabled, all workshops will be put into the initial setup phase.';

View File

@ -1985,15 +1985,17 @@ function workshop_reset_course_form_definition($mform) {
$mform->addElement('header', 'workshopheader', get_string('modulenameplural', 'mod_workshop'));
$mform->addElement('advcheckbox', 'reset_workshop_phase', get_string('resetphase', 'mod_workshop'));
$mform->addHelpButton('reset_workshop_phase', 'resetphase', 'mod_workshop');
$mform->addElement('static', 'workshopdelete', get_string('delete'));
$mform->addElement('advcheckbox', 'reset_workshop_submissions', get_string('resetsubmissions', 'mod_workshop'));
$mform->addHelpButton('reset_workshop_submissions', 'resetsubmissions', 'mod_workshop');
$mform->addElement('advcheckbox', 'reset_workshop_assessments', get_string('resetassessments', 'mod_workshop'));
$mform->addHelpButton('reset_workshop_assessments', 'resetassessments', 'mod_workshop');
$mform->disabledIf('reset_workshop_assessments', 'reset_workshop_submissions', 'checked');
$mform->addElement('advcheckbox', 'reset_workshop_phase', get_string('resetphase', 'mod_workshop'));
$mform->addHelpButton('reset_workshop_phase', 'resetphase', 'mod_workshop');
$mform->hideIf('reset_workshop_assessments', 'reset_workshop_submissions', 'checked');
}
/**