Sha256: 2db0afc3f0a89c785e02455050de07766674e01160371f79d4422f863d169c4c
Contents?: true
Size: 952 Bytes
Versions: 9
Compression:
Stored size: 952 Bytes
Contents
module Admin module Form module Email extend ActiveSupport::Concern included do rails_admin do visible false object_label_method do :rails_admin_label end edit do toolbar = Rich.editor[:toolbar].deep_dup toolbar.delete_at(-2) if RailsAdminCMS::Config.with_email_body? I18n.available_locales.each do |locale| configure :"body_#{locale}", :rich_editor do config(toolbar: toolbar) end end exclude_fields :structure else exclude_fields :structure, *I18n.available_locales.map{ |l| :"body_#{l}" } end end end end def rails_admin_label if with_email? '<i class="icon-ok"></i>' else '<i>-</i>' end.html_safe end end end end
Version data entries
9 entries across 9 versions & 1 rubygems