2015-02-12 13:09:11 -08:00
|
|
|
$('#entries').append('<% @inbox.each do |i|
|
|
|
|
%><%= j render 'inbox/entry', i: i
|
2015-02-12 12:59:46 -08:00
|
|
|
%><% end %>');
|
2020-04-20 14:03:57 -07:00
|
|
|
<% if @more_data_available %>
|
|
|
|
$('#pagination').html('<%= j render 'shared/cursored_pagination_dummy', more_data_available: @more_data_available, last_id: @inbox_last_id %>');
|
2015-02-12 12:59:46 -08:00
|
|
|
<% else %>
|
|
|
|
$('#pagination, #load-more-btn').remove();
|
2015-02-12 13:09:11 -08:00
|
|
|
<% end %>
|
2020-04-20 14:03:57 -07:00
|
|
|
<% Inbox.where(id: @inbox.pluck(:id)).update_all(new: false) %>
|