Displaying 1 result from an estimated 1 matches for "popp_image_pages".
2006 Mar 27
0
update subset of my data
...y foriegn key: albumid
Each dealer can login using user_engine engine
I restrict viewing for each dealer to their own images by assigning each
dealer their own albumid.
I list their images with:
in my controller:
def list
@dealers = Dealer.find_all
@dealer = current_user.albumid
@popp_image_pages, @popp_images = paginate :popp_images, :per_page
=> 10
end
in my view:
<%
odd_or_even = 0
for popp_image in @popp_images
odd_or_even = 1 - odd_or_even
%>
<% if (@dealer == nil) || (@dealer == popp_image.albumid)%>
this works fine.
I am stuck on updating multiple pop_images...