예제 #1
0
 class Meta(CommonMetaApi):
     paginator_class = CrossSiteXHRPaginator
     filtering = CommonMetaApi.filtering
     filtering.update({'video_type': ALL})
     queryset = Video.objects.distinct().order_by('-date')
     resource_name = 'videos'
     authentication = MultiAuthentication(SessionAuthentication(),
                                          GeonodeApiKeyAuthentication())
예제 #2
0
 class Meta:
     resource_name = "maplayers"
     queryset = MapLayer.objects.all().distinct()
     filtering = {
         'id': ALL,
         'name': ALL,
         'map': ALL_WITH_RELATIONS
     }
     authorization = GeoNodeAuthorization()
     authentication = MultiAuthentication(
         SessionAuthentication(), GeonodeApiKeyAuthentication())
예제 #3
0
파일: rest.py 프로젝트: Chirag19/cartoview
 class Meta:
     resource_name = "maplayers"
     queryset = MapLayer.objects.distinct()
     filtering = {
         'id': ALL,
         'name': ALL,
         'map': ALL_WITH_RELATIONS,
         'fixed': ALL,
         'local': ALL
     }
     authentication = MultiAuthentication(SessionAuthentication(),
                                          GeonodeApiKeyAuthentication())
예제 #4
0
 class Meta:
     resource_name = 'all_resources'
     queryset = ResourceBase.objects.distinct()
     fields = ['id', 'title', 'abstract',
               'type', 'featured', 'owner__username','app', 'owner', 'urls', 'thumbnail_url']
     filtering = {
         'id': ALL,
         'title': ALL,
         'abstract': ALL,
         'featured': ALL,
         'owner': ALL_WITH_RELATIONS
     }
     authorization = GeoNodeAuthorization()
     authentication = MultiAuthentication(
         SessionAuthentication(), GeonodeApiKeyAuthentication())
예제 #5
0
파일: rest.py 프로젝트: nstoykov/cartoview
 class Meta:
     resource_name = "attributes"
     queryset = Attribute.objects.distinct()
     fields = ['id', 'attribute', 'description',
               'attribute_label', 'attribute_type', 'visible']
     filtering = {
         'id': ALL,
         'attribute': ALL,
         'description': ALL,
         'attribute_label': ALL,
         'attribute_type': ALL,
         'visible': ALL,
         'layer': ALL_WITH_RELATIONS
     }
     authentication = MultiAuthentication(
         SessionAuthentication(), GeonodeApiKeyAuthentication())