mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-16 02:03:07 -07:00
WebUI: Implement start torrents by category
This commit is contained in:
parent
24584503d9
commit
f7833c9f0c
4 changed files with 31 additions and 0 deletions
|
@ -385,6 +385,22 @@ initializeWindows = function() {
|
|||
setCategoryFilter(CATEGORIES_ALL);
|
||||
};
|
||||
|
||||
startTorrentsByCategoryFN = function (categoryHash) {
|
||||
var h = torrentsTable.getFilteredTorrentsHashes('all', categoryHash);
|
||||
if (h.length) {
|
||||
h.each(function (hash, index) {
|
||||
new Request({
|
||||
url: 'command/resume',
|
||||
method: 'post',
|
||||
data: {
|
||||
hash: hash
|
||||
}
|
||||
}).send();
|
||||
});
|
||||
updateMainData();
|
||||
}
|
||||
};
|
||||
|
||||
['pauseAll', 'resumeAll'].each(function(item) {
|
||||
addClickEvent(item, function(e) {
|
||||
new Event(e).stop();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue