mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-11-16 14:28:34 +00:00
36 lines
930 B
JavaScript
36 lines
930 B
JavaScript
(function() {
|
|
'use strict';
|
|
|
|
angular
|
|
.module('vertoControllers')
|
|
.controller('ModalSettingsController', ['$scope', '$http',
|
|
'$location', '$modalInstance', 'storage', 'verto',
|
|
function($scope, $http, $location, $modalInstance, storage, verto) {
|
|
console.debug('Executing ModalSettingsController.');
|
|
|
|
$scope.storage = storage;
|
|
$scope.verto = verto;
|
|
$scope.mydata = angular.copy(storage.data);
|
|
|
|
$scope.ok = function() {
|
|
storage.changeData($scope.mydata);
|
|
verto.data.instance.iceServers(storage.data.useSTUN);
|
|
$modalInstance.close('Ok.');
|
|
};
|
|
|
|
$scope.cancel = function() {
|
|
$modalInstance.dismiss('cancel');
|
|
};
|
|
|
|
$scope.refreshDeviceList = function() {
|
|
return verto.refreshDevices();
|
|
}
|
|
|
|
$scope.resetSettings = function() {
|
|
storage.reset();
|
|
}
|
|
}
|
|
]);
|
|
|
|
})();
|