阅读背景:

在REST框架中返回字典而不是数组

来源:互联网 

I am converting a set of existing APIs from tastypie to REST framework. By default when doing list APIs, tastypie returns a dictionary containing the list of objects and a dictionary of metadata, where REST framework just returns an array of objects. For example, I have a model called Site. Tastypie returns a dictionary that looks like I am converting a set of existing APIs from tas




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: