Sha256: 599ff794f45bcbe462a1318ad9033781c8e7734ee8ff84e2c1abceb6b14e9fd4

Contents?: true

Size: 1.34 KB

Versions: 1

Compression:

Stored size: 1.34 KB

Contents

%a#back-to-all{:href => rails_email_preview.root_url} « Back to list
:ruby
  raw_url  = rails_email_preview.email_url(params.merge(:part_type => 'raw'))
  html_url = if @mail.multipart? || @mail.content_type =~ %r(text/html)
   rails_email_preview.email_url(params.merge(:part_type => 'text/html'))
  end
  plain_url = if @mail.multipart? || @mail.content_type =~ %r(text/plain) || Object.const_defined?('PremailerRails')
   rails_email_preview.email_url(params.merge(:part_type => 'text/plain'))
  end

#message_headers
  %p.alternate
    - if @part_type != 'raw'
      %a{:href => raw_url} View Original Message (raw)
      %br
    - if @part_type != 'text/html' && html_url
      %a{:href => html_url} View HTML version
      %br
    - if @part_type != 'text/plain' && plain_url
      %a{:href => plain_url} View plain text version
  %dl
    %dt From:
    %dd= @mail.from

    %dt Subject:
    %dd
      %strong= @mail.subject

    %dt Date:
    %dd= Time.now.strftime("%b %e, %Y %I:%M:%S %p %Z")

    %dt To:
    %dd= @mail.to

%iframe#src-iframe{:src => rails_email_preview.raw_email_url(params.slice(:mail_class, :mail_action, :part_type)),
  :width => "100%", :height => "800", :onload => "document.getElementById('src-iframe').style.display = 'block';document.getElementById('loading').style.display = 'none'", :style => "display:none"}
%pre#loading Loading...

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rails_email_preview-0.0.5 app/views/rails_email_preview/emails/show.html.haml