rubyforgood / playtime

Supporting children and families experiencing homelessness in Washington, DC. Live app - https://wishlist.playtimeproject.org Organization Website:
http://www.playtimeproject.org/
MIT License
89 stars 52 forks source link

Paginate Amazon search results #46

Open micahbales opened 7 years ago

micahbales commented 7 years ago

~Incorporate infinite scrolling for results page~

Edited by leesharma: see below for full issue description.

leesharma commented 7 years ago

@micahbales What do you mean by the results page?

Edit: Oh, I see: items/results. Is there a way to get to that page from the current web interface?

micahbales commented 7 years ago

No, I believe this view is only to appear after someone runs a search.

leesharma commented 6 years ago

Okay, here's a full description for this issue:

Right now, when a site manager/admin goes to add new wishlist items, they only see the first 10 search results with no way of accessing the others. The task is to add pagination links so that the user can view subsequent pages of search results.

For UI, I'm not sure if Bootstrap's standard pagination component is appropriate here (since we don't know the total page count), but try to use existing components if you can.

The Complication

Amazon only returns the first 10 results; to implement this issue, you'll either need to make another API request for each clicked-on page of results and/or find a way to return more than 10 results.

Notes

Current View

(Not that the "Next" text in the upper left corner doesn't work.)

Amazon search results