Parcourir la source

Added migrations to generator

Andrew Kane il y a 9 ans
Parent
commit
78284b6502
1 fichiers modifiés avec 12 ajouts et 0 suppressions
  1. 12 0
      lib/generators/blazer/templates/install.rb

+ 12 - 0
lib/generators/blazer/templates/install.rb

@@ -21,5 +21,17 @@ class <%= migration_class_name %> < ActiveRecord::Migration
       t.text :emails
       t.timestamps
     end
+
+    create_table :blazer_dashboards do |t|
+      t.text :name
+      t.timestamps
+    end
+
+    create_table :blazer_dashboard_queries do |t|
+      t.references :blazer_dashboard
+      t.references :blazer_query
+      t.integer :position
+      t.timestamps
+    end
   end
 end