From: tjhunt Date: Mon, 12 May 2008 15:59:05 +0000 (+0000) Subject: MDL-10899 - followup - need to move random questions too. X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=e4cdf3fb2c1504a93917846bf0c3f08469b0c076;p=moodle.git MDL-10899 - followup - need to move random questions too. --- diff --git a/question/category_class.php b/question/category_class.php index 80c5fe16fd..0469f2e5b2 100644 --- a/question/category_class.php +++ b/question/category_class.php @@ -352,7 +352,7 @@ class question_category_object { } function move_questions($oldcat, $newcat){ - $questionids = get_records_select_menu('question', "category = $oldcat AND parent = 0", '', 'id,1'); + $questionids = get_records_select_menu('question', "category = $oldcat AND (parent = 0 OR parent = id)", '', 'id,1'); if (!question_move_questions_to_category(implode(',', array_keys($questionids)), $newcat)) { print_error('errormovingquestions', 'question', $returnurl, $ids); }