<span>{{time | date:'mm:ss'}}</span> $scope.time= 900000; //15分钟 $one_minute = $interval(function(){ $scope.time--; },1000);
In this case, it will only move once at 14:59 and then stop moving date:'mm:ss' There is a problem here
Just click $scope.time--;换成$scope.time -= 1000; and it’s OK, the time format is fine.
$scope.time--;
$scope.time -= 1000;
Just click
$scope.time--;
换成$scope.time -= 1000;
and it’s OK, the time format is fine.