-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using 'url' as a property name in a model #15
Comments
We are having the same issue around here, our object from the api contains an 'url' property. The issue is that if we use the 'url' inside the props definition of the model, then the url() function is never defined, so when you do fetch(), save(), etc, throws 'Error: A "url" property or function must be specified'. Thanks! |
This might help getting data into your ampersand models. |
Thanks brian, that should work as a workaround! |
Related/duplicate issue AmpersandJS/ampersand-collection-rest-mixin#3 |
Hi folks! Sorry this has been sitting so long. Closing as a dupe of AmpersandJS/ampersand-collection-rest-mixin#3 Workaround is to either re-name it in using |
When you create a model and try to use url in the list of props, an error is thrown when you try to save it.
If you set the url it of coarse changes the url in which the model is saved.
Since url is a common field name used in databases I expected to be able to use it in an ampersand model.
Here is a simplified example: http://requirebin.com/?gist=2372c9322f4d2f5d5c3a
The text was updated successfully, but these errors were encountered: