engine/app/views/locomotive/notifications/new_content_entry.html.haml

29 lines
733 B
Plaintext

%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'
= link_to File.basename(value.to_s), value.to_s
- when 'select'
= value
- when 'belongs_to'
= value.try(:_label)
- when 'has_many', 'many_to_many'
= value.map(&:_label).join(', ')