So you're suggesting to go with the regular index and show pages and
param the heck out of them putting different content in if params[:ip]
or params[:user_id]
or should I create non standard pages for that ?

Btw. adding custom (non-hobo) actions to the controller I need to set
up rails routing manually right ? Hobo won't take care of that for me
just by adding that in the hobo controller right ?

On Mar 4, 4:50 pm, Bryan Larsen <[email protected]> wrote:
> > when i try to link to /ip_logs/ip /ip_logs/user I get no route matches
> > error I'm guessing I'm missing something but /ip_logs/127.0.0.1 (the
> > ip value for both test entries) also shows that error and not a blank
> > page or edit me here page
>
> I'm guessing that IP is not unique, that there will be more than one
> IpLog per IP, right?
>
> In Hobo /ip_logs/1 is a show page that shows the IpLog for id#1.
> It's definitely possible to make it into an index page, but you're
> probably better off just doing filtering:
>
> /ip_logs?ip=127.0.0.1
>
> def index
>   self.this = IpLog.where(:ip => params[:ip]) if params[:ip]
>   hobo_index
> end
>
> You can set up /ip_logs/ip /ip_logs/user by learning how to do generic
> Rails routing or you can use
>
> /users/1-test-user/ip_logs?ip=127.0.0.1  and a similar structure to above.
>
> or if you don't have :owner  etc set up you can just do filtering:
>
> /ip_logs?ip=127.0.0.1&user=1-test-user
>
> cheers,
> Bryan

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/hobousers?hl=en.

Reply via email to