]> git.mjollnir.org Git - moodle.git/commitdiff
Now groupmode in course_modules is supported too.
authorstronk7 <stronk7>
Thu, 22 Jan 2004 20:27:17 +0000 (20:27 +0000)
committerstronk7 <stronk7>
Thu, 22 Jan 2004 20:27:17 +0000 (20:27 +0000)
backup/backuplib.php
backup/restorelib.php
backup/version.php

index 94bc93b530d4e6ebaba231b639b2a3d0114a4474..cbc99b3625877d5b89c0ca4664cf978d1218b5c5 100644 (file)
                fwrite ($bf,full_tag("SCORE",6,false,$course_module[$tok]->score));
                fwrite ($bf,full_tag("INDENT",6,false,$course_module[$tok]->indent));
                fwrite ($bf,full_tag("VISIBLE",6,false,$course_module[$tok]->visible));
+               fwrite ($bf,full_tag("GROUPMODE",6,false,$course_module[$tok]->groupmode));
                fwrite ($bf,end_tag("MOD",5,true));
             }
            //check for next
index b281da810c271f1602e4b5fcb1e54a70423fda10..affa785e57e6a502f09debbd67d9a6a1ecc6e11c 100644 (file)
                                     $course_module->score = $mod->score;
                                     $course_module->indent = $mod->indent;
                                     $course_module->visible = $mod->visible;
+                                    $course_module->groupmode = $mod->groupmode;
                                     $course_module->instance = null;
                                     //NOTE: The instance (new) is calculated and updated in db in the
                                     //      final step of the restore. We don't know it yet.
                                 $this->info->tempmod->indent;
                             $this->info->tempsection->mods[$this->info->tempmod->id]->visible = 
                                 $this->info->tempmod->visible;
+                            $this->info->tempsection->mods[$this->info->tempmod->id]->groupmode = 
+                                $this->info->tempmod->groupmode;
                             unset($this->info->tempmod);
                     }
                 }
                         case "VISIBLE":
                             $this->info->tempmod->visible = $this->getContents();
                             break;
+                        case "GROUPMODE":
+                            $this->info->tempmod->groupmode = $this->getContents();
+                            break;
                     }
                 }
             }
index 25f8f3e678a508d1a0b08327b32cd62681060f37..1f4b87339b732690f66acdbf12a618dfc54601a5 100644 (file)
@@ -5,6 +5,6 @@
 // database (backup_version) to determine whether upgrades should
 // be performed (see db/backup_*.php)
 
-$backup_version = 2003122900;   // The current version is a date (YYYYMMDDXX)
+$backup_version = 2004012200;   // The current version is a date (YYYYMMDDXX)
 
 $backup_release = "1.2 development";  // User-friendly version number