1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-12-16 11:37:58 +02:00
Sonarr/UI/Commands/CommandController.js

17 lines
394 B
JavaScript
Raw Normal View History

2013-05-12 02:39:32 +03:00
"use strict";
define(['app'], function () {
2013-06-13 05:55:11 +03:00
NzbDrone.Commands.Execute = function (name, properties) {
var data = { command: name };
2013-06-13 18:21:38 +03:00
if (!properties) {
2013-06-13 05:55:11 +03:00
$.extend(data, properties);
}
2013-05-12 02:39:32 +03:00
return $.ajax({
type: 'POST',
url : NzbDrone.Constants.ApiRoot + '/command',
2013-06-13 05:55:11 +03:00
data: JSON.stringify(data)
2013-05-12 02:39:32 +03:00
});
};
});