[英]Tastypie - get user groups resource_uri
I'm trying to update the groups assigned to users via an API (via rest) with Tastypie. 我正在尝试通过Delicious(通过Rest)更新通过API分配给用户的组。
I tried passing the group id's directly in, however it says that the URL provided is not a valid resource. 我尝试直接传入组ID,但是它说提供的URL不是有效资源。 I then tried passing in a URL such as ' /api/v1/groups/1/
' but that is saying that's not a link to a valid resource. 然后,我尝试传递诸如“ /api/v1/groups/1/
”之类的URL,但这就是说这不是指向有效资源的链接。
Any hints? 有什么提示吗? I'm creating user records just fine from a standard django view/form, but I would like to do this as a REST action. 我正在从标准django视图/窗体创建用户记录,但是我想将它作为REST操作来完成。
您是否需要指定格式,例如: /api/v1/groups/1/?format=json
?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.