forked from pboling/capistrano_mailer
/
notification_email.text.html.erb
39 lines (33 loc) · 1.59 KB
/
notification_email.text.html.erb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title><%= @site_name %> Notification </title>
</head>
<body style="font: 14px normal Helvetica, Arial, Sans; background: #999;">
<div style="width:800px; margin: 10px auto; background: #fff; border: 10px solid #aaa;">
<h1 style="clear: both; margin: 0; padding: 40px 20px 5px 20px; border-bottom: 1px dotted; background: #ccc;">
<%= @site_name %> <%=@task_name.titleize unless @task_name.nil? %>
</h1>
<% unless @site_url.nil? %>
<p style="margin: 8px 0 20px 20px; padding: 0px; font-style: italic;" >
View site: <a href="<%= @site_url -%>"><%= @site_url -%></a>
</p>
<% end %>
<p style="margin: 10px 20px; font-weight: bold;">Released: <%= @date %> at <%= @time %></p>
<%= @sections.map { |section|
data = @section_data[section.to_sym]
if !data.empty?
if %w(extra_information release_data).include?(section)
render :partial => 'section_custom.html.erb', :locals => {:section_title => section, :data => data}
else
render :partial => 'section.html.erb', :locals => {:section_title => section, :data => data}
end
end
}.join unless @sections.nil? %>
</div>
<p style="margin: 8px 0 20px 20px; padding: 0px; font-style: italic;" >
Brought to you by: <a href="http://github.com/textgoeshere/capistrano_mailer">Capistrano Mailer</a>
</p>
</body>
</html>