Content blocks - new keys

This commit is contained in:
Ziyan Junaideen
2018-07-26 15:37:22 +05:30
parent a37b64dfb6
commit a6bbf32b8e

View File

@@ -1,5 +1,5 @@
class SiteCustomization::ContentBlock < ActiveRecord::Base
VALID_BLOCKS = %w(top_links footer main_navigation_left main_navigation_right)
VALID_BLOCKS = %w(top_links footer subnavigation_left subnavigation_right)
validates :locale, presence: true, inclusion: { in: I18n.available_locales.map(&:to_s) }
validates :name, presence: true, uniqueness: { scope: :locale }, inclusion: { in: VALID_BLOCKS }