diff --git a/apps/wpm/services_2.py b/apps/wpm/services_2.py index 5911613f..3f767583 100644 --- a/apps/wpm/services_2.py +++ b/apps/wpm/services_2.py @@ -6,6 +6,8 @@ from apps.qm.models import FtestWork from django.utils import timezone from datetime import datetime from server.conf import BASE_PROJECT_CODE +import json +from django.core.serializers.json import DjangoJSONEncoder def get_alldata_with_batch_and_store(batch: str): """ @@ -24,7 +26,7 @@ def get_alldata_with_batch_and_store(batch: str): "last_time": last_time }) bobj.last_time = last_time - bobj.data = data + bobj.data = json.loads(json.dumps(data, cls=DjangoJSONEncoder)) bobj.save() def get_alldata_with_batch_gx(batch: str):