Skip to content

Commit ab8d018

Browse files
committed
Provide a document's rfc number (if any) as part of the document fields exposed in the json api.
- Legacy-Id: 9923
1 parent faecc69 commit ab8d018

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

ietf/doc/resources.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Autogenerated by the mkresources management command 2014-12-14 19:50
22
from tastypie.resources import ModelResource
3-
from tastypie.fields import ToOneField, ToManyField
3+
from tastypie.fields import ToOneField, ToManyField, CharField
44
from tastypie.constants import ALL, ALL_WITH_RELATIONS
55

66
from ietf import api
@@ -86,6 +86,7 @@ class DocumentResource(ModelResource):
8686
states = ToManyField(StateResource, 'states', null=True)
8787
tags = ToManyField(DocTagNameResource, 'tags', null=True)
8888
authors = ToManyField(EmailResource, 'authors', null=True)
89+
rfc = CharField(attribute='rfc_number', null=True)
8990
class Meta:
9091
queryset = Document.objects.all()
9192
#resource_name = 'document'

0 commit comments

Comments
 (0)