I have a Rails app using Devise and it also uses acts_as_tenant.
In my applications controller I create a variable for the url (including the tenant prefix). It's called $request_url
The issue is that the URL in the confirmation email doesn't change the Tenant prefix. For instance some.website.com vs other.website.com
How do I change this line to use that correct URL? :
<p><%= link_to 'Confirm my account', confirmation_url(@resource, :confirmation_token => @resource.confirmation_token) %></p>
Do I need to create a new route?
Thanks for the help!
Are you saying, though, that you'd like to change where they land after confirmation? I would think you still want them to go through the confirmation controller so their account becomes enabled. If you are saying that you'd like to change where they land after being confirmed, see this answer.
As an aside
$request_url
would be a global variable - those are often dangerous unless you fully understand the implications. Are you setting it in abefore_filter
? You could just use and instance variable like so:@request_url = "some string"