add index on post_versions.updated_at

This commit is contained in:
albert
2013-02-20 22:24:14 -05:00
parent d5c3e10d57
commit efaae104fb
2 changed files with 10 additions and 1 deletions

View File

@@ -18,7 +18,7 @@
<td><%= feedback.category %></td>
<td><%= link_to feedback.user_name, user_path(feedback.user_id) %></td>
<td><%= link_to feedback.creator_name, user_path(feedback.creator_id) %></td>
<td><%= time_ago_in_words_tagged(feedback.created_at) %></td>
<td><%= compact_time(feedback.created_at) %></td>
<td><%= format_text(feedback.body) %></td>
</tr>
<% end %>

View File

@@ -0,0 +1,9 @@
class AddIndexUpdatedAtOnPostVersions < ActiveRecord::Migration
def up
add_index :post_versions, :updated_at
end
def down
remove_index :post_versions, :updated_at
end
end