From 1712a9a1041cfa09fdf840b4a4520b3c0dfa435a Mon Sep 17 00:00:00 2001 From: feng <1304903146@qq.com> Date: Wed, 21 Aug 2024 11:28:39 +0800 Subject: [PATCH] perf: No permission to test asset connectivity --- apps/assets/api/asset/asset.py | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/assets/api/asset/asset.py b/apps/assets/api/asset/asset.py index f7e088319..799435c31 100644 --- a/apps/assets/api/asset/asset.py +++ b/apps/assets/api/asset/asset.py @@ -292,6 +292,7 @@ class AssetsTaskCreateApi(AssetsTaskMixin, generics.CreateAPIView): def check_permissions(self, request): action_perm_require = { "refresh": "assets.refresh_assethardwareinfo", + "test": "assets.test_assetconnectivity", } _action = request.data.get("action") perm_required = action_perm_require.get(_action)