tomchristie/django-rest-framework — pull request #347 by minddust (2012-10-31 14:32:57+00:00)
Title: support for passing custom slug options to HyperlinkedRelatedField

without subclassing HyperlinkedRelatedField and overwriting
slug_url_kwarg and slug_field there is no possibility to use other
fields / arguments. now you can do something like this:

```python
url(r'^users/(?P\w[\w-]*)$', UserInstance.as_view(),
name='user-detail')

class ProjectSerializer(serializers.HyperlinkedModelSerializer):
created_by =
serializers.HyperlinkedRelatedField(view_name='user-detail',
slug_url_kwargs='username', slug_field='username')
```