Skip to content

Commit

Permalink
Add older/newer links in front of diary, comment, issue, block pages
Browse files Browse the repository at this point in the history
  • Loading branch information
AntonKhorev committed Oct 15, 2024
1 parent 29cc3d2 commit 53fb10f
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/views/diary_comments/_page.html.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<turbo-frame id="pagination" target="_top" data-turbo="false">
<%= render "shared/pagination",
:newer_id => @newer_comments_id,
:older_id => @older_comments_id %>

<table class="table table-striped" width="100%">
<thead>
<tr>
Expand Down
4 changes: 4 additions & 0 deletions app/views/diary_entries/_page.html.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<turbo-frame id="pagination" target="_top" data-turbo="false">
<h4><%= t ".recent_entries" %></h4>

<%= render "shared/pagination",
:newer_id => @newer_entries_id,
:older_id => @older_entries_id %>
<%= render @entries %>
<%= render "shared/pagination",
Expand Down
5 changes: 5 additions & 0 deletions app/views/issues/_page.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
<p><%= t ".issues_not_found" %></p>
<% end %>
<% else %>
<%= render "shared/pagination",
:newer_id => @newer_issues_id,
:older_id => @older_issues_id %>

<table class="table table-sm">
<thead>
<tr>
Expand Down Expand Up @@ -35,6 +39,7 @@
<% end %>
</tbody>
</table>

<%= render "shared/pagination",
:newer_id => @newer_issues_id,
:older_id => @older_issues_id %>
Expand Down
4 changes: 4 additions & 0 deletions app/views/user_blocks/_page.html.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<turbo-frame id="pagination" target="_top" data-turbo="false">
<%= render "shared/pagination",
:newer_id => @newer_user_blocks_id,
:older_id => @older_user_blocks_id %>

<table id="block_list" class="table table-borderless table-striped table-sm">
<thead>
<tr>
Expand Down

0 comments on commit 53fb10f

Please sign in to comment.