url for image

This commit is contained in:
wmcheng 2019-09-02 04:31:45 +08:00
parent 7926019711
commit 54282a4d8d
1 changed files with 3 additions and 3 deletions

View File

@ -14,7 +14,7 @@ namespace :epaper do
subscriber.save
if emails.count == mail_limit
puts "Sending #{mail_limit} mails"
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page}, :mail_to => emails)
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page, "siteurl" => "http://" + domain }, :mail_to => emails)
email.deliver
emails = []
sleep 0.5
@ -26,7 +26,7 @@ namespace :epaper do
emails << email
if emails.count == mail_limit
puts "Sending #{mail_limit} mails"
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page}, :mail_to => emails)
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page, "siteurl" => "http://" + domain }, :mail_to => emails)
email.deliver
emails = []
sleep 0.5
@ -35,7 +35,7 @@ namespace :epaper do
end
if !emails.empty?
puts "Sending last emails"
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page}, :mail_to => emails)
email = Email.new(:mail_subject => paper.sending_title, :mail_lang => :zh_tw, :template => "admin/e_paper_criterias/emailer", :template_data => {"paper" => paper, "page" => "http://" + domain + page, "siteurl" => "http://" + domain }, :mail_to => emails)
email.deliver
end
paper.save