mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-16 15:28:38 +00:00
perf: Remove applets, no longer display remote application connection methods
This commit is contained in:
@@ -102,6 +102,8 @@ class AppletMethod:
|
||||
|
||||
methods = defaultdict(list)
|
||||
has_applet_hosts = AppletHost.objects.filter(is_active=True).exists()
|
||||
if not has_applet_hosts:
|
||||
return methods
|
||||
applets = Applet.objects.filter(is_active=True)
|
||||
for applet in applets:
|
||||
for protocol in applet.protocols:
|
||||
@@ -110,7 +112,7 @@ class AppletMethod:
|
||||
'label': applet.display_name,
|
||||
'type': 'applet',
|
||||
'icon': applet.icon,
|
||||
'disabled': not applet.is_active or not has_applet_hosts,
|
||||
'disabled': not applet.is_active,
|
||||
})
|
||||
return methods
|
||||
|
||||
|
Reference in New Issue
Block a user