diff options
Diffstat (limited to 'app/views/layouts')
| -rw-r--r-- | app/views/layouts/_nav_controls.html.erb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/views/layouts/_nav_controls.html.erb b/app/views/layouts/_nav_controls.html.erb index bae1082b..70d5130c 100644 --- a/app/views/layouts/_nav_controls.html.erb +++ b/app/views/layouts/_nav_controls.html.erb | |||
| @@ -9,7 +9,8 @@ | |||
| 9 | <% end %> | 9 | <% end %> |
| 10 | 10 | ||
| 11 | <span class="nav_group"> | 11 | <span class="nav_group"> |
| 12 | <%= link_to url_for(locale: (:en unless I18n.locale == :en)), | 12 | <% locale_target = request.query_parameters.symbolize_keys.except(:controller, :action, :only_path, :host, :port, :protocol, :anchor, :script_name).merge(:locale => (:en unless I18n.locale == :en)) %> |
| 13 | <%= link_to url_for(locale_target), | ||
| 13 | class: "nav_toggle nav_locale", | 14 | class: "nav_toggle nav_locale", |
| 14 | "aria-label" => t(".switch_locale"), title: t(".switch_locale") do %> | 15 | "aria-label" => t(".switch_locale"), title: t(".switch_locale") do %> |
| 15 | <%= I18n.locale == :en ? "DE" : "EN" %> | 16 | <%= I18n.locale == :en ? "DE" : "EN" %> |
