admin: add the ability to deep sync from interface

This commit is contained in:
nemunaire 2018-12-05 06:21:32 +01:00
commit 6aacce23ca
2 changed files with 21 additions and 2 deletions

View file

@ -453,6 +453,20 @@ angular.module("FICApp")
});
}
};
$scope.deepSyncInProgress = false;
$scope.deepSync = function(type) {
$rootScope.newYesNoBox('warning', 'Faire une synchronisation intégrale ?', '',
function() {
$scope.deepSyncInProgress = true;
$http.post("/api/sync/deep").then(function() {
$scope.deepSyncInProgress = false;
$rootScope.newBox('success', 'Synchronisation intégrale terminée.', '<a href="check_import.html">Voir le rapport</a>.', 15000);
}, function(response) {
$scope.deepSyncInProgress = false;
$rootScope.newBox('warning', 'Synchronisation intégrale terminée.', '<a href="check_import.html">Voir le rapport</a>.', 15000);
});
});
};
})
.controller("PKIController", function($scope, $rootScope, Certificate, CACertificate, Team, $location, $http) {