aboutsummaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorMoritz Strohm <strohm@data-quest.de>2024-09-18 08:33:26 +0000
committerMoritz Strohm <strohm@data-quest.de>2024-09-18 08:33:26 +0000
commitfbf008efa11f009d2b89109e99c213c44c62e024 (patch)
treeee3379b5b28c6ebf4389a3809700b25a4bfa7626 /db
parent1efacbf3fd32325da48d09eabaf4a8d34d4e0de5 (diff)
TIC 4391, closes #4391
Closes #4391 Merge request studip/studip!3211
Diffstat (limited to 'db')
-rw-r--r--db/migrations/6.0.18_remove_course_mapping_by_timestamps.php30
1 files changed, 30 insertions, 0 deletions
diff --git a/db/migrations/6.0.18_remove_course_mapping_by_timestamps.php b/db/migrations/6.0.18_remove_course_mapping_by_timestamps.php
new file mode 100644
index 0000000..015618c
--- /dev/null
+++ b/db/migrations/6.0.18_remove_course_mapping_by_timestamps.php
@@ -0,0 +1,30 @@
+<?php
+
+
+class RemoveCourseMappingByTimestamps extends Migration
+{
+ public function description()
+ {
+ return 'Removes the mapping of courses to semesters by timestamps (by removing seminare.start_time and seminare.duration_time).';
+ }
+
+ public function up()
+ {
+ $db = DBManager::get();
+ $db->exec(
+ "ALTER TABLE `seminare`
+ DROP COLUMN `start_time`,
+ DROP COLUMN `duration_time`"
+ );
+ }
+
+ protected function down()
+ {
+ $db = DBManager::get();
+ $db->exec(
+ "ALTER TABLE `seminare`
+ ADD COLUMN start_time INT(11) UNSIGNED NULL DEFAULT 0,
+ ADD COLUMN duration_time INT(11) NULL DEFAULT NULL"
+ );
+ }
+}