]> git.mjollnir.org Git - moodle.git/commitdiff
fix for category.php lists. Slight change in listlib api caused breakage.
authorjamiesensei <jamiesensei>
Fri, 25 May 2007 04:59:17 +0000 (04:59 +0000)
committerjamiesensei <jamiesensei>
Fri, 25 May 2007 04:59:17 +0000 (04:59 +0000)
lib/listlib.php
question/category_class.php

index d3c89db6b420452010f8b7cdbe02cf2d7b50157c..75c266d2bdc150d79b8c25095c312dfbbef6e468 100644 (file)
@@ -210,7 +210,7 @@ class moodle_list{
      * @return integer $offset + how many toplevel items where there in this list.
      * 
      */
-    function list_from_records($paged = false, $offset =0){
+    function list_from_records($paged = false, $offset =1){
         $this->paged = $paged;
         $this->offset = $offset;
         $this->get_records();
index 6ab93bb3158c011156ffdf0af9a1a90f5b018d86..772d3c27e62c09e7886a85c25f6e3f97da00755c 100644 (file)
@@ -138,7 +138,7 @@ class question_category_object {
         $this->str->page           = get_string('page');
         $this->pixpath = $CFG->pixpath;
 
-        $this->editlist = new question_category_list('ul', '', true, $page, $pageurl, 'cpage');
+        $this->editlist = new question_category_list('ul', '', true, $pageurl, $page, 'cpage', QUESTION_PAGE_LENGTH);
 
         $this->pageurl = $pageurl;
         
@@ -177,7 +177,7 @@ class question_category_object {
             error("Error: Could not find or make a category!");
         }
 
-        $this->editlist->list_from_records(QUESTION_PAGE_LENGTH);
+        $this->editlist->list_from_records();
 
         $this->categories = $this->editlist->records;