提交 d016decb 编写于 作者: A Aditya Sanghi

Dynamic Delivery Method Options

上级 150c6dc3
......@@ -116,6 +116,20 @@ h3. Action Mailer
* Asynchronously send messages via the Rails Queue.
* Delivery Options (such as SMTP Settings) can now be set dynamically per mailer action.
Delivery options are set via <tt>:delivery_method_options</tt> key on mail.
<ruby>
def welcome_mailer(user,company)
mail to: user.email,
subject: "Welcome!",
delivery_method_options: {user_name: company.smtp_user,
password: company.smtp_password,
address: company.smtp_server}
end
</ruby>
h3. Action Pack
h4. Action Controller
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册