merge translated tags branch

This commit is contained in:
Toks
2014-05-29 23:11:34 -04:00
15 changed files with 109 additions and 7 deletions

View File

@@ -0,0 +1,10 @@
class AddOtherNamesToWikiPages < ActiveRecord::Migration
def change
add_column :wiki_pages, :other_names, :text
add_column :wiki_pages, :other_names_index, :tsvector
add_column :wiki_page_versions, :other_names, :text
execute "CREATE INDEX index_wiki_pages_on_other_names_index ON wiki_pages USING GIN (other_names_index)"
execute "CREATE TRIGGER trigger_wiki_pages_on_update_for_other_names BEFORE INSERT OR UPDATE ON wiki_pages FOR EACH ROW EXECUTE PROCEDURE tsvector_update_trigger('other_names_index', 'public.danbooru', 'other_names')"
end
end