{"action":"created","issue":{"url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/258","repository_url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api","labels_url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/258/labels{/name}","comments_url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/258/comments","events_url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/258/events","html_url":"https://github.com/django-json-api/django-rest-framework-json-api/issues/258","id":163970540,"number":258,"title":"ResourceRelatedField and the browsable API","user":{"login":"alexahn","id":1480330,"avatar_url":"https://avatars.githubusercontent.com/u/1480330?v=3","gravatar_id":"","url":"https://api.github.com/users/alexahn","html_url":"https://github.com/alexahn","followers_url":"https://api.github.com/users/alexahn/followers","following_url":"https://api.github.com/users/alexahn/following{/other_user}","gists_url":"https://api.github.com/users/alexahn/gists{/gist_id}","starred_url":"https://api.github.com/users/alexahn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexahn/subscriptions","organizations_url":"https://api.github.com/users/alexahn/orgs","repos_url":"https://api.github.com/users/alexahn/repos","events_url":"https://api.github.com/users/alexahn/events{/privacy}","received_events_url":"https://api.github.com/users/alexahn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-05T23:46:03Z","updated_at":"2016-08-18T15:50:11Z","closed_at":null,"body":"When I define a field on a serializer using ResourceRelatedField, the browsable API's form field corresponding to this field does not load the correct value. For example, if I have a serializer like this:\r\n```\r\nclass BlogSerializer(rest_framework_json_api.serializers.HyperlinkedModelSerializer):\r\n    user = rest_framework_json_api.relations.ResourceRelatedField(\r\n        queryset=User.objects,\r\n        related_link_view_name='blog-user',\r\n        related_link_url_kwarg='blog_pk',\r\n    )\r\n```\r\nThe browsable API no longer loads the correct value for the `User` field when going to the detail view for an instance (e.g. `/blog/1`)"},"comment":{"url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/comments/240767279","html_url":"https://github.com/django-json-api/django-rest-framework-json-api/issues/258#issuecomment-240767279","issue_url":"https://api.github.com/repos/django-json-api/django-rest-framework-json-api/issues/258","id":240767279,"user":{"login":"jerel","id":322706,"avatar_url":"https://avatars.githubusercontent.com/u/322706?v=3","gravatar_id":"","url":"https://api.github.com/users/jerel","html_url":"https://github.com/jerel","followers_url":"https://api.github.com/users/jerel/followers","following_url":"https://api.github.com/users/jerel/following{/other_user}","gists_url":"https://api.github.com/users/jerel/gists{/gist_id}","starred_url":"https://api.github.com/users/jerel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jerel/subscriptions","organizations_url":"https://api.github.com/users/jerel/orgs","repos_url":"https://api.github.com/users/jerel/repos","events_url":"https://api.github.com/users/jerel/events{/privacy}","received_events_url":"https://api.github.com/users/jerel/received_events","type":"User","site_admin":false},"created_at":"2016-08-18T15:50:11Z","updated_at":"2016-08-18T15:50:11Z","body":"I'm not sure what's going on here... I use the browsable API along with `ResourceRelatedField` and the forms work correctly. However I don't have a serializer defined exactly like yours so it's possibly a bug in that exact code path."}}
{"actor":{"display_login":"jerel"}}