Forum: Ruby on Rails Edge Rails Apps Consuming 1.2 Rails Resources

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
3c458017e52f646945b899aa5d380a0f?d=identicon&s=25 Matthew Isleb (misleb)
on 2007-07-21 00:31
Hi, I'm currently starting a new Rails app using Edge so I can utilize
the Active Resources client. The app I am consuming resources from is a
production 1.2.3 app (I can't easily go Edge with it). The problem I'm
having is that Edge has changed the Resources URL structure. In my
production app, the URL for a custom action would be
/users.xml;authenticate. In Edge is is something like
/users/authenticate.xml.

s there any way to easily make them compatible or am I just SOL by this
query string change until I can update the production app to Edge Rails?

I suppose I could simply construct my own query strings in the client,
but that kinda takes the fun out of Active Resources.

-matthew
Ddeec660d0ddef3647786f7adb228a97?d=identicon&s=25 Luca Mearelli (Guest)
on 2007-07-21 14:51
(Received via mailing list)
I think that your best/only option is to map those custom actions
using specific named routes:

map.resources :users, :collection => {:authenticate => :get}
map.connect 'users/authenticate.xml', :controller => 'users', :action
=> 'authenticate', :format => 'xml'

bye
Luca

2007/7/21, Matthew Isleb <rails-mailing-list@andreas-s.net>:
This topic is locked and can not be replied to.