WebUI/WebAPI: Support downloading torrent via search plugin

This adds support for downloading a torrent via a search plugin's `download_torrent` function. This primarily affects torrents that use a private tracker requiring a login.

Closes #18334.
PR #23163.
This commit is contained in:
Thomas (Tom) Piccirello
2025-09-05 05:24:15 -07:00
committed by GitHub
parent becfd19e34
commit 4fa433a728
8 changed files with 125 additions and 35 deletions

View File

@@ -561,8 +561,8 @@ window.qBittorrent.Search ??= (() => {
const downloadSearchTorrent = () => {
for (const rowID of searchResultsTable.selectedRowsIds()) {
const { fileName, fileUrl } = searchResultsTable.getRow(rowID).full_data;
qBittorrent.Client.createAddTorrentWindow(fileName, fileUrl);
const { engineName, fileName, fileUrl } = searchResultsTable.getRow(rowID).full_data;
qBittorrent.Client.createAddTorrentWindow(fileName, fileUrl, undefined, engineName);
}
};