-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Artur Beljajev
committed
Mar 28, 2019
1 parent
5d63feb
commit b06b99a
Showing
4 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
require_relative 'production' | ||
|
||
Rails.application.configure do | ||
config.action_mailer.show_previews = true | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
class DomainDeleteMailerPreview < ActionMailer::Preview | ||
def self.define_forced_templates | ||
DomainDeleteMailer.force_delete_templates.each do |template_name| | ||
define_method "forced_#{template_name}".to_sym do | ||
domain = Domain.first | ||
DomainDeleteMailer.forced(domain: domain, | ||
registrar: domain.registrar, | ||
registrant: domain.registrant, | ||
template_name: template_name) | ||
end | ||
end | ||
end | ||
|
||
define_forced_templates | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
class DomainExpireMailerPreview < ActionMailer::Preview | ||
def expired | ||
domain = Domain.first | ||
DomainExpireMailer.expired(domain: domain, | ||
registrar: domain.registrar) | ||
end | ||
end |