Rails Email Config
This commit is contained in:
parent
225f402c0f
commit
b16b1929b4
4
Gemfile
4
Gemfile
@ -19,6 +19,10 @@ gem 'uglifier', '>= 1.3.0'
|
||||
gem 'bourbon'
|
||||
gem 'neat'
|
||||
|
||||
# Foundation for Emails
|
||||
gem 'inky-rb', require: 'inky'
|
||||
gem 'premailer-rails'
|
||||
|
||||
group :development do
|
||||
gem 'better_errors'
|
||||
gem 'rack-livereload'
|
||||
|
15
Gemfile.lock
15
Gemfile.lock
@ -38,6 +38,7 @@ GEM
|
||||
i18n (~> 0.7)
|
||||
minitest (~> 5.1)
|
||||
tzinfo (~> 1.1)
|
||||
addressable (2.4.0)
|
||||
ansi (1.5.0)
|
||||
arel (7.1.0)
|
||||
ast (2.3.0)
|
||||
@ -57,6 +58,8 @@ GEM
|
||||
choice (0.2.0)
|
||||
coderay (1.1.1)
|
||||
concurrent-ruby (1.0.2)
|
||||
css_parser (1.4.5)
|
||||
addressable
|
||||
debug_inspector (0.0.2)
|
||||
docile (1.1.5)
|
||||
domain_name (0.5.20160615)
|
||||
@ -71,6 +74,7 @@ GEM
|
||||
figaro (1.1.1)
|
||||
thor (~> 0.14)
|
||||
formatador (0.2.5)
|
||||
foundation_emails (2.2.0.0)
|
||||
globalid (0.3.6)
|
||||
activesupport (>= 4.1.0)
|
||||
guard (2.14.0)
|
||||
@ -97,10 +101,13 @@ GEM
|
||||
guard-shell (0.7.1)
|
||||
guard (>= 2.0.0)
|
||||
guard-compat (~> 1.0)
|
||||
htmlentities (4.3.4)
|
||||
http-cookie (1.0.2)
|
||||
domain_name (~> 0.5)
|
||||
http_parser.rb (0.6.0)
|
||||
i18n (0.7.0)
|
||||
inky-rb (1.3.6.1)
|
||||
foundation_emails (~> 2)
|
||||
jbuilder (2.6.0)
|
||||
activesupport (>= 3.0.0, < 5.1)
|
||||
multi_json (~> 1.2)
|
||||
@ -151,6 +158,12 @@ GEM
|
||||
ast (~> 2.2)
|
||||
pkg-config (1.1.7)
|
||||
powerpack (0.1.1)
|
||||
premailer (1.8.7)
|
||||
css_parser (>= 1.4.5)
|
||||
htmlentities (>= 4.0.0)
|
||||
premailer-rails (1.9.4)
|
||||
actionmailer (>= 3, < 6)
|
||||
premailer (~> 1.7, >= 1.7.9)
|
||||
pry (0.10.4)
|
||||
coderay (~> 1.1.0)
|
||||
method_source (~> 0.8.1)
|
||||
@ -281,6 +294,7 @@ DEPENDENCIES
|
||||
guard-minitest
|
||||
guard-rubocop
|
||||
guard-shell
|
||||
inky-rb
|
||||
jbuilder (~> 2.6)
|
||||
jquery-rails
|
||||
json (~> 2.0.2)
|
||||
@ -289,6 +303,7 @@ DEPENDENCIES
|
||||
minitest-reporters
|
||||
mysql2 (>= 0.3.18, < 0.5)
|
||||
neat
|
||||
premailer-rails
|
||||
pry-byebug
|
||||
pry-rails
|
||||
puma (~> 3.0)
|
||||
|
9
app/assets/stylesheets/foundation_emails.scss
Normal file
9
app/assets/stylesheets/foundation_emails.scss
Normal file
@ -0,0 +1,9 @@
|
||||
@import "foundation-emails";
|
||||
.pd-logo {
|
||||
font-size: 28px;
|
||||
}
|
||||
|
||||
.email-container {
|
||||
width: 100% !important;
|
||||
max-width:600px;
|
||||
}
|
@ -1,16 +1,12 @@
|
||||
<table cellspacing="0" cellpadding="0" border="0" style="width:100%; font-family:sans-serif;">
|
||||
<tr>
|
||||
<container class="email-container"><row>
|
||||
<columns>
|
||||
<div class="pd-logo">PERFICIENT<span style="color: #EF0734;">/digital</span> Skills Assessment Test</div>
|
||||
</columns>
|
||||
</row>
|
||||
|
||||
<td>
|
||||
<div style="font-size: 28px;">PERFICIENT<span style="color: #EF0734;">/digital</span> Skills Assessment Test</div>
|
||||
<br><br><br>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
<td style="padding:50px;">
|
||||
<p>Dear <strong><%= @candidate.name %></strong>,</p>
|
||||
<row>
|
||||
<columns>
|
||||
<p>Dear <strong><%= @candidate.name %></strong>,</p>
|
||||
<p>
|
||||
Thank you for taking the Skills Assessment Test. However, it looks like you have not submitted it
|
||||
yet. If you are having trouble, please reach out to your recruiter:
|
||||
@ -19,18 +15,9 @@
|
||||
<p>
|
||||
You can return to the test here:
|
||||
<%= link_to nil, root_url %>.
|
||||
<br>
|
||||
<br />
|
||||
Your Test ID is: <strong><%= @candidate.test_hash %></strong>
|
||||
</p>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>
|
||||
<br><br><br>
|
||||
<br><br><br>
|
||||
<div style="background-color: #FFF200; height: 20px; width: 100%;"> </div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</columns>
|
||||
</row></container>
|
@ -1,5 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en" class="no-js">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
@ -1,13 +1,21 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<style>
|
||||
<% # Email styles need to be inline %>
|
||||
</style>
|
||||
<meta name="viewport" content="width=device-width" />
|
||||
|
||||
<%= stylesheet_link_tag "foundation_emails" %>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<%= yield %>
|
||||
<table class="body" data-made-with-foundation>
|
||||
<tr>
|
||||
<td class="center" align="center" valign="top">
|
||||
<center>
|
||||
<%= yield %>
|
||||
</center>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
|
13
app/views/layouts/old_mailer_1470948990.html.erb
Normal file
13
app/views/layouts/old_mailer_1470948990.html.erb
Normal file
@ -0,0 +1,13 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<style>
|
||||
<% # Email styles need to be inline %>
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<%= yield %>
|
||||
</body>
|
||||
</html>
|
@ -11,5 +11,5 @@ Rails.application.config.assets.version = '1.0'
|
||||
# Rails.application.config.assets.precompile += %w( search.js )
|
||||
|
||||
Rails.application.config.assets.precompile += ['vendor/assets/**/*']
|
||||
|
||||
Rails.application.config.assets.precompile += %w(ie9.js)
|
||||
Rails.application.config.assets.precompile += %w( foundation_emails.css )
|
||||
|
Loading…
Reference in New Issue
Block a user