Ruby on Rails
Wednesday, February 26, 2014
Thanks for the link Mike. Actually I my mobile app is using PhoneGap. So it does JSON calls to my User controller.
On Thursday, February 27, 2014 4:44:24 AM UTC+8, mike wrote:
-- Been looking for a better way to organise the methods. Right now in addition to Create, I also have Mobile_create in the User controller because Mobile_create is slightly different from Create.
On Thursday, February 27, 2014 4:44:24 AM UTC+8, mike wrote:
On Tuesday, February 25, 2014 6:43:52 AM UTC-5, Brandon wrote:Hi,I've controller methods which my mobile app calls to retrieve JSON.I'm curious what is the best practice in naming mobile methods? Do I put all the mobile calls into a new controller? Right now I'm only prependng 'mobile_' in front of the methods like session/mobile_create.Right now the mobile functions are quite different from the Web ones. So a sessions/create VS sessions/mobile_create is different and so mobile_create news to exist.I'm not sure I understand exactly what you're doing, but I'm assuming when you refer to a mobile app you mean a rails app running on a mobile device (as opposed to an app developed in Cocoa or Android that is accessing your API). In that case, I would recommend Rails 4.1 as they have developed a standard that is a lot easier to use. Look at the section "ActionPack Variants" at the following link:
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/0354fb1c-8de3-41c4-b70a-500d3fbe7ca9%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment