get support configuration via REST API

This commit is contained in:
Girish Ramakrishnan
2020-02-05 14:15:46 -08:00
parent 5996ea1ba3
commit be1874839e
3 changed files with 24 additions and 16 deletions

View File

@@ -9,6 +9,7 @@ angular.module('Application').controller('SupportController', ['$scope', '$locat
$scope.config = Client.getConfig();
$scope.user = Client.getUserInfo();
$scope.apps = Client.getInstalledApps();
$scope.supportConfig = null;
$scope.feedback = {
error: null,
@@ -70,12 +71,18 @@ angular.module('Application').controller('SupportController', ['$scope', '$locat
}
Client.onReady(function () {
Client.getRemoteSupport(function (error, enabled) {
Client.getSupportConfig(function (error, supportConfig) {
if (error) return console.error(error);
$scope.sshSupportEnabled = enabled;
$scope.supportConfig = supportConfig;
getSubscription();
Client.getRemoteSupport(function (error, enabled) {
if (error) return console.error(error);
$scope.sshSupportEnabled = enabled;
getSubscription();
});
});
});