📜  serializers.py 包含所有字段 - Python 代码示例

📅  最后修改于: 2022-03-11 14:47:10.931000             🧑  作者: Mango

代码示例1
# Include all fields in the Order model in the Serializer
class OrderSerializer(serializers.ModelSerializer):
    class Meta:
        model = Order
        fields = '__all__'