mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-06 04:45:30 +00:00
Merge pull request #498 in FS/freeswitch from ~STEFAN_YOHANSSON/freeswitch:bugfix/FS-8095-add-factory-reset-to-settings to master
* commit 'bc4d21e38203879a9a9d314e723904975a5cd6cc': FS-8095 [verto_communicator] added reset button to default settings.
This commit is contained in:
commit
dfd6d0248a
@ -24,6 +24,7 @@
|
|||||||
</select>
|
</select>
|
||||||
|
|
||||||
<a class="btn btn-primary" href="" ng-click="refreshDeviceList()">Refresh device list</a>
|
<a class="btn btn-primary" href="" ng-click="refreshDeviceList()">Refresh device list</a>
|
||||||
|
<a class="btn btn-primary" href="" ng-click="resetSettings()">Factory reset</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
|
@ -4,9 +4,8 @@
|
|||||||
.module('storageService')
|
.module('storageService')
|
||||||
.service('storage', ['$rootScope', '$localStorage',
|
.service('storage', ['$rootScope', '$localStorage',
|
||||||
function($rootScope, $localStorage) {
|
function($rootScope, $localStorage) {
|
||||||
var data = $localStorage;
|
var data = $localStorage,
|
||||||
|
defaultSettings = {
|
||||||
data.$default({
|
|
||||||
ui_connected: false,
|
ui_connected: false,
|
||||||
ws_connected: false,
|
ws_connected: false,
|
||||||
cur_call: 0,
|
cur_call: 0,
|
||||||
@ -36,7 +35,9 @@
|
|||||||
googNoiseSuppression: true,
|
googNoiseSuppression: true,
|
||||||
googHighpassFilter: true,
|
googHighpassFilter: true,
|
||||||
googEchoCancellation: true
|
googEchoCancellation: true
|
||||||
});
|
};
|
||||||
|
|
||||||
|
data.$default(defaultSettings);
|
||||||
|
|
||||||
function changeData(verto_data) {
|
function changeData(verto_data) {
|
||||||
jQuery.extend(true, data, verto_data);
|
jQuery.extend(true, data, verto_data);
|
||||||
@ -46,10 +47,7 @@
|
|||||||
data: data,
|
data: data,
|
||||||
changeData: changeData,
|
changeData: changeData,
|
||||||
reset: function() {
|
reset: function() {
|
||||||
data.ui_connected = false;
|
data.$reset(defaultSettings);
|
||||||
data.ws_connected = false;
|
|
||||||
data.cur_call = 0;
|
|
||||||
data.userStatus = 'disconnected';
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -25,6 +25,10 @@
|
|||||||
$scope.refreshDeviceList = function() {
|
$scope.refreshDeviceList = function() {
|
||||||
return verto.refreshDevices();
|
return verto.refreshDevices();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$scope.resetSettings = function() {
|
||||||
|
storage.reset();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user