fixed unworking infinite scroll

This commit is contained in:
Dmitriy Zaporozhets 2012-02-12 23:52:27 +02:00
parent 48bc4fc214
commit ece9f50fb1
11 changed files with 180 additions and 66 deletions

View file

@ -26,6 +26,6 @@
- if @commits.count == @limit
:javascript
$(function(){
CommitsList.init("#{@ref}", 20);
CommitsList.init("#{@ref}", #{@limit});
});

View file

@ -14,3 +14,8 @@
- else
:plain
- else
- if params[:first_id]
:plain
NoteList.append(#{params[:first_id]}, "");

View file

@ -3,7 +3,7 @@
%small= "( #{current_user.projects.count} )"
%hr
- unless @projects.empty?
%div.tile= render "tile"
%div.content_list= render "tile"
-# If projects requris paging
-# We add ajax loader & init script
@ -13,7 +13,7 @@
:javascript
$(function(){
ProjectsList.init(16);
Pager.init(#{@limit});
});
- else
%h2 Nothing here

View file

@ -1,2 +1,2 @@
:plain
ProjectsList.append(#{@projects.count}, "#{escape_javascript(render(:partial => 'projects/tile'))}");
Pager.append(#{@projects.count}, "#{escape_javascript(render(:partial => 'projects/tile'))}");