From 42721e95726559b4a601240bb5b0fe4e5d755b2a Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Wed, 27 Nov 2019 23:43:21 +0100 Subject: Added Schedule parsing and replaced old Fahrplan importer Resolves #553 (Change Frab Import from xCal to XML) Resolves #538 (Feature Request: Multi Frab Import) --- ...7_000000_migrate_admin_schedule_permissions.php | 48 ++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 db/migrations/2019_09_07_000000_migrate_admin_schedule_permissions.php (limited to 'db/migrations/2019_09_07_000000_migrate_admin_schedule_permissions.php') diff --git a/db/migrations/2019_09_07_000000_migrate_admin_schedule_permissions.php b/db/migrations/2019_09_07_000000_migrate_admin_schedule_permissions.php new file mode 100644 index 00000000..e39e22d8 --- /dev/null +++ b/db/migrations/2019_09_07_000000_migrate_admin_schedule_permissions.php @@ -0,0 +1,48 @@ +schema->hasTable('Privileges')) { + return; + } + + $this->schema->getConnection() + ->table('Privileges') + ->where('name', 'admin_import') + ->update( + [ + 'name' => 'schedule.import', + 'desc' => 'Import rooms and shifts from schedule.xml', + ] + ); + } + + /** + * Reverse the migration + */ + public function down() + { + if (!$this->schema->hasTable('Privileges')) { + return; + } + + $this->schema->getConnection() + ->table('Privileges') + ->where('name', 'schedule.import') + ->update( + [ + 'name' => 'admin_import', + 'desc' => 'Import rooms and shifts from schedule.xcs/schedule.xcal', + ] + ); + } +} -- cgit v1.2.3-54-g00ecf