dnmapper/bgpdata/api.py

20 lines
542 B
Python
Raw Normal View History

2015-03-27 15:33:54 +01:00
#from tastypie.resources import ModelResource, ALL_WITH_RELATIONS
#from tastypie import fields
#from bgpdata.models import AS, CrawlRun
#
#class ASResource(ModelResource):
# crawl = fields.ForeignKey("bgpdata.api.CrawlResource", "crawl")
# class Meta:
# list_allowed_methods = ['get']
# detail_allowed_methods = ['get']
# filtering = {'crawl': ALL_WITH_RELATIONS}
#
# queryset = AS.objects.all()
# resource_name = "as"
#
#class CrawlResource(ModelResource):
# class Meta:
# queryset = CrawlRun.objects.all()
# resource_name = "crawl"