rails & custom devise controller > email templates

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

rails & custom devise controller > email templates

tommaso159
hello,

i have an app that operates under 2 domains, depending on the domain
the app serves 2 different application layouts. Now i want to show
different devise-email-layouts when sending these devise emails.
I have the custom devise controllers and i can trigger them from an
test action, but i don't know how to use them on devise actions.
thank you in advance
t

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CADQqhMcC8FrOtz_5_tR66%2Bi6wef8a69J2_SsNvsnCcttAgD%3DDg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: rails & custom devise controller > email templates

Walter Lee Davis

> On Nov 15, 2018, at 9:02 AM, tom <[hidden email]> wrote:
>
> hello,
>
> i have an app that operates under 2 domains, depending on the domain
> the app serves 2 different application layouts. Now i want to show
> different devise-email-layouts when sending these devise emails.
> I have the custom devise controllers and i can trigger them from an
> test action, but i don't know how to use them on devise actions.
> thank you in advance
> t
>

I would start here: https://guides.rubyonrails.org/layouts_and_rendering.html#the-layout-option

It's not specific to mailers, but the concept should apply.

Walter

> --
> You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
> To post to this group, send email to [hidden email].
> To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CADQqhMcC8FrOtz_5_tR66%2Bi6wef8a69J2_SsNvsnCcttAgD%3DDg%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/EDB035F5-32C9-48BF-8005-1E2D9D6200BA%40wdstudio.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: rails & custom devise controller > email templates

Rob Zolkos-2
In reply to this post by tommaso159
You can also configure which email layout to use (would be similar to how you are setting the application layout to use).

  # Or to configure mailer layout
  Devise::Mailer.layout "email"

On Thu, Nov 15, 2018 at 9:03 AM tom <[hidden email]> wrote:
hello,

i have an app that operates under 2 domains, depending on the domain
the app serves 2 different application layouts. Now i want to show
different devise-email-layouts when sending these devise emails.
I have the custom devise controllers and i can trigger them from an
test action, but i don't know how to use them on devise actions.
thank you in advance
t

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CADQqhMcC8FrOtz_5_tR66%2Bi6wef8a69J2_SsNvsnCcttAgD%3DDg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAJ6MPzKMChinDno6NOJbaUpdy2JZt-mDAMkRejMUVHcK1FXLrg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.