From 3334f79e84d5c1009af58718b4a7dfacafe963fe Mon Sep 17 00:00:00 2001 From: jiangweidong Date: Sun, 19 Feb 2023 19:17:12 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=E8=A7=A3=E5=86=B3=E8=B7=A8=E7=BB=84?= =?UTF-8?q?=E7=BB=87=E8=B5=84=E6=BA=90=E7=9A=84Activty=E5=9C=A8=E5=85=B6?= =?UTF-8?q?=E4=BB=96=E7=BB=84=E7=BB=87=E4=B8=8B404=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/audits/api.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/audits/api.py b/apps/audits/api.py index d1915206a..2b2e0f9ff 100644 --- a/apps/audits/api.py +++ b/apps/audits/api.py @@ -12,7 +12,6 @@ from common.api import JMSGenericViewSet from common.drf.filters import DatetimeRangeFilter from common.plugins.es import QuerySet as ESQuerySet from orgs.mixins.api import OrgGenericViewSet, OrgBulkModelViewSet -from orgs.models import Organization from orgs.utils import current_org, tmp_to_root_org from users.models import User from .backends import TYPE_ENGINE_MAPPING @@ -149,9 +148,7 @@ class OperateLogViewSet(RetrieveModelMixin, ListModelMixin, OrgGenericViewSet): def get_queryset(self): with tmp_to_root_org(): - qs = OperateLog.objects.filter( - Q(org_id=current_org.id) | Q(org_id=Organization.SYSTEM_ID) - ) + qs = OperateLog.objects.all() es_config = settings.OPERATE_LOG_ELASTICSEARCH_CONFIG if es_config: engine_mod = import_module(TYPE_ENGINE_MAPPING['es']) From 485454f9c61846c82248d3915708eb72678f8642 Mon Sep 17 00:00:00 2001 From: jiangweidong Date: Sun, 19 Feb 2023 19:49:06 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E8=A7=A3=E5=86=B3JobLog=E8=A1=A8?= =?UTF-8?q?=E4=BE=9D=E8=B5=96=E9=A1=BA=E5=BA=8F=E4=B8=8D=E5=AF=B9=EF=BC=8C?= =?UTF-8?q?=E5=AF=BC=E8=87=B4=E4=BB=8E=E6=96=B0=E8=BF=81=E7=A7=BB=E5=A4=B1?= =?UTF-8?q?=E8=B4=A5=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/audits/migrations/0021_auto_20230207_0857.py | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/audits/migrations/0021_auto_20230207_0857.py b/apps/audits/migrations/0021_auto_20230207_0857.py index 6913d21c7..4e66c63f0 100644 --- a/apps/audits/migrations/0021_auto_20230207_0857.py +++ b/apps/audits/migrations/0021_auto_20230207_0857.py @@ -8,6 +8,7 @@ class Migration(migrations.Migration): dependencies = [ ('audits', '0020_auto_20230117_1004'), + ('ops', '0023_auto_20220912_0021'), ] operations = [