add volume status indicator

This commit is contained in:
Girish Ramakrishnan
2021-05-13 15:33:07 -07:00
parent 95e2b726c1
commit 247dcbfe11
3 changed files with 27 additions and 3 deletions
+9
View File
@@ -2665,6 +2665,15 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout
});
};
Client.prototype.getVolumeStatus = function (volume, callback) {
get('/api/v1/volumes/' + volume + '/status', null, function (error, data, status) {
if (error) return callback(error);
if (status !== 200) return callback(new ClientError(status, data));
callback(null, data);
});
};
Client.prototype.addVolume = function (name, hostPath, mountType, mountOptions, callback) {
var data = {
name: name,