Make Widget::Card translatable

This commit is contained in:
Javi Martín
2018-09-26 15:55:36 +02:00
parent 2c22ab347d
commit 5bb5cfa7fb
7 changed files with 72 additions and 19 deletions

View File

@@ -0,0 +1,16 @@
class AddHomepageContentTranslations < ActiveRecord::Migration
def self.up
Widget::Card.create_translation_table!(
label: :string,
title: :string,
description: :text,
link_text: :string
)
end
def self.down
Widget::Card.drop_translation_table!
end
end