mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-02-12 06:54:19 +01:00
(bug) incorrect date range in statistics
This commit is contained in:
parent
8cd87f94d5
commit
2ceb4f1119
@ -502,8 +502,8 @@ Application.Controllers.controller('StatisticsController', ['$scope', '$state',
|
|||||||
scroll: ES_SCROLL_TIME + 'm',
|
scroll: ES_SCROLL_TIME + 'm',
|
||||||
'stat-type': type,
|
'stat-type': type,
|
||||||
'custom-query': custom ? JSON.stringify(Object.assign({ exclude: custom.exclude }, buildElasticCustomCriterion(custom))) : '',
|
'custom-query': custom ? JSON.stringify(Object.assign({ exclude: custom.exclude }, buildElasticCustomCriterion(custom))) : '',
|
||||||
'start-date': moment($scope.datePickerStart.selected).format(),
|
'start-date': moment($scope.datePickerStart.selected).format('YYYY-MM-DD'),
|
||||||
'end-date': moment($scope.datePickerEnd.selected).format(),
|
'end-date': moment($scope.datePickerEnd.selected).format('YYYY-MM-DD'),
|
||||||
body: buildElasticDataQuery(type, custom, $scope.agePicker.start, $scope.agePicker.end, moment($scope.datePickerStart.selected), moment($scope.datePickerEnd.selected), $scope.sorting)
|
body: buildElasticDataQuery(type, custom, $scope.agePicker.start, $scope.agePicker.end, moment($scope.datePickerStart.selected), moment($scope.datePickerEnd.selected), $scope.sorting)
|
||||||
}
|
}
|
||||||
, function (error, response) {
|
, function (error, response) {
|
||||||
@ -537,8 +537,8 @@ Application.Controllers.controller('StatisticsController', ['$scope', '$state',
|
|||||||
{
|
{
|
||||||
range: {
|
range: {
|
||||||
date: {
|
date: {
|
||||||
gte: intervalBegin.format(),
|
gte: intervalBegin.format('YYYY-MM-DD'),
|
||||||
lte: intervalEnd.format()
|
lte: intervalEnd.format('YYYY-MM-DD')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -767,8 +767,8 @@ Application.Controllers.controller('ExportStatisticsController', ['$scope', '$ui
|
|||||||
{
|
{
|
||||||
range: {
|
range: {
|
||||||
date: {
|
date: {
|
||||||
gte: moment($scope.dates.start).format(),
|
gte: moment($scope.dates.start).format('YYYY-MM-DD'),
|
||||||
lte: moment($scope.dates.end).format()
|
lte: moment($scope.dates.end).format('YYYY-MM-DD')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user