From a9c16c4a9d6971bee571095389d9a77a3d874bcd Mon Sep 17 00:00:00 2001 From: caoqianming Date: Mon, 18 Dec 2023 11:12:33 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=97=A5=E5=BF=97=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E5=92=8C=E6=92=A4=E5=9B=9E=E8=BF=94=E5=9B=9E=E5=BA=8F=E5=88=97?= =?UTF-8?q?=E5=8C=96=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/wpm/views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/wpm/views.py b/apps/wpm/views.py index c4738dd9..a2b9557c 100644 --- a/apps/wpm/views.py +++ b/apps/wpm/views.py @@ -176,7 +176,7 @@ class MlogViewSet(CustomModelViewSet): vdata_new = MlogSerializer(ins).data create_auditlog('submit', ins, vdata_new, vdata_old, now, self.request.user) - return Response() + return Response(MlogSerializer(instance=ins).data) @action(methods=['post'], detail=True, perms_map={'post': 'mlog.submit'}, serializer_class=MlogRevertSerializer) @transaction.atomic @@ -197,7 +197,7 @@ class MlogViewSet(CustomModelViewSet): update_mtask(ins.mtask) create_auditlog('revert', ins, {}, {}, now, user, request.data.get('change_reason', '')) - return Response() + return Response(MlogSerializer(instance=ins).data) @action(methods=['post'], detail=False, perms_map={'post': '*'}, serializer_class=MlogRelatedSerializer) @transaction.atomic