mirror of
https://github.com/Carve/qbittorrent-webui-cjratliff.com.git
synced 2025-02-28 23:50:57 +01:00
Set confirmTorrentDeletion to checked by default
This commit is contained in:
parent
8890cc004d
commit
f84ec827f0
@ -743,7 +743,7 @@
|
|||||||
deleteVisibleTorrentsFN = function() {
|
deleteVisibleTorrentsFN = function() {
|
||||||
const hashes = torrentsTable.getFilteredTorrentsHashes(selectedStatus, selectedCategory, selectedTag, selectedTracker);
|
const hashes = torrentsTable.getFilteredTorrentsHashes(selectedStatus, selectedCategory, selectedTag, selectedTracker);
|
||||||
if (hashes.length > 0) {
|
if (hashes.length > 0) {
|
||||||
if (window.qBittorrent.Cache.preferences.get().confirm_torrent_deletion) {
|
// if (window.qBittorrent.Cache.preferences.get().confirm_torrent_deletion) {
|
||||||
new MochaUI.Modal({
|
new MochaUI.Modal({
|
||||||
...window.qBittorrent.Dialog.baseModalOptions,
|
...window.qBittorrent.Dialog.baseModalOptions,
|
||||||
id: "confirmDeletionPage",
|
id: "confirmDeletionPage",
|
||||||
@ -759,24 +759,24 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else {
|
// else {
|
||||||
new Request({
|
// new Request({
|
||||||
url: "api/v2/torrents/delete",
|
// url: "api/v2/torrents/delete",
|
||||||
method: "post",
|
// method: "post",
|
||||||
data: {
|
// data: {
|
||||||
hashes: hashes.join("|"),
|
// hashes: hashes.join("|"),
|
||||||
deleteFiles: false,
|
// deleteFiles: false,
|
||||||
},
|
// },
|
||||||
onSuccess: () => {
|
// onSuccess: () => {
|
||||||
torrentsTable.deselectAll();
|
// torrentsTable.deselectAll();
|
||||||
updateMainData();
|
// updateMainData();
|
||||||
updatePropertiesPanel();
|
// updatePropertiesPanel();
|
||||||
},
|
// },
|
||||||
onFailure: () => {
|
// onFailure: () => {
|
||||||
alert("Unable to delete torrents.");
|
// alert("Unable to delete torrents.");
|
||||||
}
|
// }
|
||||||
}).send();
|
// }).send();
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
<fieldset class="settings">
|
<fieldset class="settings">
|
||||||
<legend>Transfer list</legend>
|
<legend>Transfer list</legend>
|
||||||
<div class="formRow" style="margin-bottom: 3px;" title="Shows a confirmation dialog upon torrent deletion">
|
<div class="formRow" style="margin-bottom: 3px;" title="Shows a confirmation dialog upon torrent deletion">
|
||||||
<input type="checkbox" id="confirmTorrentDeletion">
|
<input type="checkbox" id="confirmTorrentDeletion" checked>
|
||||||
<label for="confirmTorrentDeletion">Confirm when deleting torrents</label>
|
<label for="confirmTorrentDeletion">Confirm when deleting torrents</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="formRow" style="margin-bottom: 3px;">
|
<div class="formRow" style="margin-bottom: 3px;">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user