|
12 | 12 | from django.http import HttpRequest |
13 | 13 | from edx_api_doc_tools import schema_for |
14 | 14 | from organizations.models import Organization |
| 15 | +from organizations.serializers import OrganizationSerializer |
15 | 16 | from rest_framework import filters, generics, status |
16 | 17 | from rest_framework.response import Response |
17 | 18 | from rest_framework.views import APIView |
|
34 | 35 | ListRolesWithScopeResponseSerializer, |
35 | 36 | ListRolesWithScopeSerializer, |
36 | 37 | ListUsersInRoleWithScopeSerializer, |
37 | | - OrganizationSerializer, |
38 | 38 | PermissionValidationResponseSerializer, |
39 | 39 | PermissionValidationSerializer, |
40 | 40 | RemoveUsersFromRoleWithScopeSerializer, |
@@ -507,14 +507,19 @@ class OrgsAPIView(generics.ListAPIView): |
507 | 507 | "results": [ |
508 | 508 | { |
509 | 509 | "id": 1, |
510 | | - "name": "edX", |
511 | | - "short_name": "edx" |
| 510 | + "created": "2026-04-02T19:30:36.779095Z", |
| 511 | + "modified": "2026-04-02T19:30:36.779095Z", |
| 512 | + "name": "OpenedX", |
| 513 | + "short_name": "OpenedX", |
| 514 | + "description": "", |
| 515 | + "logo": null, |
| 516 | + "active": true |
512 | 517 | } |
513 | 518 | ] |
514 | 519 | } |
515 | 520 | """ |
516 | 521 |
|
517 | | - queryset = Organization.objects.order_by("name") |
| 522 | + queryset = Organization.objects.filter(active=True).order_by("name") |
518 | 523 | serializer_class = OrganizationSerializer |
519 | 524 | pagination_class = AuthZAPIViewPagination |
520 | 525 | filter_backends = [filters.SearchFilter] |
|
0 commit comments