WebUI: Implement removing categories

This commit is contained in:
buinsky 2016-01-21 16:42:20 +03:00
parent a4dca52617
commit 50f2437ac3
6 changed files with 35 additions and 1 deletions

View file

@ -357,6 +357,18 @@ initializeWindows = function() {
updateMainData();
};
removeCategoryFN = function (categoryHash) {
var categoryName = category_list[categoryHash].name;
new Request({
url: 'command/removeCategory',
method: 'post',
data: {
category: categoryName
}
}).send();
setCategoryFilter(CATEGORIES_ALL);
};
['pauseAll', 'resumeAll'].each(function(item) {
addClickEvent(item, function(e) {
new Event(e).stop();