diff options
| author | Zog | 2017-12-27 13:42:39 +0100 |
|---|---|---|
| committer | Zog | 2017-12-27 13:42:39 +0100 |
| commit | 607fa5e03289a10b60a773bc40af38f1d721bbea (patch) | |
| tree | b27f8e9825e79675c606571ff7efb9953b8a4917 /db/migrate | |
| parent | 78e2d256f895c1014a3def5f2ef6509086755215 (diff) | |
| download | chouette-core-607fa5e03289a10b60a773bc40af38f1d721bbea.tar.bz2 | |
Refs #5407 @2h; Model implementation
- Link PurchaseWindows to VehicleJourneys in the model
- Add an autocompletion endpoint
Diffstat (limited to 'db/migrate')
| -rw-r--r-- | db/migrate/20171227113809_create_join_table_purchase_windows_vehicle_journeys.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/db/migrate/20171227113809_create_join_table_purchase_windows_vehicle_journeys.rb b/db/migrate/20171227113809_create_join_table_purchase_windows_vehicle_journeys.rb new file mode 100644 index 000000000..822fcc33a --- /dev/null +++ b/db/migrate/20171227113809_create_join_table_purchase_windows_vehicle_journeys.rb @@ -0,0 +1,10 @@ +class CreateJoinTablePurchaseWindowsVehicleJourneys < ActiveRecord::Migration + def change + create_join_table :purchase_windows, :vehicle_journeys do |t| + t.belongs_to :purchase_window + t.belongs_to :vehicle_journey + # t.index [:purchase_window_id, :vehicle_journey_id] + # t.index [:vehicle_journey_id, :purchase_window_id] + end + end +end |
