mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-19067 removed obsoleted string (never used in any STABLE branch)
This commit is contained in:
parent
739ee4e679
commit
6d40f12e5b
@ -51,16 +51,12 @@ $string['cannotfindanswer'] = 'Error: could not find answer';
|
|||||||
$string['cannotfindgrade'] = 'Error: could not find grades';
|
$string['cannotfindgrade'] = 'Error: could not find grades';
|
||||||
$string['cannotfindrecords'] = 'Error: could not find lesson records';
|
$string['cannotfindrecords'] = 'Error: could not find lesson records';
|
||||||
$string['cannotfinduser'] = 'Error: could not find users';
|
$string['cannotfinduser'] = 'Error: could not find users';
|
||||||
$string['cannotdeleteanswer'] = 'Update page: unable to delete answer record';
|
|
||||||
$string['cannotdeleteattempt'] = 'Error: could not delete old attempts';
|
|
||||||
$string['cannotdeletebranch'] = 'Error: could not delete old seen branches';
|
|
||||||
$string['cannotinsertanswer'] = 'Cannot insert answer record';
|
$string['cannotinsertanswer'] = 'Cannot insert answer record';
|
||||||
$string['cannotinserthighscore'] = 'Insert of new high score Failed!';
|
$string['cannotinserthighscore'] = 'Insert of new high score Failed!';
|
||||||
$string['cannotinsertpage'] = 'Cannot insert new page';
|
$string['cannotinsertpage'] = 'Cannot insert new page';
|
||||||
$string['cannotinserttimer'] = 'Error: could not insert row into lesson_timer table';
|
$string['cannotinserttimer'] = 'Error: could not insert row into lesson_timer table';
|
||||||
$string['cannotupdateanswer'] = 'Update page: answer not updated';
|
$string['cannotupdateanswer'] = 'Update page: answer not updated';
|
||||||
$string['cannotupdatebook'] = 'Cannot update your book';
|
$string['cannotupdatebook'] = 'Cannot update your book';
|
||||||
$string['cannotupdategrade'] = 'Cannot update grade';
|
|
||||||
$string['cannotupdatelink'] = 'Cannot update link';
|
$string['cannotupdatelink'] = 'Cannot update link';
|
||||||
$string['cannotupdatepage'] = 'Update page: page not updated';
|
$string['cannotupdatepage'] = 'Update page: page not updated';
|
||||||
$string['cannotupdatetimer'] = 'Error: could not update lesson_timer table';
|
$string['cannotupdatetimer'] = 'Error: could not update lesson_timer table';
|
||||||
|
@ -61,7 +61,6 @@ $string['attlsname'] = 'ATTLS (20 item version)';
|
|||||||
$string['cannotfindsurveytmpt'] = 'No survey templates found!';
|
$string['cannotfindsurveytmpt'] = 'No survey templates found!';
|
||||||
$string['cannotfindquestion'] = 'Question doesn\'t exist';
|
$string['cannotfindquestion'] = 'Question doesn\'t exist';
|
||||||
$string['cannotfindanswer'] = 'There are no answers for this survey yet.';
|
$string['cannotfindanswer'] = 'There are no answers for this survey yet.';
|
||||||
$string['cannotinsertanswer'] = 'Encountered a problem trying to store your results. Sorry.';
|
|
||||||
$string['ciq1'] = 'At what moment in class were you most engaged as a learner?';
|
$string['ciq1'] = 'At what moment in class were you most engaged as a learner?';
|
||||||
$string['ciq1short'] = 'Most engaged';
|
$string['ciq1short'] = 'Most engaged';
|
||||||
$string['ciq2'] = 'At what moment in class were you most distanced as a learner?';
|
$string['ciq2'] = 'At what moment in class were you most distanced as a learner?';
|
||||||
|
@ -35,9 +35,7 @@
|
|||||||
$newpage->timecreated = $timenow;
|
$newpage->timecreated = $timenow;
|
||||||
$newpage->title = get_string("clustertitle", "lesson");
|
$newpage->title = get_string("clustertitle", "lesson");
|
||||||
$newpage->contents = get_string("clustertitle", "lesson");
|
$newpage->contents = get_string("clustertitle", "lesson");
|
||||||
if (!$newpageid = $DB->insert_record("lesson_pages", $newpage)) {
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list...
|
// update the linked list...
|
||||||
if ($pageid != 0) {
|
if ($pageid != 0) {
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
||||||
|
@ -37,9 +37,7 @@
|
|||||||
$newpage->timecreated = $timenow;
|
$newpage->timecreated = $timenow;
|
||||||
$newpage->title = get_string("endofbranch", "lesson");
|
$newpage->title = get_string("endofbranch", "lesson");
|
||||||
$newpage->contents = get_string("endofbranch", "lesson");
|
$newpage->contents = get_string("endofbranch", "lesson");
|
||||||
if (!$newpageid = $DB->insert_record("lesson_pages", $newpage)) {
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list...
|
// update the linked list...
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
||||||
print_error('cannotupdatelink', 'lesson');
|
print_error('cannotupdatelink', 'lesson');
|
||||||
|
@ -28,9 +28,7 @@
|
|||||||
$newpage->timecreated = $timenow;
|
$newpage->timecreated = $timenow;
|
||||||
$newpage->title = get_string("endofclustertitle", "lesson");
|
$newpage->title = get_string("endofclustertitle", "lesson");
|
||||||
$newpage->contents = get_string("endofclustertitle", "lesson");
|
$newpage->contents = get_string("endofclustertitle", "lesson");
|
||||||
if (!$newpageid = $DB->insert_record("lesson_pages", $newpage)) {
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list...
|
// update the linked list...
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
||||||
print_error('cannotupdatelink', 'lesson');
|
print_error('cannotupdatelink', 'lesson');
|
||||||
|
@ -47,18 +47,11 @@
|
|||||||
$newpage->contents = trim($form->contents);
|
$newpage->contents = trim($form->contents);
|
||||||
$newpage->title = $newpage->title;
|
$newpage->title = $newpage->title;
|
||||||
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
if (!$newpageid) {
|
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list (point the previous page to this new one)
|
// update the linked list (point the previous page to this new one)
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $newpage->prevpageid))) {
|
$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $newpage->prevpageid));
|
||||||
print_error('cannotupdatelink', 'lesson');
|
|
||||||
}
|
|
||||||
if ($page->nextpageid) {
|
if ($page->nextpageid) {
|
||||||
// new page is not the last page
|
// new page is not the last page
|
||||||
if (!$DB->set_field("lesson_pages", "prevpageid", $newpageid, array("id" => $page->nextpageid))) {
|
$DB->set_field("lesson_pages", "prevpageid", $newpageid, array("id" => $page->nextpageid));
|
||||||
print_error('cannotupdatelink', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// new page is the first page
|
// new page is the first page
|
||||||
@ -90,9 +83,6 @@
|
|||||||
$newpage->contents = trim($form->contents);
|
$newpage->contents = trim($form->contents);
|
||||||
$newpage->title = $newpage->title;
|
$newpage->title = $newpage->title;
|
||||||
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
if (!$newpageid) {
|
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// there are existing pages put this at the start
|
// there are existing pages put this at the start
|
||||||
$newpage->lessonid = $lesson->id;
|
$newpage->lessonid = $lesson->id;
|
||||||
|
@ -70,9 +70,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!$DB->update_record("lesson_answers", $oldanswer)) {
|
$DB->update_record("lesson_answers", $oldanswer);
|
||||||
print_error('cannotupdateanswer', 'lesson');
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// it's an "ordinary" page
|
// it's an "ordinary" page
|
||||||
if ($page->qtype == LESSON_MATCHING) {
|
if ($page->qtype == LESSON_MATCHING) {
|
||||||
@ -105,9 +103,7 @@
|
|||||||
if (isset($form->score[$i])) {
|
if (isset($form->score[$i])) {
|
||||||
$oldanswer->score = clean_param($form->score[$i], PARAM_INT);
|
$oldanswer->score = clean_param($form->score[$i], PARAM_INT);
|
||||||
}
|
}
|
||||||
if (!$DB->update_record("lesson_answers", $oldanswer)) {
|
$DB->update_record("lesson_answers", $oldanswer);
|
||||||
print_error('cannotupdateanswer', 'lesson');
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// it's a new answer
|
// it's a new answer
|
||||||
$newanswer = new stdClass; // need to clear id if more than one new answer is ben added
|
$newanswer = new stdClass; // need to clear id if more than one new answer is ben added
|
||||||
@ -152,9 +148,7 @@
|
|||||||
$form->responseeditor[$i] * LESSON_RESPONSE_EDITOR;
|
$form->responseeditor[$i] * LESSON_RESPONSE_EDITOR;
|
||||||
$oldanswer->timemodified = $timenow;
|
$oldanswer->timemodified = $timenow;
|
||||||
$oldanswer->answer = NULL;
|
$oldanswer->answer = NULL;
|
||||||
if (!$DB->update_record("lesson_answers", $oldanswer)) {
|
$DB->update_record("lesson_answers", $oldanswer);
|
||||||
print_error('cannotupdateanswer', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} elseif (!empty($form->answerid[$i])) {
|
} elseif (!empty($form->answerid[$i])) {
|
||||||
// need to delete blanked out answer
|
// need to delete blanked out answer
|
||||||
|
@ -93,13 +93,9 @@ class qformat_default {
|
|||||||
$newpage->prevpageid = $pageid;
|
$newpage->prevpageid = $pageid;
|
||||||
$newpage->nextpageid = $page->nextpageid;
|
$newpage->nextpageid = $page->nextpageid;
|
||||||
// insert the page and reset $pageid
|
// insert the page and reset $pageid
|
||||||
if (!$newpageid = $DB->insert_record("lesson_pages", $newpage)) {
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list
|
// update the linked list
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid))) {
|
$DB->set_field("lesson_pages", "nextpageid", $newpageid, array("id" => $pageid));
|
||||||
print_error('cannotupdateanswer', 'lesson');
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// new page is the first page
|
// new page is the first page
|
||||||
@ -110,21 +106,13 @@ class qformat_default {
|
|||||||
$newpage->prevpageid = 0; // this is a first page
|
$newpage->prevpageid = 0; // this is a first page
|
||||||
$newpage->nextpageid = 0; // this is the only page
|
$newpage->nextpageid = 0; // this is the only page
|
||||||
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
if (!$newpageid) {
|
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// there are existing pages put this at the start
|
// there are existing pages put this at the start
|
||||||
$newpage->prevpageid = 0; // this is a first page
|
$newpage->prevpageid = 0; // this is a first page
|
||||||
$newpage->nextpageid = $page->id;
|
$newpage->nextpageid = $page->id;
|
||||||
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
$newpageid = $DB->insert_record("lesson_pages", $newpage);
|
||||||
if (!$newpageid) {
|
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
// update the linked list
|
// update the linked list
|
||||||
if (!$DB->set_field("lesson_pages", "prevpageid", $newpageid, array("id" => $page->id))) {
|
$DB->set_field("lesson_pages", "prevpageid", $newpageid, array("id" => $page->id));
|
||||||
print_error('cannotupdatelink', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// reset $pageid and put the page ID in $question, used in save_question_option()
|
// reset $pageid and put the page ID in $question, used in save_question_option()
|
||||||
|
@ -116,9 +116,7 @@
|
|||||||
$newhighscore->gradeid = $newgrade->id;
|
$newhighscore->gradeid = $newgrade->id;
|
||||||
$newhighscore->nickname = $name;
|
$newhighscore->nickname = $name;
|
||||||
|
|
||||||
if (!$DB->insert_record('lesson_high_scores', $newhighscore)) {
|
$DB->insert_record('lesson_high_scores', $newhighscore);
|
||||||
print_error('cannotinserthighscore', 'lesson');
|
|
||||||
}
|
|
||||||
|
|
||||||
// Log it
|
// Log it
|
||||||
add_to_log($course->id, 'lesson', 'update highscores', "highscores.php?id=$cm->id", $name, $cm->id);
|
add_to_log($course->id, 'lesson', 'update highscores', "highscores.php?id=$cm->id", $name, $cm->id);
|
||||||
|
@ -543,15 +543,11 @@ function lesson_save_objects($branchtables, $lessonid, $after) {
|
|||||||
$branchtable->page->prevpageid = $prevpageid;
|
$branchtable->page->prevpageid = $prevpageid;
|
||||||
|
|
||||||
// insert the page
|
// insert the page
|
||||||
if(!$id = $DB->insert_record('lesson_pages', $branchtable->page)) {
|
$id = $DB->insert_record('lesson_pages', $branchtable->page);
|
||||||
print_error('cannotinsertpage', 'lesson');
|
|
||||||
}
|
|
||||||
|
|
||||||
// update the link of the page previous to the one we just updated
|
// update the link of the page previous to the one we just updated
|
||||||
if ($prevpageid != 0) { // if not the first page
|
if ($prevpageid != 0) { // if not the first page
|
||||||
if (!$DB->set_field("lesson_pages", "nextpageid", $id, array("id" => $prevpageid))) {
|
$DB->set_field("lesson_pages", "nextpageid", $id, array("id" => $prevpageid));
|
||||||
print_error('cannotupdatepage', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// insert the answers
|
// insert the answers
|
||||||
@ -565,9 +561,7 @@ function lesson_save_objects($branchtables, $lessonid, $after) {
|
|||||||
|
|
||||||
// all done with inserts. Now check to update our last page (this is when we import between two lesson pages)
|
// all done with inserts. Now check to update our last page (this is when we import between two lesson pages)
|
||||||
if ($nextpageid != 0) { // if the next page is not the end of lesson
|
if ($nextpageid != 0) { // if the next page is not the end of lesson
|
||||||
if (!$DB->set_field("lesson_pages", "prevpageid", $id, array("id" => $nextpageid))) {
|
$DB->set_field("lesson_pages", "prevpageid", $id, array("id" => $nextpageid));
|
||||||
print_error('cannotupdatepage', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -581,9 +575,7 @@ function book_save_objects($chapters, $bookid, $pageid='0') {
|
|||||||
|
|
||||||
// nothing fancy, just save them all in order
|
// nothing fancy, just save them all in order
|
||||||
foreach ($chapters as $chapter) {
|
foreach ($chapters as $chapter) {
|
||||||
if (!$chapter->id = $DB->insert_record('book_chapters', $chapter)) {
|
$chapter->id = $DB->insert_record('book_chapters', $chapter);
|
||||||
print_error('cannotupdatebook', 'lesson');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -326,9 +326,7 @@
|
|||||||
$startlesson->starttime = time();
|
$startlesson->starttime = time();
|
||||||
$startlesson->lessontime = time();
|
$startlesson->lessontime = time();
|
||||||
|
|
||||||
if (!$DB->insert_record('lesson_timer', $startlesson)) {
|
$DB->insert_record('lesson_timer', $startlesson);
|
||||||
print_error('cannotinserttimer', 'lesson');
|
|
||||||
}
|
|
||||||
if ($lesson->timed) {
|
if ($lesson->timed) {
|
||||||
lesson_set_message(get_string('maxtimewarning', 'lesson', $lesson->maxtime), 'center');
|
lesson_set_message(get_string('maxtimewarning', 'lesson', $lesson->maxtime), 'center');
|
||||||
}
|
}
|
||||||
|
@ -84,9 +84,7 @@
|
|||||||
$newdata->answer2 = "";
|
$newdata->answer2 = "";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $DB->insert_record("survey_answers", $newdata)) {
|
$DB->insert_record("survey_answers", $newdata);
|
||||||
print_error('cannotinsertanswer', 'survey');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Print the page and finish up.
|
// Print the page and finish up.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user