added pagination to photo picker on the user profile. still ugly, less sucky

This commit is contained in:
maxwell 2010-07-26 13:55:44 -07:00
parent 0c2fc54c0f
commit d7550568ad
3 changed files with 3 additions and 2 deletions

View file

@ -12,7 +12,7 @@ class UsersController < ApplicationController
def edit
@user = User.first(:id => params[:id])
@profile = @user.profile
@photos = Photo.all
@photos = Photo.paginate :page => params[:page], :order => 'created_at DESC'
end
def update

View file

@ -17,6 +17,7 @@
%div.small_photo{:id => photo.image.thumb_medium.url}
= check_box_tag 'checked_photo'
= link_to image_tag(photo.image.url(:thumb_medium)), "#"
=will_paginate @photos
%h3 Info