From 7939ef34b0363a2b168154699bdf66198a4a29eb Mon Sep 17 00:00:00 2001 From: Michael Bai Date: Tue, 14 Sep 2021 17:23:37 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=91=8A=E8=AD=A6=E4=B8=BB=E9=A2=98=E6=9B=BF=E6=8D=A2
?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/notifications/notifications.py | 1 - apps/ops/notifications.py | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/notifications/notifications.py b/apps/notifications/notifications.py index ab2f25492..d4456ac90 100644 --- a/apps/notifications/notifications.py +++ b/apps/notifications/notifications.py @@ -164,7 +164,6 @@ class SystemMessage(Message): self.send_msg(users, receive_backends) - @classmethod def post_insert_to_db(cls, subscription: SystemMsgSubscription): pass diff --git a/apps/ops/notifications.py b/apps/ops/notifications.py index a8c659108..ac5973596 100644 --- a/apps/ops/notifications.py +++ b/apps/ops/notifications.py @@ -18,8 +18,9 @@ class ServerPerformanceMessage(SystemMessage): self._msg = msg def get_common_msg(self): + subject = self._msg[:80] return { - 'subject': self._msg[:80], + 'subject': subject.replace('
', '; '), 'message': self._msg }