[SOLVED] How to show subcategories under category type

Issue I need to get the child list under the parent list as a group. class ServiceSerializer(serializers.ModelSerializer): cleaning_type = serializers.CharField(source=’cleaning_type.cleaning_type_name’) class Meta: model = Service fields = (‘id’, ‘cleaning_type’,’service_name’) class ServiceTypeViewSet(ModelViewSet): serializer_class = ServiceSerializer http_method_names = ["get"] queryset = Service.objects.all()

Continue reading