aboutsummaryrefslogtreecommitdiffstats
path: root/db
diff options
context:
space:
mode:
authorAlban Peignier2012-06-07 13:39:35 +0200
committerAlban Peignier2012-06-07 13:39:35 +0200
commit7c0ae629a2ea0079c8b5efbd4c41b6ca661eae91 (patch)
tree26195fe0d4eb8e77a89a9dadaf25626fc3f7fc50 /db
parent1d72c64b77c20d0d3b0bf4b05c40ba99a97493bd (diff)
downloadchouette-core-7c0ae629a2ea0079c8b5efbd4c41b6ca661eae91.tar.bz2
Add support for Exports. Refs #41
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20120607064150_create_exports.rb13
-rw-r--r--db/migrate/20120607064625_create_export_log_messages.rb14
-rw-r--r--db/schema.rb25
3 files changed, 51 insertions, 1 deletions
diff --git a/db/migrate/20120607064150_create_exports.rb b/db/migrate/20120607064150_create_exports.rb
new file mode 100644
index 000000000..6dda4948e
--- /dev/null
+++ b/db/migrate/20120607064150_create_exports.rb
@@ -0,0 +1,13 @@
+class CreateExports < ActiveRecord::Migration
+ def change
+ create_table :exports do |t|
+ t.belongs_to :referential
+ t.string :status
+ t.string :type
+ t.string :options
+
+ t.timestamps
+ end
+ add_index :exports, :referential_id
+ end
+end
diff --git a/db/migrate/20120607064625_create_export_log_messages.rb b/db/migrate/20120607064625_create_export_log_messages.rb
new file mode 100644
index 000000000..e4ad03f98
--- /dev/null
+++ b/db/migrate/20120607064625_create_export_log_messages.rb
@@ -0,0 +1,14 @@
+class CreateExportLogMessages < ActiveRecord::Migration
+ def change
+ create_table :export_log_messages do |t|
+ t.belongs_to :export
+ t.string :key
+ t.string :arguments
+ t.integer :position
+ t.string :severity
+
+ t.timestamps
+ end
+ add_index :export_log_messages, :export_id
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index d4c07cdc1..536cdc7d2 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -10,7 +10,7 @@
#
# It's strongly recommended to check this file into your version control system.
-ActiveRecord::Schema.define(:version => 20120531091529) do
+ActiveRecord::Schema.define(:version => 20120607064625) do
create_table "access_links", :force => true do |t|
t.integer "access_point_id", :limit => 8
@@ -120,6 +120,29 @@ ActiveRecord::Schema.define(:version => 20120531091529) do
add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
+ create_table "export_log_messages", :force => true do |t|
+ t.integer "export_id"
+ t.string "key"
+ t.string "arguments"
+ t.integer "position"
+ t.string "severity"
+ t.datetime "created_at"
+ t.datetime "updated_at"
+ end
+
+ add_index "export_log_messages", ["export_id"], :name => "index_export_log_messages_on_export_id"
+
+ create_table "exports", :force => true do |t|
+ t.integer "referential_id"
+ t.string "status"
+ t.string "type"
+ t.string "options"
+ t.datetime "created_at"
+ t.datetime "updated_at"
+ end
+
+ add_index "exports", ["referential_id"], :name => "index_exports_on_referential_id"
+
create_table "facilities", :force => true do |t|
t.integer "stop_area_id", :limit => 8
t.integer "line_id", :limit => 8