mirror of
https://github.com/VueTorrent/VueTorrent.git
synced 2025-03-14 12:10:18 +03:00
feat: auto install search plugins when none installed
This commit is contained in:
parent
f9567f930e
commit
abc5457882
2 changed files with 9 additions and 0 deletions
|
@ -64,6 +64,11 @@ export default {
|
|||
togglePlugin(plugin) {
|
||||
qbit.enableSearchPlugin([plugin.name], plugin.enabled)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if(!this.searchPlugins.length) {
|
||||
qbit.updateSearchPlugins()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
|
@ -355,6 +355,10 @@ class Qbit {
|
|||
.then(res => res.data)
|
||||
}
|
||||
|
||||
updateSearchPlugins() {
|
||||
return this.execute('post', '/search/updatePlugins')
|
||||
}
|
||||
|
||||
enableSearchPlugin(plugins, enable) {
|
||||
const params = {
|
||||
names: plugins.join('|'),
|
||||
|
|
Loading…
Add table
Reference in a new issue