Sha256: 4915918e2e61947bbc1198ba7acd3f30d3c59eb99b4b91c3553b7519f7c28f0b
Contents?: true
Size: 980 Bytes
Versions: 1
Compression:
Stored size: 980 Bytes
Contents
- if @object.type == 'string' || @object.type == 'integer' = form.text_field :raw, :value => field.value - elsif @object.type == 'text' || @object.type == 'yaml' = form.text_area :raw, :value => field.value, :rows => 10, :cols => 80 - elsif @object.type == 'html' - if form.respond_to?(:cktext_area) = javascript_include_tag "ckeditor/init" = form.cktext_area :raw, :value => field.value, :rows => 10, :cols => 80 - elsif Object.const_defined?('Rich') = form.text_area :raw, :value => field.value, :rows => 10, :cols => 80 = javascript_include_tag "rich/base.js" javascript: var instance = CKEDITOR.instances['#{form.dom_id(field)}']; if(instance) { CKEDITOR.remove(instance); } CKEDITOR.replace('#{form.dom_id(field)}', #{Rich.options().to_json.html_safe}); - else .alert.alert-error = t('admin.settings.no_ckeditor_detected') = form.text_area :raw, :value => field.value, :rows => 10, :cols => 80
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rails_admin_settings-0.1.0 | app/views/rails_admin/main/_setting_value.html.haml |