Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 7ab00f4

Browse files
committed
docs($resource): clarify how a @-prefix param is used
1 parent 02aef57 commit 7ab00f4

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/ngResource/resource.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,13 @@ function shallowClearAndCopy(src, dst) {
123123
* Given a template `/path/:verb` and parameter `{verb:'greet', salutation:'Hello'}` results in
124124
* URL `/path/greet?salutation=Hello`.
125125
*
126-
* If the parameter value is prefixed with `@` then the value for that parameter will be extracted
127-
* from the corresponding property on the `data` object (provided when calling an action method).
126+
* If the parameter value is prefixed with `@`, then the value for that parameter will be
127+
* extracted from the corresponding property on the `data` object (provided when calling a
128+
* "non-GET" action method).
128129
* For example, if the `defaultParam` object is `{someParam: '@someProp'}` then the value of
129130
* `someParam` will be `data.someProp`.
131+
* Note that the parameter will be ignored, when calling a "GET" action method (i.e. an action
132+
* method that does not accept a request body)
130133
*
131134
* @param {Object.<Object>=} actions Hash with declaration of custom actions that should extend
132135
* the default set of resource actions. The declaration should be created in the format of {@link

0 commit comments

Comments
 (0)