private async void AddJobButton_Click(object sender, RoutedEventArgs e) { var dialog = new AddJobDialog(); var result = await dialog.ShowAsync(); if (result == ContentDialogResult.Secondary) { await ViewModel.UpdateDailyStatistic(ViewModel.Jobs.Count + 1); } await ViewModel.LoadScreenData(); }
private async void AddClientCommandExecute() { AddJobDialog dialog = new AddJobDialog(); await dialog.ShowAsync(); if (dialog.DiagResult == ContentDialogResult.Primary && dialog.NewTrip != null) { var progressDialog = UserDialogs.Instance.Loading("Adding New Trip...", maskType: MaskType.Clear); tripDataManager.SaveTrip(dialog.NewTrip); ActiveJobDataCollection.Clear(); var activeTrips = tripDataManager.GetActiveTrips(); ActiveJobDataCollection.AddRange(activeTrips); progressDialog?.Dispose(); } }
private async void AddJobButton_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e) { // Implementation will need to be changed later. var dialog = new AddJobDialog(); await dialog.ShowAsync(); }