Lines Matching full:scope

13     '$scope', 'APIUtils', '$route', '$q', 'toastService', '$timeout',
14 function($scope, APIUtils, $route, $q, toastService, $timeout) { argument
15 $scope.bmc = {};
17 $scope.host = {};
18 $scope.ntp = {servers: []};
19 $scope.time = {mode: '', owner: ''};
22 $scope.timeOwners = ['BMC', 'Host', 'Both', 'Split'];
23 $scope.loading = true;
32 $scope.bmc.date =
35 $scope.bmc.date.setMilliseconds(0);
40 $scope.bmc.timezone = getUserTimezone($scope.bmc.date) + ' ' +
41 createOffset($scope.bmc.date);
45 $scope.host.date =
47 $scope.host.date.setMilliseconds(0);
48 $scope.host.timezone = getUserTimezone($scope.bmc.date) + ' ' +
49 createOffset($scope.bmc.date);
53 $scope.time.owner =
59 $scope.time.mode = data.data[timePath + 'sync_method']
70 $scope.ntp.servers = data.data;
79 $scope.loading = false;
92 $scope.saveDateTimeSettings = function() {
93 $scope.loading = true;
94 if ($scope.time.mode == 'Manual' || $scope.time.owner == 'Split') {
113 $scope.loading = false;
120 if ($scope.time.mode == 'Manual') {
123 if ($scope.time.owner != 'Host') {
124 manualPromises.push(setBMCTime($scope.bmc.date.getTime() * 1000));
129 if ($scope.time.owner == 'Host') {
130 manualPromises.push(setHostTime($scope.bmc.date.getTime() * 1000));
135 if ($scope.time.owner == 'Split') {
136 manualPromises.push(setHostTime($scope.host.date.getTime() * 1000));
150 $scope.loading = false;
154 $scope.refresh = function() {
158 $scope.addNTPField = function() {
159 $scope.ntp.servers.push('');
162 $scope.removeNTPField = function(index) {
163 $scope.ntp.servers.splice(index, 1);
169 $scope.ntp.servers = $scope.ntp.servers.filter(Boolean);
171 return APIUtils.setNTPServers($scope.ntp.servers);
177 $scope.time.mode);
182 'xyz.openbmc_project.Time.Owner.Owners.' + $scope.time.owner);