]> git.mjollnir.org Git - moodle.git/commitdiff
Now assignment submodules are handled by the XMLDB editor. Pending commit.
authorstronk7 <stronk7>
Wed, 19 Sep 2007 08:04:11 +0000 (08:04 +0000)
committerstronk7 <stronk7>
Wed, 19 Sep 2007 08:04:11 +0000 (08:04 +0000)
admin/xmldb/actions/get_db_directories/get_db_directories.class.php

index 83b64a92dcb7248710f38960ddc751d2f560fe84..04a6cabce5357246e29b11bef84c17affe425ccf 100644 (file)
@@ -90,6 +90,18 @@ class get_db_directories extends XMLDBAction {
             }
         }
 
+    /// Now, assignment submodules (mod/assignment/type/xxx/db)
+        if ($plugins = get_list_of_plugins('mod/assignment/type')) {
+            foreach ($plugins as $plugin) {
+                $dbdir = new stdClass;
+                $dbdir->path = $CFG->dirroot . '/mod/assignment/type/' . $plugin . '/db';
+                if (!isset($XMLDB->dbdirs[$dbdir->path])) {
+                    $XMLDB->dbdirs[$dbdir->path] = $dbdir;
+                }
+                $XMLDB->dbdirs[$dbdir->path]->path_exists = file_exists($dbdir->path);  //Update status
+            }
+        }
+
     /// Now, question types (question/type/xxx/db)
         if ($plugins = get_list_of_plugins('question/type')) {
             foreach ($plugins as $plugin) {