adds a helper to simplify the way selects and filters are rendered

This commit is contained in:
kikito
2015-08-28 20:07:45 +02:00
parent ae98ba3572
commit a7929c607d
9 changed files with 15 additions and 9 deletions

View File

@@ -8,7 +8,7 @@
<dd class="active"><%= t("admin.comments.index.filters.#{filter}") %></dd>
<% else %>
<dd><%= link_to t("admin.comments.index.filters.#{filter}"),
admin_comments_path(filter: filter) %></dd>
current_path_with_query_params(filter: filter) %></dd>
<% end %>
<% end %>
</dl>

View File

@@ -8,7 +8,7 @@
<dd class="active"><%= t("admin.debates.index.filters.#{filter}") %></dd>
<% else %>
<dd><%= link_to t("admin.debates.index.filters.#{filter}"),
admin_debates_path(filter: filter) %></dd>
current_path_with_query_params(filter: filter) %></dd>
<% end %>
<% end %>
</dl>

View File

@@ -21,7 +21,7 @@
<dd class="active"><%= t("admin.organizations.index.filters.#{filter}") %></dd>
<% else %>
<dd><%= link_to t("admin.organizations.index.filters.#{filter}"),
admin_organizations_path(filter: filter) %></dd>
current_path_with_query_params(filter: filter) %></dd>
<% end %>
<% end %>
</dl>

View File

@@ -8,7 +8,7 @@
<dd class="active"><%= t("admin.users.index.filters.#{filter}") %></dd>
<% else %>
<dd><%= link_to t("admin.users.index.filters.#{filter}"),
admin_users_path(filter: filter) %></dd>
current_path_with_query_params(filter: filter) %></dd>
<% end %>
<% end %>
</dl>