From a36e8ea2bf092a23530b0ad54504667caa94e788 Mon Sep 17 00:00:00 2001 From: spag Date: Thu, 17 Jan 2013 15:43:15 +0100 Subject: set match action in prerouting table --- db/migrate/20130117142600_change_action_prerouting_table.rb | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 db/migrate/20130117142600_change_action_prerouting_table.rb diff --git a/db/migrate/20130117142600_change_action_prerouting_table.rb b/db/migrate/20130117142600_change_action_prerouting_table.rb new file mode 100644 index 0000000..8b57ca6 --- /dev/null +++ b/db/migrate/20130117142600_change_action_prerouting_table.rb @@ -0,0 +1,13 @@ +class ChangeActionPreroutingTable < ActiveRecord::Migration + def up + RouteElement.where(:action => 'set_route_var', :mandatory => true).each do |route| + route.update_attributes(:action => 'match') + end + end + + def down + RouteElement.where(:action => 'match', :mandatory => true).each do |route| + route.update_attributes(:action => 'set_route_var') + end + end +end -- cgit v1.2.3