diff --git a/db/migrate/20160223073859_add_publish_to_attachment_histories.rb b/db/migrate/20160223073859_add_publish_to_attachment_histories.rb new file mode 100644 index 000000000..81533004f --- /dev/null +++ b/db/migrate/20160223073859_add_publish_to_attachment_histories.rb @@ -0,0 +1,6 @@ +class AddPublishToAttachmentHistories < ActiveRecord::Migration + def change + add_column :attachment_histories, :is_publish, :integer, :default => 1 + add_column :attachment_histories, :publish_time, :date + end +end diff --git a/db/schema.rb b/db/schema.rb index c22b79790..db33479a5 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended to check this file into your version control system. -ActiveRecord::Schema.define(:version => 20160220100507) do +ActiveRecord::Schema.define(:version => 20160223073859) do create_table "activities", :force => true do |t| t.integer "act_id", :null => false @@ -99,6 +99,8 @@ ActiveRecord::Schema.define(:version => 20160220100507) do t.integer "quotes" t.integer "version" t.integer "attachment_id" + t.integer "is_publish", :default => 1 + t.date "publish_time" end create_table "attachments", :force => true do |t| @@ -118,6 +120,8 @@ ActiveRecord::Schema.define(:version => 20160220100507) do t.integer "is_public", :default => 1 t.integer "copy_from" t.integer "quotes" + t.integer "is_publish", :default => 1 + t.date "publish_time" end add_index "attachments", ["author_id"], :name => "index_attachments_on_author_id" @@ -1373,7 +1377,6 @@ ActiveRecord::Schema.define(:version => 20160220100507) do t.integer "changeset_num", :default => 0 t.integer "board_message_num", :default => 0 t.integer "board_num", :default => 0 - t.integer "act_num", :default => 0 t.integer "attach_num", :default => 0 t.datetime "commit_time" end