mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-02 05:38:06 -06:00
60 lines
2.3 KiB
HTML
60 lines
2.3 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="${LANG}" class="dark">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>QBT_TR(Deletion confirmation)QBT_TR[CONTEXT=RSSWidget]</title>
|
|
<link rel="stylesheet" href="css/style.css?v=${CACHEID}" type="text/css">
|
|
<script defer src="scripts/localpreferences.js?v=${CACHEID}"></script>
|
|
<script defer src="scripts/color-scheme.js?v=${CACHEID}"></script>
|
|
<script>
|
|
"use strict";
|
|
|
|
window.addEventListener("DOMContentLoaded", (event) => {
|
|
document.getElementById("cancelBtn").focus();
|
|
document.getElementById("cancelBtn").addEventListener("click", (e) => {
|
|
e.preventDefault();
|
|
e.stopPropagation();
|
|
window.parent.qBittorrent.Client.closeFrameWindow(window);
|
|
});
|
|
document.getElementById("confirmBtn").addEventListener("click", (e) => {
|
|
e.preventDefault();
|
|
e.stopPropagation();
|
|
|
|
let completionCount = 0;
|
|
const paths = new URLSearchParams(window.location.search).get("paths").split("|");
|
|
for (const path of paths) {
|
|
fetch("api/v2/rss/removeItem", {
|
|
method: "POST",
|
|
body: new URLSearchParams({
|
|
path: decodeURIComponent(path)
|
|
})
|
|
})
|
|
.then((response) => {
|
|
if (!response.ok)
|
|
return;
|
|
|
|
++completionCount;
|
|
if (completionCount === paths.length) {
|
|
window.parent.qBittorrent.Rss.updateRssFeedList();
|
|
window.parent.qBittorrent.Client.closeFrameWindow(window);
|
|
}
|
|
});
|
|
}
|
|
});
|
|
});
|
|
</script>
|
|
</head>
|
|
|
|
<body>
|
|
<div style="padding: 10px 10px 0px 10px;">
|
|
<p>QBT_TR(Are you sure you want to delete the selected RSS feeds?)QBT_TR[CONTEXT=RSSWidget]</p>
|
|
<div style="text-align: right;">
|
|
<input type="button" id="cancelBtn" value="QBT_TR(No)QBT_TR[CONTEXT=MainWindow]">
|
|
<input type="button" id="confirmBtn" value="QBT_TR(Yes)QBT_TR[CONTEXT=MainWindow]">
|
|
</div>
|
|
</div>
|
|
</body>
|
|
|
|
</html>
|