Merge pull request #225 from rashidkpc/master

Fix for timepicker mode in firefox. Closes #222
This commit is contained in:
Rashid Khan 2013-07-17 15:10:09 -07:00
commit 3359284a93

View File

@ -84,9 +84,12 @@ angular.module('kibana.timepicker', [])
if(filterSrv.idsByType('time').length > 0) { if(filterSrv.idsByType('time').length > 0) {
var time = filterSrv.timeRange('min') var time = filterSrv.timeRange('min')
if($scope.time.from.diff(moment.utc(time.from)) != 0 if($scope.time.from.diff(moment.utc(time.from),'seconds') !== 0
|| $scope.time.to.diff(moment.utc(time.to)) != 0) || $scope.time.to.diff(moment.utc(time.to),'seconds') !== 0)
{ {
console.log($scope.time.from+ " and "+ moment.utc(time.from))
console.log($scope.time.to+" and "+moment.utc(time.to))
$scope.set_mode('absolute'); $scope.set_mode('absolute');
// These 3 statements basicly do everything time_apply() does // These 3 statements basicly do everything time_apply() does