That must be a Rails routing issue then. It is needed to compute the
pagination link, I guess you're using URL helpers in your representer.
Can you paste the representer module here, please?
On Tue, Mar 26, 2013 at 11:20 AM, Marcel Augsburger
<
maugs...@gmail.com> wrote:
> First of all, congrats for the awesome work. I'm working on parliamentary
> monitoring tools, and wasn't sure how to handle the interaction between the
> back end and multiple front ends with different fields, and it looks like
> ROAR is just what I needed!
>
> The first thing I did was cloning elvanja's roar_example, and it helped a
> ton! Then I needed pagination, and tried to follow the Pagination With ROAR
> tutorial with no success... I cloned the ruby-on-rest project, but still had
> problems with that.
>n
> This is what happens when working with Rails 3.2.1, and will_paginate 3.0.3:
>
> I create a bowl, and paginate the fruits. Everything working: page.to_json
> returns fine. Then I extend BowlPageRepresenter and .to_json gives me this
> error:
>
> ActionController::RoutingError: No route matches {:action=>”show”,
> :controller=>”bowls”, :page=>page 1}
>
> This might be a noob question, but, why is it routing anyway?
> Other methods like to_xml work fine… probably because they’re not overridden
> by ROAR like to_json. Mixed-in methods like .page_url are also giving me
> similar errors.
>
> Any clues? Thanks again!
>
> --
> You received this message because you are subscribed to the Google Groups
> "Roar" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to
roar-talk+...@googlegroups.com.
> For more options, visit
https://groups.google.com/groups/opt_out.
>
>