From 3a1b6483f05c5bd084967c13b236454861804ca1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E5=89=8D=E6=98=8E?= <909355014@qq.com> Date: Fri, 15 Jul 2022 10:38:06 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E6=B5=81bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/wf/services.py | 2 ++ apps/wf/views.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/wf/services.py b/apps/wf/services.py index f28714df..d6d46738 100755 --- a/apps/wf/services.py +++ b/apps/wf/services.py @@ -206,6 +206,8 @@ class WfService(object): if len(destination_participant) == 1: # 如果只有一个人 destination_participant_type = State.PARTICIPANT_TYPE_PERSONAL destination_participant = destination_participant[0] + elif destination_participant_type == State.PARTICIPANT_TYPE_ROBOT: + pass else: destination_participant_type = State.PARTICIPANT_TYPE_PERSONAL if destination_participant_type == State.PARTICIPANT_TYPE_MULTI: diff --git a/apps/wf/views.py b/apps/wf/views.py index bd939237..45c7b7b1 100755 --- a/apps/wf/views.py +++ b/apps/wf/views.py @@ -441,7 +441,7 @@ class TicketViewSet(CreateUpdateCustomMixin, CreateModelMixin, ListModelMixin, R ticket = self.get_object() if not ticket.script_run_last_result: ticket.script_run_last_result = True - run_task(ticket.id) + run_task.delay(ticket.id) return Response()