Django 调试时提示: In order to allow non-dict objects to be serialized

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/xm_csdn/article/details/78247286

return JsonResponse(result)

改为:

return JsonResponse(result, safe=False)

猜你喜欢

转载自blog.csdn.net/xm_csdn/article/details/78247286
今日推荐