<% sorting = active_scaffold_config.list.user.sorting sorting_stages = ['reset', 'ASC', 'DESC'] default_sorting = active_scaffold_config.list.sorting default_sorting_stages = ['ASC', 'DESC'] -%> <%# AST Begin -%> <% href = url_for(params_for(:action => :reset_search, :escape => false).delete_if{|k,v| k == 'search'}) @link_to_reset_filter = link_to_remote(as_(:filtered__click_to_reset), { :url => href, :method => :get, :before => "addActiveScaffoldPageToHistory('#{href}', '#{params[:controller]}')", :after => "$('#{loading_indicator_id(:action => :table)}').style.visibility = 'visible';", :complete => "$('#{loading_indicator_id(:action => :table)}').style.visibility = 'hidden';", :failure => "ActiveScaffold.report_500_response('#{active_scaffold_id}')", :update => active_scaffold_content_id}, { :href => href }) if @filtered show_actions_column = active_scaffold_config.show_actions_column and active_scaffold_config.action_links.any? {|link| link.type == :record } -%> <% if active_scaffold_config.left_handed and show_actions_column -%> <%= @link_to_reset_filter %> <% end %> <% if active_scaffold_config.one_column_list %>

<%= show_actions_column ? ' ' : @link_to_reset_filter || ' ' %>

<% else -%> <% active_scaffold_tools_list_columns.each do |column| -%> <%# AST End -%> <% stages = default_sorting.sorts_on?(column) ? default_sorting_stages : sorting_stages column_sort_direction = stages.after(sorting.direction_of(column)) || 'ASC' sort_params = params_for(:action => :update_table, :page => 1, :sort => column.name, :sort_direction => column_sort_direction) column_header_id = active_scaffold_column_header_id(column) -%> " title="<%= h column.description %>"> <% if column.sortable? -%> <% href = url_for(sort_params) -%> <%= link_to_remote column.label, { :url => sort_params, :before => "addActiveScaffoldPageToHistory('#{href}', '#{controller_id}')", :loading => "Element.addClassName('#{column_header_id}','loading');", :failure => "ActiveScaffold.report_500_response('#{active_scaffold_id}')", :update => active_scaffold_content_id, :method => :get }, { :href => href } %> <% else -%>

<%= column.label %>

<% end -%> <%= inplace_edit_control(column) -%> <% end -%> <%# AST Begin -%> <% end -%> <% if !active_scaffold_config.left_handed and show_actions_column -%> <%= @link_to_reset_filter %> <% end -%> <%# AST End -%>