mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-30 20:28:05 -06:00
committed by
Vladimir Golovnev (Glassez)
parent
a721540e6c
commit
f4e6b515c2
@@ -177,12 +177,12 @@
|
||||
<div style="margin-left: 40px; margin-bottom: 5px;">
|
||||
<input type="checkbox" id="setTotalMinutes" class="shareLimitInput" onclick="enableInputBoxes()">
|
||||
<label id="totalMinutesLabel" for="setTotalMinutes">QBT_TR(total minutes)QBT_TR[CONTEXT=UpDownRatioDialog]</label>
|
||||
<input type="number" id="totalMinutes" value="0" step="1" min="0" max="525600" class="shareLimitInput" aria-labelledby="totalMinutesLabel">
|
||||
<input type="number" id="totalMinutes" value="0" step="1" min="0" class="shareLimitInput" aria-labelledby="totalMinutesLabel">
|
||||
</div>
|
||||
<div style="margin-left: 40px; margin-bottom: 5px;">
|
||||
<input type="checkbox" id="setInactiveMinutes" class="shareLimitInput" onclick="enableInputBoxes()">
|
||||
<label id="inactiveMinutesLabel" for="setInactiveMinutes">QBT_TR(inactive minutes)QBT_TR[CONTEXT=UpDownRatioDialog]</label>
|
||||
<input type="number" id="inactiveMinutes" value="0" step="1" min="0" max="525600" class="shareLimitInput" aria-labelledby="inactiveMinutesLabel">
|
||||
<input type="number" id="inactiveMinutes" value="0" step="1" min="0" class="shareLimitInput" aria-labelledby="inactiveMinutesLabel">
|
||||
</div>
|
||||
<div style="text-align: center; padding-top: 10px;">
|
||||
<input type="button" value="QBT_TR(Save)QBT_TR[CONTEXT=HttpServer]" id="save">
|
||||
|
||||
@@ -2887,11 +2887,11 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
settings["max_ratio_enabled"] = $("max_ratio_checkbox").checked;
|
||||
settings["max_ratio"] = max_ratio;
|
||||
|
||||
let max_seeding_time = -1;
|
||||
if ($("max_seeding_time_checkbox").checked) {
|
||||
max_seeding_time = Number($("max_seeding_time_value").value);
|
||||
if (isNaN(max_seeding_time) || (max_seeding_time < 0) || (max_seeding_time > 525600)) {
|
||||
alert("QBT_TR(Seeding time limit must be between 0 and 525600 minutes.)QBT_TR[CONTEXT=HttpServer]");
|
||||
let maxSeedingTime = -1;
|
||||
if (document.getElementById("maxSeedingTimeCheckbox").checked) {
|
||||
maxSeedingTime = Number(document.getElementById("maxSeedingTimeValue").value);
|
||||
if (Number.isNaN(maxSeedingTime) || (maxSeedingTime < 0)) {
|
||||
alert("QBT_TR(Seeding time limit must not have a negative value.)QBT_TR[CONTEXT=HttpServer]");
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -2899,11 +2899,11 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
settings["max_seeding_time"] = max_seeding_time;
|
||||
settings["max_ratio_act"] = Number($("max_ratio_act").value);
|
||||
|
||||
let max_inactive_seeding_time = -1;
|
||||
if ($("max_inactive_seeding_time_checkbox").checked) {
|
||||
max_inactive_seeding_time = Number($("max_inactive_seeding_time_value").value);
|
||||
if (isNaN(max_inactive_seeding_time) || (max_inactive_seeding_time < 0) || (max_inactive_seeding_time > 525600)) {
|
||||
alert("QBT_TR(Seeding time limit must be between 0 and 525600 minutes.)QBT_TR[CONTEXT=HttpServer]");
|
||||
let maxInactiveSeedingTime = -1;
|
||||
if (document.getElementById("maxInactiveSeedingTimeCheckbox").checked) {
|
||||
maxInactiveSeedingTime = Number(document.getElementById("maxInactiveSeedingTimeValue").value);
|
||||
if (Number.isNaN(maxInactiveSeedingTime) || (maxInactiveSeedingTime < 0)) {
|
||||
alert("QBT_TR(Seeding time limit must not have a negative value.)QBT_TR[CONTEXT=HttpServer]");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user