Fix problem with Surveil endpoint
Change-Id: I4d8625ec1855594f7e4e3dab2abc3f6f3108a676
This commit is contained in:
parent
7b30a1ff45
commit
4f1c0bed84
@ -58,7 +58,7 @@ angular.module('bansho.authentication', [])
|
|||||||
|
|
||||||
authService.login = function (credentials) {
|
authService.login = function (credentials) {
|
||||||
return $http
|
return $http
|
||||||
.post('/surveil/v2/auth/tokens/', credentials)
|
.post('surveil/v2/auth/tokens/', credentials)
|
||||||
.success(function (data) {
|
.success(function (data) {
|
||||||
$rootScope.isAuthenticated = true;
|
$rootScope.isAuthenticated = true;
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@ angular.module('bansho.surveil')
|
|||||||
}
|
}
|
||||||
|
|
||||||
return $http({
|
return $http({
|
||||||
url: '/surveil/v2/actions/acknowledge/',
|
url: 'surveil/v2/actions/acknowledge/',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
@ -39,7 +39,7 @@ angular.module('bansho.surveil')
|
|||||||
}
|
}
|
||||||
|
|
||||||
return $http({
|
return $http({
|
||||||
url: '/surveil/v2/actions/downtime/',
|
url: 'surveil/v2/actions/downtime/',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: attrs
|
data: attrs
|
||||||
});
|
});
|
||||||
@ -53,7 +53,7 @@ angular.module('bansho.surveil')
|
|||||||
}
|
}
|
||||||
|
|
||||||
return $http({
|
return $http({
|
||||||
url: '/surveil/v2/actions/recheck/',
|
url: 'surveil/v2/actions/recheck/',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: attrs
|
data: attrs
|
||||||
});
|
});
|
||||||
|
@ -35,7 +35,7 @@ angular.module('bansho.surveil')
|
|||||||
query.filters = JSON.stringify(filters);
|
query.filters = JSON.stringify(filters);
|
||||||
|
|
||||||
return $http({
|
return $http({
|
||||||
url: '/surveil/v2/status/' + apiName + '/',
|
url: 'surveil/v2/status/' + apiName + '/',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: query,
|
data: query,
|
||||||
transformResponse: appendTransform($http.defaults.transformResponse, transformations),
|
transformResponse: appendTransform($http.defaults.transformResponse, transformations),
|
||||||
@ -45,7 +45,7 @@ angular.module('bansho.surveil')
|
|||||||
};
|
};
|
||||||
|
|
||||||
var getMetric = function (host, service, metric) {
|
var getMetric = function (host, service, metric) {
|
||||||
var url = '/surveil/v2/status/hosts/' + host,
|
var url = 'surveil/v2/status/hosts/' + host,
|
||||||
responsePromise = $q.defer();
|
responsePromise = $q.defer();
|
||||||
|
|
||||||
if (service !== undefined) {
|
if (service !== undefined) {
|
||||||
@ -201,8 +201,8 @@ angular.module('bansho.surveil')
|
|||||||
"host": "hosts",
|
"host": "hosts",
|
||||||
"service": "services"
|
"service": "services"
|
||||||
},
|
},
|
||||||
liveUrl = '/surveil/v2/status/' + endpoints[objectType] + '/' + objectIdentifier.host_name + '/',
|
liveUrl = 'surveil/v2/status/' + endpoints[objectType] + '/' + objectIdentifier.host_name + '/',
|
||||||
configUrl = '/surveil/v2/config/' + endpoints[objectType] + '/' + objectIdentifier.host_name + '/',
|
configUrl = 'surveil/v2/config/' + endpoints[objectType] + '/' + objectIdentifier.host_name + '/',
|
||||||
responsePromise = $q.defer();
|
responsePromise = $q.defer();
|
||||||
|
|
||||||
$http.get(liveUrl).success(function (liveData) {
|
$http.get(liveUrl).success(function (liveData) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user