예제 #1
0
        private async Task UploadRides()
        {
            var uploads = Context.Model.PendingRideUploads
                          .OrderBy(i => i.StartUtc)
                          .ToList();

            IsUploading = true;

            foreach (var upload in uploads)
            {
                try {
                    RideOverviewDto rideOverview = await Context.Services.UploadRide(upload);

                    await Context.Model.RemoveUploadRide(upload);

                    Rides.Insert(0, rideOverview);

                    OnPropertyChanged(nameof(PendingUploudCount));
                    OnPropertyChanged(nameof(UploadText));
                } catch (ServiceException ex) {
                    Toast.LongAlert(ex.Message);
                }
            }

            IsUploading = false;
        }
예제 #2
0
 public async Task GoToReview(RideOverviewDto ride)
 {
     await Context.UI.GoToRideReviewScreenAsync(ride.RideId.Value);
 }