Skip to content

Commit

Permalink
Remove timestamps from essence and contents tables
Browse files Browse the repository at this point in the history
These records always ever get created within an element.
So, this information is duplicated.
  • Loading branch information
tvdeyen committed May 5, 2020
1 parent bfc8717 commit b5f534f
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 44 deletions.
22 changes: 0 additions & 22 deletions db/migrate/20200226213334_alchemy_four_point_four.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ def up
t.string "name"
t.references "essence", null: false, polymorphic: true, index: { unique: true }
t.references "element", null: false
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

Expand Down Expand Up @@ -57,17 +55,13 @@ def up
unless table_exists?("alchemy_essence_booleans")
create_table "alchemy_essence_booleans", force: :cascade do |t|
t.boolean "value"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.index ["value"], name: "index_alchemy_essence_booleans_on_value"
end
end

unless table_exists?("alchemy_essence_dates")
create_table "alchemy_essence_dates", force: :cascade do |t|
t.datetime "date"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

Expand All @@ -76,17 +70,13 @@ def up
t.references "attachment"
t.string "title"
t.string "css_class"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.string "link_text"
end
end

unless table_exists?("alchemy_essence_htmls")
create_table "alchemy_essence_htmls", force: :cascade do |t|
t.text "source"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

Expand All @@ -96,16 +86,12 @@ def up
t.string "link_title"
t.string "link_target"
t.string "link_class_name"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

unless table_exists?("alchemy_essence_pages")
create_table "alchemy_essence_pages", force: :cascade do |t|
t.references "page"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
end

Expand All @@ -120,8 +106,6 @@ def up
t.string "link_title"
t.string "css_class"
t.string "link_target"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.string "crop_from"
t.string "crop_size"
t.string "render_size"
Expand All @@ -133,16 +117,12 @@ def up
t.text "body"
t.text "stripped_body"
t.boolean "public"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

unless table_exists?("alchemy_essence_selects")
create_table "alchemy_essence_selects", force: :cascade do |t|
t.string "value"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.index ["value"], name: "index_alchemy_essence_selects_on_value"
end
end
Expand All @@ -155,8 +135,6 @@ def up
t.string "link_class_name"
t.boolean "public", default: false
t.string "link_target"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end
end

Expand Down
22 changes: 0 additions & 22 deletions spec/dummy/db/schema.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@
t.string "essence_type", null: false
t.integer "essence_id", null: false
t.integer "element_id", null: false
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.index ["element_id"], name: "index_alchemy_contents_on_element_id"
t.index ["essence_type", "essence_id"], name: "index_alchemy_contents_on_essence_type_and_essence_id", unique: true
end
Expand Down Expand Up @@ -67,40 +65,30 @@

create_table "alchemy_essence_booleans", force: :cascade do |t|
t.boolean "value"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.index ["value"], name: "index_alchemy_essence_booleans_on_value"
end

create_table "alchemy_essence_dates", force: :cascade do |t|
t.datetime "date"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end

create_table "alchemy_essence_files", force: :cascade do |t|
t.integer "attachment_id"
t.string "title"
t.string "css_class"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.string "link_text"
t.index ["attachment_id"], name: "index_alchemy_essence_files_on_attachment_id"
end

create_table "alchemy_essence_htmls", force: :cascade do |t|
t.text "source"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end

create_table "alchemy_essence_links", force: :cascade do |t|
t.string "link"
t.string "link_title"
t.string "link_target"
t.string "link_class_name"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end

create_table "alchemy_essence_nodes", force: :cascade do |t|
Expand All @@ -112,8 +100,6 @@

create_table "alchemy_essence_pages", force: :cascade do |t|
t.integer "page_id"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["page_id"], name: "index_alchemy_essence_pages_on_page_id"
end

Expand All @@ -127,8 +113,6 @@
t.string "link_title"
t.string "css_class"
t.string "link_target"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.string "crop_from"
t.string "crop_size"
t.string "render_size"
Expand All @@ -139,14 +123,10 @@
t.text "body"
t.text "stripped_body"
t.boolean "public"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end

create_table "alchemy_essence_selects", force: :cascade do |t|
t.string "value"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
t.index ["value"], name: "index_alchemy_essence_selects_on_value"
end

Expand All @@ -157,8 +137,6 @@
t.string "link_class_name"
t.boolean "public", default: false
t.string "link_target"
t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false
end

create_table "alchemy_folded_pages", force: :cascade do |t|
Expand Down

0 comments on commit b5f534f

Please sign in to comment.