This commit is contained in:
MaysWind 2016-06-04 17:10:54 +08:00
parent 080a50a772
commit f14e38d9c5

View file

@ -81,7 +81,11 @@
ariaNgCommonService.confirm('Confirm Remove', 'Are you sure you want to remove the selected task?', 'warning', function () {
$rootScope.loadPromise = aria2TaskService.removeTasks(tasks, function (result) {
if ($location.path() == '/stopped') {
$route.reload();
} else {
$location.path('/stopped');
}
});
});
};
@ -89,7 +93,11 @@
$scope.clearStoppedTasks = function () {
ariaNgCommonService.confirm('Confirm Clear', 'Are you sure you want to clear stopped tasks?', 'warning', function () {
$rootScope.loadPromise = aria2TaskService.clearStoppedTasks(function (result) {
if ($location.path() == '/stopped') {
$route.reload();
} else {
$location.path('/stopped');
}
});
});
};