From eb74d13059a3d277373ceb1af58b07c9db878b2d Mon Sep 17 00:00:00 2001 From: xinwen Date: Tue, 12 May 2020 17:09:36 +0800 Subject: [PATCH] =?UTF-8?q?[Update]=20Asset=20filter=20=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=20platform=5F=5Fbase=20=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/assets/api/asset.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/assets/api/asset.py b/apps/assets/api/asset.py index 4bafe2fc2..0d7a42454 100644 --- a/apps/assets/api/asset.py +++ b/apps/assets/api/asset.py @@ -33,7 +33,7 @@ class AssetViewSet(OrgBulkModelViewSet): API endpoint that allows Asset to be viewed or edited. """ model = Asset - filter_fields = ("hostname", "ip", "systemuser__id", "admin_user__id", "platform__name") + filter_fields = ("hostname", "ip", "systemuser__id", "admin_user__id", "platform__base") search_fields = ("hostname", "ip") ordering_fields = ("hostname", "ip", "port", "cpu_cores") serializer_classes = {