Commit e0c22222 authored by Marina Glancy's avatar Marina Glancy Committed by Eloy Lafuente
Browse files

MDL-45336 questionbank: use core strings instead of quiz

AMOS BEGIN
 CPY [categories,mod_quiz],[categories,question]
 CPY [unusedcategorydeleted,mod_quiz],[unusedcategorydeleted,question]
 CPY [export,mod_quiz],[export,core_question]
 CPY [import,mod_quiz],[import,core_question]
AMOS END
parent 8766d198
...@@ -60,6 +60,7 @@ $string['cannotretrieveqcat'] = 'Could not retrieve question category'; ...@@ -60,6 +60,7 @@ $string['cannotretrieveqcat'] = 'Could not retrieve question category';
$string['cannotunhidequestion'] = 'Failed to unhide the question.'; $string['cannotunhidequestion'] = 'Failed to unhide the question.';
$string['cannotunzip'] = 'Could not unzip file.'; $string['cannotunzip'] = 'Could not unzip file.';
$string['cannotwriteto'] = 'Cannot write exported questions to {$a}'; $string['cannotwriteto'] = 'Cannot write exported questions to {$a}';
$string['categories'] = 'Categories';
$string['categorycurrent'] = 'Current category'; $string['categorycurrent'] = 'Current category';
$string['categorycurrentuse'] = 'Use this category'; $string['categorycurrentuse'] = 'Use this category';
$string['categorydoesnotexist'] = 'This category does not exist'; $string['categorydoesnotexist'] = 'This category does not exist';
...@@ -139,6 +140,7 @@ $string['errorprocessingresponses'] = 'An error occurred while processing your r ...@@ -139,6 +140,7 @@ $string['errorprocessingresponses'] = 'An error occurred while processing your r
$string['errorsavingcomment'] = 'Error saving the comment for question {$a->name} in the database.'; $string['errorsavingcomment'] = 'Error saving the comment for question {$a->name} in the database.';
$string['errorupdatingattempt'] = 'Error updating attempt {$a->id} in the database.'; $string['errorupdatingattempt'] = 'Error updating attempt {$a->id} in the database.';
$string['eventquestioncategorycreated'] = 'Question category created'; $string['eventquestioncategorycreated'] = 'Question category created';
$string['export'] = 'Export';
$string['exportcategory'] = 'Export category'; $string['exportcategory'] = 'Export category';
$string['exportcategory_help'] = 'This setting determines the category from which the exported questions will be taken. $string['exportcategory_help'] = 'This setting determines the category from which the exported questions will be taken.
...@@ -167,6 +169,7 @@ $string['chooseqtypetoadd'] = 'Choose a question type to add'; ...@@ -167,6 +169,7 @@ $string['chooseqtypetoadd'] = 'Choose a question type to add';
$string['editquestions'] = 'Edit questions'; $string['editquestions'] = 'Edit questions';
$string['ignorebroken'] = 'Ignore broken links'; $string['ignorebroken'] = 'Ignore broken links';
$string['impossiblechar'] = 'Impossible character {$a} detected as parenthesis character'; $string['impossiblechar'] = 'Impossible character {$a} detected as parenthesis character';
$string['import'] = 'Import';
$string['importcategory'] = 'Import category'; $string['importcategory'] = 'Import category';
$string['importcategory_help'] = 'This setting determines the category into which the imported questions will go. $string['importcategory_help'] = 'This setting determines the category into which the imported questions will go.
...@@ -430,6 +433,7 @@ $string['unknownorunhandledtype'] = 'Unknown or unhandled question type: {$a}'; ...@@ -430,6 +433,7 @@ $string['unknownorunhandledtype'] = 'Unknown or unhandled question type: {$a}';
$string['unknownquestion'] = 'Unknown question: {$a}.'; $string['unknownquestion'] = 'Unknown question: {$a}.';
$string['unknownquestioncatregory'] = 'Unknown question category: {$a}.'; $string['unknownquestioncatregory'] = 'Unknown question category: {$a}.';
$string['unknownquestiontype'] = 'Unknown question type: {$a}.'; $string['unknownquestiontype'] = 'Unknown question type: {$a}.';
$string['unusedcategorydeleted'] = 'This category has been deleted because, after deleting the course, its questions weren\'t used any more.';
$string['whethercorrect'] = 'Whether correct'; $string['whethercorrect'] = 'Whether correct';
$string['whethercorrect_help'] = 'This covers both the textual description \'Correct\', \'Partially correct\' or \'Incorrect\', and any coloured highlighting that conveys the same information.'; $string['whethercorrect_help'] = 'This covers both the textual description \'Correct\', \'Partially correct\' or \'Incorrect\', and any coloured highlighting that conveys the same information.';
$string['whichtries'] = 'Which tries'; $string['whichtries'] = 'Which tries';
......
...@@ -360,7 +360,7 @@ function question_delete_course($course, $feedback=true) { ...@@ -360,7 +360,7 @@ function question_delete_course($course, $feedback=true) {
$feedbackdata = array(); $feedbackdata = array();
//Cache some strings //Cache some strings
$strcatdeleted = get_string('unusedcategorydeleted', 'quiz'); $strcatdeleted = get_string('unusedcategorydeleted', 'question');
$coursecontext = context_course::instance($course->id); $coursecontext = context_course::instance($course->id);
$categoriescourse = $DB->get_records('question_categories', $categoriescourse = $DB->get_records('question_categories',
array('contextid' => $coursecontext->id), 'parent', 'id, parent, name, contextid'); array('contextid' => $coursecontext->id), 'parent', 'id, parent, name, contextid');
...@@ -391,7 +391,7 @@ function question_delete_course($course, $feedback=true) { ...@@ -391,7 +391,7 @@ function question_delete_course($course, $feedback=true) {
//Inform about changes performed if feedback is enabled //Inform about changes performed if feedback is enabled
if ($feedback) { if ($feedback) {
$table = new html_table(); $table = new html_table();
$table->head = array(get_string('category', 'quiz'), get_string('action')); $table->head = array(get_string('category', 'question'), get_string('action'));
$table->data = $feedbackdata; $table->data = $feedbackdata;
echo html_writer::table($table); echo html_writer::table($table);
} }
...@@ -417,7 +417,7 @@ function question_delete_course_category($category, $newcategory, $feedback=true ...@@ -417,7 +417,7 @@ function question_delete_course_category($category, $newcategory, $feedback=true
if (empty($newcategory)) { if (empty($newcategory)) {
$feedbackdata = array(); // To store feedback to be showed at the end of the process $feedbackdata = array(); // To store feedback to be showed at the end of the process
$rescueqcategory = null; // See the code around the call to question_save_from_deletion. $rescueqcategory = null; // See the code around the call to question_save_from_deletion.
$strcatdeleted = get_string('unusedcategorydeleted', 'quiz'); $strcatdeleted = get_string('unusedcategorydeleted', 'question');
// Loop over question categories. // Loop over question categories.
if ($categories = $DB->get_records('question_categories', if ($categories = $DB->get_records('question_categories',
...@@ -544,7 +544,7 @@ function question_delete_activity($cm, $feedback=true) { ...@@ -544,7 +544,7 @@ function question_delete_activity($cm, $feedback=true) {
$feedbackdata = array(); $feedbackdata = array();
//Cache some strings //Cache some strings
$strcatdeleted = get_string('unusedcategorydeleted', 'quiz'); $strcatdeleted = get_string('unusedcategorydeleted', 'question');
$modcontext = context_module::instance($cm->id); $modcontext = context_module::instance($cm->id);
if ($categoriesmods = $DB->get_records('question_categories', if ($categoriesmods = $DB->get_records('question_categories',
array('contextid' => $modcontext->id), 'parent', 'id, parent, name, contextid')) { array('contextid' => $modcontext->id), 'parent', 'id, parent, name, contextid')) {
...@@ -572,7 +572,7 @@ function question_delete_activity($cm, $feedback=true) { ...@@ -572,7 +572,7 @@ function question_delete_activity($cm, $feedback=true) {
//Inform about changes performed if feedback is enabled //Inform about changes performed if feedback is enabled
if ($feedback) { if ($feedback) {
$table = new html_table(); $table = new html_table();
$table->head = array(get_string('category', 'quiz'), get_string('action')); $table->head = array(get_string('category', 'question'), get_string('action'));
$table->data = $feedbackdata; $table->data = $feedbackdata;
echo html_writer::table($table); echo html_writer::table($table);
} }
...@@ -1496,19 +1496,19 @@ function question_extend_settings_navigation(navigation_node $navigationnode, $c ...@@ -1496,19 +1496,19 @@ function question_extend_settings_navigation(navigation_node $navigationnode, $c
$contexts = new question_edit_contexts($context); $contexts = new question_edit_contexts($context);
if ($contexts->have_one_edit_tab_cap('questions')) { if ($contexts->have_one_edit_tab_cap('questions')) {
$questionnode->add(get_string('questions', 'quiz'), new moodle_url( $questionnode->add(get_string('questions', 'question'), new moodle_url(
'/question/edit.php', $params), navigation_node::TYPE_SETTING); '/question/edit.php', $params), navigation_node::TYPE_SETTING);
} }
if ($contexts->have_one_edit_tab_cap('categories')) { if ($contexts->have_one_edit_tab_cap('categories')) {
$questionnode->add(get_string('categories', 'quiz'), new moodle_url( $questionnode->add(get_string('categories', 'question'), new moodle_url(
'/question/category.php', $params), navigation_node::TYPE_SETTING); '/question/category.php', $params), navigation_node::TYPE_SETTING);
} }
if ($contexts->have_one_edit_tab_cap('import')) { if ($contexts->have_one_edit_tab_cap('import')) {
$questionnode->add(get_string('import', 'quiz'), new moodle_url( $questionnode->add(get_string('import', 'question'), new moodle_url(
'/question/import.php', $params), navigation_node::TYPE_SETTING); '/question/import.php', $params), navigation_node::TYPE_SETTING);
} }
if ($contexts->have_one_edit_tab_cap('export')) { if ($contexts->have_one_edit_tab_cap('export')) {
$questionnode->add(get_string('export', 'quiz'), new moodle_url( $questionnode->add(get_string('export', 'question'), new moodle_url(
'/question/export.php', $params), navigation_node::TYPE_SETTING); '/question/export.php', $params), navigation_node::TYPE_SETTING);
} }
......
invalidnumericanswer,mod_quiz invalidnumericanswer,mod_quiz
multiplier,mod_quiz multiplier,mod_quiz
invalidnumerictolerance,mod_quiz invalidnumerictolerance,mod_quiz
unusedcategorydeleted,mod_quiz
categories,mod_quiz
import,mod_quiz
export,mod_quiz
category,mod_quiz
...@@ -137,8 +137,6 @@ $string['cannotwrite'] = 'Cannot write to export file ({$a})'; ...@@ -137,8 +137,6 @@ $string['cannotwrite'] = 'Cannot write to export file ({$a})';
$string['caseno'] = 'No, case is unimportant'; $string['caseno'] = 'No, case is unimportant';
$string['casesensitive'] = 'Case sensitivity'; $string['casesensitive'] = 'Case sensitivity';
$string['caseyes'] = 'Yes, case must match'; $string['caseyes'] = 'Yes, case must match';
$string['categories'] = 'Categories';
$string['category'] = 'Category';
$string['categoryadded'] = 'The category \'{$a}\' was added'; $string['categoryadded'] = 'The category \'{$a}\' was added';
$string['categorydeleted'] = 'The category \'{$a}\' was deleted'; $string['categorydeleted'] = 'The category \'{$a}\' was deleted';
$string['categorynoedit'] = 'You do not have editing privileges in the category \'{$a}\'.'; $string['categorynoedit'] = 'You do not have editing privileges in the category \'{$a}\'.';
...@@ -327,7 +325,6 @@ $string['eventreportviewed'] = 'Quiz report viewed'; ...@@ -327,7 +325,6 @@ $string['eventreportviewed'] = 'Quiz report viewed';
$string['everynquestions'] = 'Every {$a} questions'; $string['everynquestions'] = 'Every {$a} questions';
$string['everyquestion'] = 'Every question'; $string['everyquestion'] = 'Every question';
$string['everythingon'] = 'Everything on'; $string['everythingon'] = 'Everything on';
$string['export'] = 'Export';
$string['exportcategory'] = 'export category'; $string['exportcategory'] = 'export category';
$string['exporterror'] = 'An error occurred during export processing'; $string['exporterror'] = 'An error occurred during export processing';
$string['exportingquestions'] = 'Questions are being exported to file'; $string['exportingquestions'] = 'Questions are being exported to file';
...@@ -394,7 +391,6 @@ $string['hidereordertool'] = 'Hide the reordering tool'; ...@@ -394,7 +391,6 @@ $string['hidereordertool'] = 'Hide the reordering tool';
$string['history'] = 'History of responses:'; $string['history'] = 'History of responses:';
$string['howquestionsbehave_desc'] = 'Default setting for how questions behave in a quiz.'; $string['howquestionsbehave_desc'] = 'Default setting for how questions behave in a quiz.';
$string['imagedisplay'] = 'Image to display'; $string['imagedisplay'] = 'Image to display';
$string['import'] = 'Import';
$string['import_help'] = 'This function allows you to import questions from external text files. $string['import_help'] = 'This function allows you to import questions from external text files.
If your file contains non-ascii characters then it must use UTF-8 encoding. Be particularly cautious with files generated by Microsoft Office applications, as these commonly use special encoding which will not be handled correctly. If your file contains non-ascii characters then it must use UTF-8 encoding. Be particularly cautious with files generated by Microsoft Office applications, as these commonly use special encoding which will not be handled correctly.
...@@ -875,7 +871,6 @@ $string['unfinished'] = 'open'; ...@@ -875,7 +871,6 @@ $string['unfinished'] = 'open';
$string['ungraded'] = 'Ungraded'; $string['ungraded'] = 'Ungraded';
$string['unit'] = 'Unit'; $string['unit'] = 'Unit';
$string['unknowntype'] = 'Question type not supported at line {$a}. The question will be ignored'; $string['unknowntype'] = 'Question type not supported at line {$a}. The question will be ignored';
$string['unusedcategorydeleted'] = 'This category has been deleted because, after deleting the course, its questions weren\'t used any more.';
$string['updatesettings'] = 'Update quiz settings'; $string['updatesettings'] = 'Update quiz settings';
$string['updatingatttemptgrades'] = 'Updating attempt grades.'; $string['updatingatttemptgrades'] = 'Updating attempt grades.';
$string['updatingfinalgrades'] = 'Updating final grades.'; $string['updatingfinalgrades'] = 'Updating final grades.';
...@@ -903,6 +898,11 @@ $string['yourfinalgradeis'] = 'Your final grade for this quiz is {$a}.'; ...@@ -903,6 +898,11 @@ $string['yourfinalgradeis'] = 'Your final grade for this quiz is {$a}.';
// Deprecated since Moodle 2.8 // Deprecated since Moodle 2.8
$string['categories'] = 'Categories';
$string['category'] = 'Category';
$string['export'] = 'Export';
$string['import'] = 'Import';
$string['invalidnumericanswer'] = 'One of the answers you entered was not a valid number.'; $string['invalidnumericanswer'] = 'One of the answers you entered was not a valid number.';
$string['invalidnumerictolerance'] = 'One of the tolerances you entered was not a valid number.'; $string['invalidnumerictolerance'] = 'One of the tolerances you entered was not a valid number.';
$string['multiplier'] = 'Multiplier'; $string['multiplier'] = 'Multiplier';
$string['unusedcategorydeleted'] = 'This category has been deleted because, after deleting the course, its questions weren\'t used any more.';
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment