method
new_element_path
v3.2.1 -
Show latest stable
-
0 notes -
Class: ActiveResource::Base
- 1.0.0
- 1.1.6
- 1.2.6
- 2.0.3
- 2.1.0
- 2.2.1
- 2.3.8
- 3.0.0 (0)
- 3.0.9 (-2)
- 3.1.0 (0)
- 3.2.1 (8)
- 3.2.8 (0)
- 3.2.13 (0)
- 4.0.2
- 4.1.8
- 4.2.1
- 4.2.7
- 4.2.9
- 5.0.0.1
- 5.1.7
- 5.2.3
- 6.0.0
- 6.1.3.1
- 6.1.7.7
- 7.0.0
- 7.1.3.2
- 7.1.3.4
- What's this?
new_element_path(prefix_options = {})
public
Gets the new element path for REST resources.
Options
-
prefix_options - A hash to add a prefix to the request for nested URLs (e.g., :account_id => 19 would yield a URL like /accounts/19/purchases/new.json).
Examples
Post.new_element_path # => /posts/new.json class Comment < ActiveResource::Base self.site = "http://37s.sunrise.i/posts/:post_id/" end Comment.collection_path(:post_id => 5) # => /posts/5/comments/new.json