Lines Matching full:scope

20         '$scope', 'APIUtils', 'Constants',
21 function($scope, APIUtils, Constants) { argument
22 $scope.itemsPerPage = Constants.PAGINATION.LOG_ITEMS_PER_PAGE;
23 $scope.loading = true;
24 $scope.sysLogs = [];
25 $scope.customSearch = '';
26 $scope.searchTerms = [];
27 $scope.sortKey = 'Id';
28 $scope.showLogDropdown = false;
29 $scope.recordTypeList =
31 $scope.selectedRecordType = 'SEL'; // Default Select to SEL.
32 $scope.typeFilter = false;
33 $scope.selectedSeverityList = [];
34 $scope.severityList = ['All', 'Critical', 'Warning', 'Ok'];
35 $scope.filterTypes = [];
36 $scope.selectedType = 'All';
38 $scope.selectRecordType = function(recordType) {
39 $scope.selectedRecordType = recordType;
40 $scope.showLogDropdown = false;
41 $scope.filterTypes = [];
46 $scope.sysLogs = res;
47 $scope.filterTypes.push('All');
48 $scope.sysLogs.forEach(function(log) {
49 if ($scope.filterTypes.indexOf(log.SensorType) < 0) {
50 $scope.filterTypes.push(log.SensorType);
58 $scope.loading = false;
62 $scope.clearSystemLogEntries = function(selectedRecordType) {
63 $scope.confirm = false;
73 $scope.selectRecordType($scope.selectedRecordType);
77 $scope.sortBy = function(keyname, isReverse) {
78 $scope.sortKey = keyname;
79 $scope.reverse = isReverse;
82 $scope.clear = function() {
83 $scope.customSearch = '';
84 $scope.searchTerms = [];
87 $scope.doSearchOnEnter = function(event) {
89 $scope.customSearch.replace(/^\s+/g, '').replace(/\s+$/g, '');
91 $scope.searchTerms = $scope.customSearch.split(' ');
94 $scope.searchTerms = [];
99 $scope.doSearchOnClick = function() {
101 $scope.customSearch.replace(/^\s+/g, '').replace(/\s+$/g, '');
103 $scope.searchTerms = $scope.customSearch.split(' ');
106 $scope.searchTerms = [];
111 $scope.filterBySearchTerms = function(log) {
112 if (!$scope.searchTerms.length) {
116 for (var i = 0, length = $scope.searchTerms.length; i < length;
121 if (search_text.indexOf($scope.searchTerms[i].toLowerCase()) ==
128 $scope.filterBySeverity = function(log) {
129 if ($scope.selectedSeverityList.length == 0) {
133 return ($scope.selectedSeverityList.indexOf(log.Severity) > -1);
136 $scope.filterByType = function(log) {
137 if ($scope.selectedType == 'All') {
141 return (($scope.selectedType == log.SensorType));
144 $scope.filterByDate = function(log) {
146 if ($scope.start_date && $scope.end_date) {
148 logDate >= $scope.start_date && logDate <= $scope.end_date);
154 setTimeout($scope.selectRecordType($scope.selectedRecordType), 2000);