Fix #3324: Incorporate replacement comment info in the replacement history.

This commit is contained in:
evazion
2017-12-18 17:10:55 -06:00
parent fb6d692c37
commit eede2f0752
4 changed files with 65 additions and 5 deletions

View File

@@ -0,0 +1,17 @@
class AddMetadataToPostReplacements < ActiveRecord::Migration
def change
PostReplacement.without_timeout do
add_column :post_replacements, :file_ext_was, :string
add_column :post_replacements, :file_size_was, :integer
add_column :post_replacements, :image_width_was, :integer
add_column :post_replacements, :image_height_was, :integer
add_column :post_replacements, :md5_was, :string
add_column :post_replacements, :file_ext, :string
add_column :post_replacements, :file_size, :integer
add_column :post_replacements, :image_width, :integer
add_column :post_replacements, :image_height, :integer
add_column :post_replacements, :md5, :string
end
end
end

View File

@@ -2666,7 +2666,17 @@ CREATE TABLE post_replacements (
original_url text NOT NULL,
replacement_url text NOT NULL,
created_at timestamp without time zone NOT NULL,
updated_at timestamp without time zone NOT NULL
updated_at timestamp without time zone NOT NULL,
file_ext_was character varying,
file_size_was integer,
image_width_was integer,
image_height_was integer,
md5_was character varying,
file_ext character varying,
file_size integer,
image_width integer,
image_height integer,
md5 character varying
);
@@ -7530,3 +7540,5 @@ INSERT INTO schema_migrations (version) VALUES ('20171106075030');
INSERT INTO schema_migrations (version) VALUES ('20171127195124');
INSERT INTO schema_migrations (version) VALUES ('20171218213037');