Skip to content

Instantly share code, notes, and snippets.

@synic
Created April 20, 2012 16:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save synic/2429974 to your computer and use it in GitHub Desktop.
Save synic/2429974 to your computer and use it in GitHub Desktop.
class EmailResource(NBResource):
contact = fields.ForeignKey(ContactResource, 'contact', null=True)
class Meta(NBResource.Meta):
queryset = contact_models.Email.objects.all()
resource_name = 'client/contact/email'
filtering = {
'contact': ALL_WITH_RELATIONS,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment