Enable soft deletion of Debate::Translations
This commit is contained in:
committed by
voodoorai2000
parent
03375ae621
commit
096a9f6bb8
@@ -0,0 +1,6 @@
|
||||
class AddHiddenAtToDebateTranslations < ActiveRecord::Migration[4.2]
|
||||
def change
|
||||
add_column :debate_translations, :hidden_at, :datetime
|
||||
add_index :debate_translations, :hidden_at
|
||||
end
|
||||
end
|
||||
@@ -495,7 +495,9 @@ ActiveRecord::Schema.define(version: 20190607160900) do
|
||||
t.datetime "updated_at", null: false
|
||||
t.string "title"
|
||||
t.text "description"
|
||||
t.datetime "hidden_at"
|
||||
t.index ["debate_id"], name: "index_debate_translations_on_debate_id", using: :btree
|
||||
t.index ["hidden_at"], name: "index_debate_translations_on_hidden_at", using: :btree
|
||||
t.index ["locale"], name: "index_debate_translations_on_locale", using: :btree
|
||||
end
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@ describe Debate do
|
||||
it_behaves_like "has_public_author"
|
||||
it_behaves_like "notifiable"
|
||||
it_behaves_like "sanitizable"
|
||||
it_behaves_like "acts as paranoid", :debate
|
||||
end
|
||||
|
||||
it "is valid" do
|
||||
|
||||
Reference in New Issue
Block a user