serializer.py 248 B

12345678910
  1. from rest_framework import serializers
  2. from workreport.models import DailyReport
  3. class DailyReportSerializer(serializers.ModelSerializer):
  4. class Meta:
  5. model = DailyReport
  6. # 全部都包含的意思
  7. fields = '__all__'