class Meta: queryset = GroupCategory.objects.all() allowed_methods = ['get'] include_resource_uri = False filtering = {'slug': ALL, 'name': ALL} ordering = ['name'] authorization = ApiLockdownAuthorization()
class Meta: queryset = TopicCategory.objects.all() resource_name = 'categories' allowed_methods = ['get'] filtering = { 'identifier': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = HierarchicalKeyword.objects.all().order_by('name') resource_name = 'keywords' allowed_methods = ['get'] filtering = { 'slug': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = Group.objects.exclude(groupprofile=None) resource_name = 'groups' allowed_methods = ['get'] filtering = { 'name': ALL, 'group_profile': ALL_WITH_RELATIONS, } ordering = ['name', 'last_modified'] authorization = ApiLockdownAuthorization()
class Meta: queryset = Region.objects.all().order_by('name') resource_name = 'regions' allowed_methods = ['get'] filtering = { 'name': ALL, 'code': ALL, } if settings.API_INCLUDE_REGIONS_COUNT: serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = DataType.objects.all().order_by('gn_description') resource_name = 'datatype' allowed_methods = ['get'] excludes = ['is_choice', 'description_en', 'gn_description_en'] filtering = { 'identifier': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = GroupProfile.objects.all() resource_name = 'group_profile' allowed_methods = ['get'] filtering = { 'title': ALL, 'slug': ALL, 'categories': ALL_WITH_RELATIONS, } ordering = ['title', 'last_modified'] authorization = ApiLockdownAuthorization()
class Meta: #print("TESTE NA API EMBRAPATAGRESOURCE3") queryset = Embrapa_Keywords.objects.all().order_by('name') #print(queryset) resource_name = 'embrapa_keywords' allowed_methods = ['get'] filtering = { 'slug': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = get_user_model().objects.exclude(username='******') resource_name = 'owners' allowed_methods = ['get'] ordering = ['username', 'date_joined'] excludes = ['is_staff', 'password', 'is_superuser', 'is_active', 'last_login'] filtering = { 'username': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()
class Meta: queryset = ThesaurusKeyword.objects \ .all() \ .order_by('alt_label') \ .select_related('thesaurus') resource_name = 'thesaurus/keywords' allowed_methods = ['get'] filtering = { 'id': ALL, 'alt_label': ALL, 'thesaurus': ALL, } serializer = CountJSONSerializer() authorization = ApiLockdownAuthorization()