--- a/client/app/home/home_controller.js Mon Oct 06 17:36:47 2014 +0200
+++ b/client/app/home/home_controller.js Mon Oct 06 22:52:30 2014 +0200
@@ -15,6 +15,19 @@
$scope.searchSubmit = function(){
$location.path('/search/' + $scope.q);
};
+ })
+ .filter('meta', function() {
+ return function(input, metaName) {
+ var nb = input.length, i = 0, found = false;
+ while(found===false && i<nb){
+ if(input[i].name===metaName){
+ found = true;
+ return input[i].value;
+ }
+ i++;
+ }
+ return '';
+ };
});
})();