restructure email templates
This commit is contained in:
parent
f04cbcaad7
commit
4b6f059021
6 changed files with 25 additions and 41 deletions
|
@ -1,6 +1,10 @@
|
|||
<!DOCTYPE html>
|
||||
<% mail = ApplicationMailer.mail_for_notification(@notification) %>
|
||||
<% if mail %>
|
||||
<% @notification.update(body: mail.html_part&.body&.decoded) %>
|
||||
<%= raw mail.html_part&.body&.decoded %>
|
||||
<% end %>
|
||||
<div style="padding: 16px; background: white; text-align: left;">
|
||||
<% if mail %>
|
||||
<% @notification.update(body: mail.html_part&.body&.decoded) %>
|
||||
<%= raw mail.html_part&.body&.decoded %>
|
||||
<% end %>
|
||||
<p style="font-size: 12px;">Make sense with Metamaps</p>
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
</div>
|
||||
|
|
|
@ -2,3 +2,7 @@
|
|||
<% if mail %>
|
||||
<%= mail.text_part&.body&.decoded %>
|
||||
<% end %>
|
||||
|
||||
Make sense with Metamaps
|
||||
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
|
|
|
@ -1,16 +1,6 @@
|
|||
<div style="padding: 16px; background: white; text-align: left;">
|
||||
<% button_style = "background-color:#4fc059;border-radius:2px;color:white;display:inline-block;font-family:Roboto,Arial,Helvetica,sans-serif;font-size:12px;font-weight:bold;min-height:29px;line-height:29px;min-width:54px;outline:0px;padding:0 8px;text-align:center;text-decoration:none" %>
|
||||
|
||||
<p><span style="font-weight: bold;"><%= @request.user.name %></span> is requesting access to <span style="font-weight: bold">collaboratively edit</span> the following map:</p>
|
||||
|
||||
<p><%= @map.name %></p>
|
||||
|
||||
<p><%= link_to "Allow", approve_access_map_url(id: @map.id, request_id: @request.id), style: "font-size: 18px; text-decoration: none; color: #4fc059;" %>
|
||||
<p><%= link_to "Decline", deny_access_map_url(id: @map.id, request_id: @request.id), style: "font-size: 18px; text-decoration: none; color: #DB5D5D;" %></p>
|
||||
|
||||
<%= link_to 'Open in Metamaps', map_url(@map), style: button_style %>
|
||||
|
||||
<p style="font-size: 12px;">Make sense with Metamaps</p>
|
||||
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
</div>
|
||||
<% button_style = "background-color:#4fc059;border-radius:2px;color:white;display:inline-block;font-family:Roboto,Arial,Helvetica,sans-serif;font-size:12px;font-weight:bold;min-height:29px;line-height:29px;min-width:54px;outline:0px;padding:0 8px;text-align:center;text-decoration:none" %>
|
||||
<p><span style="font-weight: bold;"><%= @request.user.name %></span> is requesting access to <span style="font-weight: bold">collaboratively edit</span> the following map:</p>
|
||||
<p><%= @map.name %></p>
|
||||
<p><%= link_to "Allow", approve_access_map_url(id: @map.id, request_id: @request.id), style: "font-size: 18px; text-decoration: none; color: #4fc059;" %>
|
||||
<p><%= link_to "Decline", deny_access_map_url(id: @map.id, request_id: @request.id), style: "font-size: 18px; text-decoration: none; color: #DB5D5D;" %></p>
|
||||
<%= link_to 'Go to Map', map_url(@map), style: button_style %>
|
||||
|
|
|
@ -5,6 +5,4 @@
|
|||
Allow [<%= approve_access_map_url(id: @map.id, request_id: @request.id) %>]
|
||||
Decline [<%= deny_access_map_url(id: @map.id, request_id: @request.id) %>]
|
||||
|
||||
Make sense with Metamaps
|
||||
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
|
|
|
@ -1,15 +1,7 @@
|
|||
<div style="padding: 16px; background: white; text-align: left;">
|
||||
<% button_style = "background-color:#4fc059;border-radius:2px;color:white;display:inline-block;font-family:Roboto,Arial,Helvetica,sans-serif;font-size:12px;font-weight:bold;min-height:29px;line-height:29px;min-width:54px;outline:0px;padding:0 8px;text-align:center;text-decoration:none" %>
|
||||
|
||||
<p><span style="font-weight: bold;"><%= @inviter.name %></span> has invited you to <span style="font-weight: bold">collaboratively edit</span> the following map:</p>
|
||||
<p><%= link_to @map.name, map_url(@map), style: "font-size: 18px; text-decoration: none; color: #4fc059;" %></p>
|
||||
<% if @map.desc %>
|
||||
<p style="font-size: 12px;"><%= @map.desc %></p>
|
||||
<% end %>
|
||||
|
||||
<%= link_to 'Open in Metamaps', map_url(@map), style: button_style %>
|
||||
|
||||
<p style="font-size: 12px;">Make sense with Metamaps</p>
|
||||
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
</div>
|
||||
<% button_style = "background-color:#4fc059;border-radius:2px;color:white;display:inline-block;font-family:Roboto,Arial,Helvetica,sans-serif;font-size:12px;font-weight:bold;min-height:29px;line-height:29px;min-width:54px;outline:0px;padding:0 8px;text-align:center;text-decoration:none" %>
|
||||
<p><span style="font-weight: bold;"><%= @inviter.name %></span> has invited you to <span style="font-weight: bold">collaboratively edit</span> the following map:</p>
|
||||
<p><%= link_to @map.name, map_url(@map), style: "font-size: 18px; text-decoration: none; color: #4fc059;" %></p>
|
||||
<% if @map.desc %>
|
||||
<p style="font-size: 12px;"><%= @map.desc %></p>
|
||||
<% end %>
|
||||
<%= link_to 'Go to Map', map_url(@map), style: button_style %>
|
||||
|
|
|
@ -1,7 +1,3 @@
|
|||
<%= @inviter.name %> has invited you to collaboratively edit the following map:
|
||||
|
||||
<%= @map.name %> [<%= map_url(@map) %>]
|
||||
|
||||
Make sense with Metamaps
|
||||
|
||||
<%= render partial: 'shared/mailer_unsubscribe_link' %>
|
||||
|
|
Loading…
Reference in a new issue