Cleans the javascript

This commit is contained in:
2016-02-24 12:28:24 +01:00
parent e6e1f6d6b3
commit 17c2f18193
9 changed files with 34 additions and 30 deletions

View File

@@ -1,5 +1,3 @@
'use strict';
angular.module('satbd.satellite.bar.views.search',[
'ngRoute',
'ngSanitize',
@@ -7,11 +5,15 @@ angular.module('satbd.satellite.bar.views.search',[
'satbd.satellite.bar.components.album',
'angular-inview'
]).config(function($routeProvider) {
'use strict';
$routeProvider.when('/search', {
templateUrl: 'js/views/search/search.html',
controller: 'SearchCtrl'
});
}).controller('SearchCtrl', function($scope,$routeParams,$log,$sce,albumService) {
'use strict';
$scope.terms=$routeParams.q;
$scope.scrollMore = false;
$scope.allHits = [];
@@ -43,14 +45,14 @@ angular.module('satbd.satellite.bar.views.search',[
};
$scope.inSecond= function(bleveValue) {
return bleveValue / 1e9;
}
return bleveValue / 1e6;
};
$scope.trustedFragment = function(f) {
return $sce.trustAsHtml(f);
}
};
$scope.round4Dec = function(value) {
return Math.round(value * 10000) / 10000;
}
};
});