public
Description: This contains various plugins for Feather
Clone URL: git://github.com/eldiablo/feather-plugins.git
Search Repo:
Click here to lend your support to: feather-plugins and make a donation at www.pledgie.com !
Threw in comment pagination. Moved comment links to the action div.
mleung (author)
Fri May 09 01:23:52 -0700 2008
commit  61e7f41da5aae4a11ce56561a1177886e8348690
tree    3385e0113e4a4087debad0e535e4904b3ab5005f
parent  55f5eccb3ff14998d78f45ab6707e6f57c69e9fc
...
4
5
6
7
 
8
9
10
...
4
5
6
 
7
8
9
10
0
@@ -4,7 +4,7 @@
0
     before :find_comment, :only => %w(edit update delete show)
0
 
0
     def index
0
- @comments = Comment.all
0
+ @comments = Comment.paginate(:page => params[:page], :per_page => 10, :order => "created_at DESC")
0
       display @comments
0
     end
0
 
...
 
 
 
 
1
2
3
...
35
36
37
38
39
40
...
1
2
3
4
5
6
7
...
39
40
41
 
 
 
0
@@ -1,3 +1,7 @@
0
+<div id="actions">
0
+ <%= link_to "Edit comment settings", url(:edit_admin_comment_settings, @comment_setting) %> |
0
+ <%= link_to "View comments", url(:admin_comments) %>
0
+</div>
0
 <% throw_content :right do %>
0
   <h4>View Comment Settings</h4>
0
   <p>
0
@@ -35,7 +39,4 @@
0
   <%= @comment_setting.to_email %>
0
 </p>
0
 <% end %>
0
-
0
-<%= link_to "Edit comment settings", url(:edit_admin_comment_settings, @comment_setting) %> |
0
-<%= link_to "View comments", url(:admin_comments) %>
...
7
8
9
 
 
 
 
10
11
12
...
21
22
23
24
25
 
 
 
 
 
...
7
8
9
10
11
12
13
14
15
16
...
25
26
27
 
 
28
29
30
31
32
0
@@ -7,6 +7,10 @@
0
   </p>
0
 <% end %>
0
 
0
+<div id="action">
0
+ <%= link_to "View comment settings", url(:admin_comment_settings) %>
0
+</div>
0
+
0
 <h1>View Comments</h1>
0
 
0
 <table class='tabular'>
0
@@ -21,6 +25,9 @@
0
   </thead>
0
   <%= partial('admin/comments/comment', :with => @comments) %>
0
 </table>
0
-<br />
0
-<%= link_to "View comment settings", url(:admin_comment_settings) %>
0
+
0
+<div id="pagination">
0
+ <%= merb_paginate @comments %>
0
+ <%= page_entries_info @comments %>
0
+</div>

Comments

    No one has commented yet.