private async void AddAeroplaneType() { try { var result = await _service.AddAsync(SelectedAeroplaneType); AeroplaneTypes.Insert(0, result); } catch (System.InvalidOperationException ex) { await _dialogService.ShowMessage(ex.Message, "Error"); } }
private async void DeleteAeroplaneType() { try { await _service.DeleteAsync(SelectedAeroplaneType.Id); AeroplaneTypes.Remove(SelectedAeroplaneType); } catch (System.InvalidOperationException ex) { await _dialogService.ShowMessage(ex.Message, "Error"); } }