diff --git a/db/migrate/20220324131233_groupdate.rb b/db/migrate/20220324131233_groupdate.rb index 60c9c9b..43ca743 100644 --- a/db/migrate/20220324131233_groupdate.rb +++ b/db/migrate/20220324131233_groupdate.rb @@ -3,12 +3,12 @@ # Instala las funciones de agrupamiento por fecha class Groupdate < ActiveRecord::Migration[6.1] def up - groupdate = File.read(Rails.root.join('db', 'groupdate', 'postgresql', 'install.sql')).sub(/(BEGIN|COMMIT);/, '' + groupdate = File.read(Rails.root.join('db', 'groupdate', 'postgresql', 'install.sql')).sub(/(BEGIN|COMMIT);/, '') ActiveRecord::Base.connection.execute(groupdate) end def down - groupdate = File.read(Rails.root.join('db', 'groupdate', 'postgresql', 'uninstall.sql')).sub(/(BEGIN|COMMIT);/, '' + groupdate = File.read(Rails.root.join('db', 'groupdate', 'postgresql', 'uninstall.sql')).sub(/(BEGIN|COMMIT);/, '') ActiveRecord::Base.connection.execute(groupdate) end end