Browse Source

Follow project coding style. Issue #2192.

adaptive-webui-19844
Gabriele 10 years ago
parent
commit
9bd24a1408
  1. 20
      src/webui/www/public/downloadlimit.html
  2. 20
      src/webui/www/public/uploadlimit.html

20
src/webui/www/public/downloadlimit.html

@ -23,18 +23,26 @@ @@ -23,18 +23,26 @@
var hash = new URI().getData('hash');
setDlLimit = function() {
var limit = $("dllimitUpdatevalue").value.toInt() * 1024;
if(hash == "global") {
new Request({url: 'command/setGlobalDlLimit',
if (hash == "global") {
new Request({
url: 'command/setGlobalDlLimit',
method: 'post',
data: {'limit': limit},
data: {
'limit': limit
},
onComplete: function() {
window.parent.closeWindows();
}
}).send();
} else {
new Request({url: 'command/setTorrentDlLimit',
}
else {
new Request({
url: 'command/setTorrentDlLimit',
method: 'post',
data: {'hash': hash, 'limit': limit},
data: {
'hash': hash,
'limit': limit
},
onComplete: function() {
window.parent.closeWindows();
}

20
src/webui/www/public/uploadlimit.html

@ -23,18 +23,26 @@ @@ -23,18 +23,26 @@
var hash = new URI().getData('hash');
setUpLimit = function() {
var limit = $("uplimitUpdatevalue").value.toInt() * 1024;
if(hash == "global") {
new Request({url: 'command/setGlobalUpLimit',
if (hash == "global") {
new Request({
url: 'command/setGlobalUpLimit',
method: 'post',
data: {'limit': limit},
data: {
'limit': limit
},
onComplete: function() {
window.parent.closeWindows();
}
}).send();
}else {
new Request({url: 'command/setTorrentUpLimit',
}
else {
new Request({
url: 'command/setTorrentUpLimit',
method: 'post',
data: {'hash': hash, 'limit': limit},
data: {
'hash': hash,
'limit': limit
},
onComplete: function() {
window.parent.closeWindows();
}

Loading…
Cancel
Save