分页改为了15条
This commit is contained in:
parent
830815d3fd
commit
67c5a8e9c5
|
@ -933,13 +933,13 @@ class UsersController < ApplicationController
|
|||
end
|
||||
end
|
||||
@type = params[:type] || 1
|
||||
@limit = 10
|
||||
@limit = 15
|
||||
@is_remote = true
|
||||
@obj_count = @attachments.count
|
||||
@obj_pages = Paginator.new @obj_count, @limit, params['page'] || 1
|
||||
@offset ||= @obj_pages.offset
|
||||
@atta_count = @attachments.count
|
||||
@atta_pages = Paginator.new @atta_count, @limit, params['page'] || 1
|
||||
@offset ||= @atta_pages.offset
|
||||
#@curse_attachments_all = @all_attachments[@offset, @limit]
|
||||
@attachments = paginateHelper @attachments,10
|
||||
@attachments = paginateHelper @attachments,15
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
|
@ -989,13 +989,13 @@ class UsersController < ApplicationController
|
|||
end
|
||||
end
|
||||
@type = params[:type]
|
||||
@limit = 10
|
||||
@limit = 15
|
||||
@is_remote = true
|
||||
@obj_count = @attachments.count
|
||||
@obj_pages = Paginator.new @obj_count, @limit, params['page'] || 1
|
||||
@offset ||= @obj_pages.offset
|
||||
@atta_count = @attachments.count
|
||||
@atta_pages = Paginator.new @atta_count, @limit, params['page'] || 1
|
||||
@offset ||= @atta_pages.offset
|
||||
#@curse_attachments_all = @all_attachments[@offset, @limit]
|
||||
@attachments = paginateHelper @attachments,10
|
||||
@attachments = paginateHelper @attachments,15
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
|
@ -1405,13 +1405,13 @@ class UsersController < ApplicationController
|
|||
end
|
||||
end
|
||||
@type = params[:type]
|
||||
@limit = 10
|
||||
@limit = 15
|
||||
@is_remote = true
|
||||
@obj_count = @attachments.count
|
||||
@obj_pages = Paginator.new @obj_count, @limit, params['page'] || 1
|
||||
@offset ||= @obj_pages.offset
|
||||
@atta_count = @attachments.count
|
||||
@atta_pages = Paginator.new @atta_count, @limit, params['page'] || 1
|
||||
@offset ||= @atta_pages.offset
|
||||
#@curse_attachments_all = @all_attachments[@offset, @limit]
|
||||
@attachments = paginateHelper @attachments,10
|
||||
@attachments = paginateHelper @attachments,15
|
||||
respond_to do |format|
|
||||
format.js
|
||||
format.html {render :layout => 'base_users_new'}
|
||||
|
@ -1457,13 +1457,13 @@ class UsersController < ApplicationController
|
|||
end
|
||||
end
|
||||
@type = params[:type]
|
||||
@limit = 10
|
||||
@limit = 15
|
||||
@is_remote = true
|
||||
@obj_count = @attachments.count
|
||||
@obj_pages = Paginator.new @obj_count, @limit, params['page'] || 1
|
||||
@offset ||= @obj_pages.offset
|
||||
@atta_count = @attachments.count
|
||||
@atta_pages = Paginator.new @atta_count, @limit, params['page'] || 1
|
||||
@offset ||= @atta_pages.offset
|
||||
#@curse_attachments_all = @all_attachments[@offset, @limit]
|
||||
@attachments = paginateHelper @attachments,10
|
||||
@attachments = paginateHelper @attachments,15
|
||||
respond_to do |format|
|
||||
format.js
|
||||
end
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
$("#resources_list").html('<%= escape_javascript( render :partial => 'resources_list' ,:locals=>{ :attachments => @attachments})%>');
|
||||
$("#pages").html('<%= pagination_links_full @obj_pages, @obj_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
||||
$("#pages").html('<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
|
@ -105,7 +105,7 @@
|
|||
</div>
|
||||
<div>
|
||||
<ul class="wlist" id="pages">
|
||||
<%= pagination_links_full @obj_pages, @obj_count, :per_page_links => false, :remote => @is_remote, :flag => true%>
|
||||
<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true%>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
$("#search_div").html('<%= escape_javascript( render :partial => 'resource_search_form',:locals => {:user=>@user,:type=>@type} ) %>');
|
||||
$("#resources_list").html('<%= escape_javascript( render :partial => 'resources_list' ,:locals=>{ :attachments => @attachments})%>');
|
||||
$("#pages").html('<%= pagination_links_full @obj_pages, @obj_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
||||
$("#pages").html('<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
|
@ -2,3 +2,4 @@
|
|||
closeModal();
|
||||
$("#resources_list").html('<%= escape_javascript( render :partial => 'resources_list' ,:locals=>{ :attachments => @attachments})%>');
|
||||
|
||||
$("#pages").html('<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
|
@ -1,2 +1,2 @@
|
|||
$("#resources_list").html('<%= escape_javascript( render :partial => 'resources_list' ,:locals=>{ :attachments => @attachments})%>');
|
||||
$("#pages").html('<%= pagination_links_full @obj_pages, @obj_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
||||
$("#pages").html('<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
|
Loading…
Reference in New Issue