Sha256: 5da32fb36f4f3e9af8506dac5bd885ef052c7b5c10e440fed7ac0f220e285ef4

Contents?: true

Size: 894 Bytes

Versions: 2

Compression:

Stored size: 894 Bytes

Contents

%p= t('.title', :name => @account.name, :date => I18n.l(Time.now), :locale => @account.locale)

%hr

%p
  %b= t('.type', :type => @type.name, :locale => @account.locale)
  %br
  %i= @type.description

%hr

%ul
  - @type.ordered_entries_custom_fields.each do |field|
    - value = @entry.send(field.name)
    %li
      %strong= field.label
       - 
      %i
        - case field.type.to_s
        - when 'string', 'text', 'boolean', 'date'
          = value
        - when 'file'
          - url = value.guess_url
          - url = url =~ /^http/ ? url : URI.join("http://#{@entry.site.domains.first}", url).to_s # Amazon S3 (http/https) or local files ?
          = link_to File.basename(url), url
        - when 'select'
          = value
        - when 'belongs_to'
          = value.try(:_label)
        - when 'has_many', 'many_to_many'
          = value.map(&:_label).join(', ')

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
locomotive_cms-2.0.0.rc11 app/views/locomotive/notifications/new_content_entry.html.haml
locomotive_cms-2.0.0.rc10 app/views/locomotive/notifications/new_content_entry.html.haml