mirror of
https://github.com/valitydev/wazuh-kibana-app.git
synced 2024-11-06 18:05:20 +00:00
Modified blank screen controller to use scope directly
This commit is contained in:
parent
1a21504b36
commit
eee3c24215
@ -1,11 +1,13 @@
|
||||
const app = require('ui/modules').get('app/wazuh', []);
|
||||
import $ from 'jquery';
|
||||
|
||||
// Logs controller
|
||||
app.controller('blankScreenController', function ($scope, $rootScope, errorHandler) {
|
||||
app.controller('blankScreenController', function ($scope, $rootScope, errorHandler,$location) {
|
||||
if($rootScope.blankScreenError) {
|
||||
$('#result').html(errorHandler.handle($rootScope.blankScreenError,'',false,true));
|
||||
$scope.errorToShow = $rootScope.blankScreenError;
|
||||
delete $rootScope.blankScreenError;
|
||||
} else {
|
||||
$('#result').html('Something went wrong')
|
||||
if(!$scope.$$phase) $scope.$digest();
|
||||
}
|
||||
$scope.goOverview = () => {
|
||||
$location.path('/overview');
|
||||
}
|
||||
});
|
Loading…
Reference in New Issue
Block a user