Skip to content

Commit

Permalink
Merge pull request #822 from shankari/fix_maps
Browse files Browse the repository at this point in the history
Add additional logging + one more overlay hide
  • Loading branch information
shankari authored Apr 27, 2022
2 parents c4e5972 + 0f2f5de commit f13ca57
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion www/js/diary/infinite_scroll_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,16 +85,19 @@ angular.module('emission.main.diary.infscrolllist',['ui-leaflet',
}

$scope.readDataFromServer = function() {
Logger.log("Called readDataFromServer");
$scope.infScrollControl.fromBottom = getFromBottom()
$scope.infScrollControl.callback = adjustScrollAfterDownload;
console.log("calling readDataFromServer with "+
JSON.stringify($scope.infScrollControl));
const currEnd = $scope.infScrollControl.currentEnd;
if (!angular.isDefined(currEnd)) {
console.log("trying to read data too early, early return");
Logger.log("trying to read data too early, early return");
$ionicLoading.hide();
$scope.$broadcast('scroll.infiniteScrollComplete')
return;
}
Logger.log("Turning on the ionic loading overlay in setupInfScroll");
$ionicLoading.show({
template: $translate.instant('service.reading-server')
});
Expand Down Expand Up @@ -149,6 +152,7 @@ angular.module('emission.main.diary.infscrolllist',['ui-leaflet',
$scope.infScrollControl.reachedEnd = false;
$scope.data.allTrips = [];
$scope.data.displayTrips = [];
Logger.log("Turning on the ionic loading overlay in setupInfScroll");
$ionicLoading.show({
template: $translate.instant('service.reading-server')
});
Expand Down

0 comments on commit f13ca57

Please sign in to comment.