JSON Serializing Django Models with simplejson

后端 未结 3 444
一整个雨季
一整个雨季 2020-12-07 10:21

I\'d like to use simplejson to serialize a Django model. Django\'s serializer doesn\'t support dictionaries... and simplejson doesn\'t support Django Querysets. This is quit

3条回答
  •  眼角桃花
    2020-12-07 10:54

    A really flexible way to serialize most structures in django is to use the serializer class found here

提交回复
热议问题