I want to get the date of day - 1 or month -1 for example, how can I manage that?
For now I have that:
resolve: {
data: function($route, $http, $filter) {
var today = new Date();
var formattedDate = $filter('date')(today, 'yyyyMMdd');
return $http.get('./app/sources/stats/'+$route.current.params.mag+'/'+$route.current.params.mag+'_20170205.json').then(function(response) {
return response.data;
});
}
}