From 4ee768d80cc5374c84ed0b06a43eb4f4bda0f825 Mon Sep 17 00:00:00 2001 From: cedricnjanga Date: Fri, 24 Nov 2017 12:32:09 +0100 Subject: Take into account code review --- ...20171123110204_update_objectid_format_value_to_referentials.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'db') diff --git a/db/migrate/20171123110204_update_objectid_format_value_to_referentials.rb b/db/migrate/20171123110204_update_objectid_format_value_to_referentials.rb index bd498a0ff..c85a63b6e 100644 --- a/db/migrate/20171123110204_update_objectid_format_value_to_referentials.rb +++ b/db/migrate/20171123110204_update_objectid_format_value_to_referentials.rb @@ -1,8 +1,14 @@ class UpdateObjectidFormatValueToReferentials < ActiveRecord::Migration - def change + # Migration in the context of the STIF + # Not a definitive choice since it cannot be used for Chouette + def up Workbench.update_all(objectid_format: 'stif_netex') Referential.update_all(objectid_format: 'stif_netex') LineReferential.update_all(objectid_format: 'stif_codifligne') StopAreaReferential.update_all(objectid_format: 'stif_reflex') end + + def down + raise ActiveRecord::IrreversibleMigration + end end -- cgit v1.2.3