示例#1
0
文件: views.py 项目: vidtsin/pythoncw
def get_categories(request):
    queryset = Category.objects.all()
    serialized = CategorySerializer(queryset, many=True)
    return Response(serialized.data)