FIX: Plugins were broken for initial payloads

Our plugins use rails engines which are mounted against the main
application's `ApplicationController`. This works great but path helpers
need to reference `main_app` in order for it not to blow up.
This commit is contained in:
Robin Ward 2015-04-09 12:26:24 -04:00
parent 4a9587fa23
commit 0d90b495a8

View File

@ -45,10 +45,10 @@
<footer> <footer>
<nav itemscope itemtype='http://schema.org/SiteNavigationElement'> <nav itemscope itemtype='http://schema.org/SiteNavigationElement'>
<a href='/'><%= t 'home_title' %></a> <a href='/'><%= t 'home_title' %></a>
<%= link_to t('js.filters.categories.title'), categories_path %> <%= link_to t('js.filters.categories.title'), main_app.categories_path %>
<%= link_to t('guidelines_topic.title'), guidelines_path %> <%= link_to t('guidelines_topic.title'), main_app.guidelines_path %>
<%= link_to t('tos_topic.title'), tos_path %> <%= link_to t('tos_topic.title'), main_app.tos_path %>
<%= link_to t('privacy_topic.title'), privacy_path %> <%= link_to t('privacy_topic.title'), main_app.privacy_path %>
</nav> </nav>
</footer> </footer>
</div> </div>
@ -71,7 +71,7 @@
</div> </div>
<% unless current_user %> <% unless current_user %>
<form id='hidden-login-form' method="post" action="<%=login_path%>" style="display: none;"> <form id='hidden-login-form' method="post" action="<%=main_app.login_path%>" style="display: none;">
<input name="username" type="text" id="signin_username"> <input name="username" type="text" id="signin_username">
<input name="password" type="password" id="signin_password"> <input name="password" type="password" id="signin_password">
<input name="redirect" type="hidden"> <input name="redirect" type="hidden">