private void Guardar(List <ListaPreciosCentrosInfo> precios) { try { var pl = new ListaPreciosCentrosPL(); var usuarioId = AuxConfiguracion.ObtenerUsuarioLogueado(); if (pl.Guardar(precios, usuarioId)) { SkMessageBox.Show(Application.Current.Windows[ConstantesVista.WindowPrincipal], Properties.Resources.ListaPreciosCentros_Guardar, MessageBoxButton.OK, MessageImage.Correct); } } catch (Exception ex) { Logger.Error(ex); SkMessageBox.Show(Application.Current.Windows[ConstantesVista.WindowPrincipal], Properties.Resources.ListaPreciosCentros_ErrorGuardar, MessageBoxButton.OK, MessageImage.Error); } }
private void LLenarGrid() { try { var pl = new ListaPreciosCentrosPL(); var result = pl.ObtenerListaPreciosCentros(Contexto); gridDatos.ItemsSource = result; if (result.Count <= 0) { SkMessageBox.Show(Application.Current.Windows[ConstantesVista.WindowPrincipal], Properties.Resources.ListaPreciosCentros_SinInformacion, MessageBoxButton.OK, MessageImage.Warning); } } catch (Exception ex) { Logger.Error(ex); SkMessageBox.Show(Application.Current.Windows[ConstantesVista.WindowPrincipal], Properties.Resources.ListaPreciosCentros_MsjErrorDatos, MessageBoxButton.OK, MessageImage.Error); } }