mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-03 06:58:42 +00:00
add a method that returns both the available and enabled plugins to reduce the number of AJAX calls required
This commit is contained in:
parent
443b4854b4
commit
f831cdce9a
1 changed files with 7 additions and 0 deletions
|
@ -781,6 +781,13 @@ class WebApi(JSONComponent):
|
||||||
config[key] = config[key].encode("utf8")
|
config[key] = config[key].encode("utf8")
|
||||||
web_config[key] = config[key]
|
web_config[key] = config[key]
|
||||||
|
|
||||||
|
@export
|
||||||
|
def get_plugins(self):
|
||||||
|
return {
|
||||||
|
"enabled_plugins": component.get("Web.PluginManager").plugins.keys(),
|
||||||
|
"available_plugins": component.get("Web.PluginManager").available_plugins
|
||||||
|
}
|
||||||
|
|
||||||
@export
|
@export
|
||||||
def get_plugin_info(self, name):
|
def get_plugin_info(self, name):
|
||||||
return component.get("Web.PluginManager").get_plugin_info(name)
|
return component.get("Web.PluginManager").get_plugin_info(name)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue