public override void CargarDatos(int?entidadId) { // Instancion por medio del Inyector el Objeto Grupo empleado = ObjectFactory.GetInstance <Empleado>(); if (entidadId.HasValue) { empleado = recursosHumanosUoW.EmpleadoRepositorio.ObtenerPorId(entidadId.Value); this.txtApellido.Text = empleado.Apellido; this.txtNombre.Text = empleado.Nombre; this.txtDni.Text = empleado.Dni; this.txtTelefono.Text = empleado.Telefono; this.txtCelular.Text = empleado.Celular; this.txtMatriculaNacional.Text = empleado.MatriculaNacional; this.txtMatriculaProvincial.Text = empleado.MatriculaProvincial; this.cmbEspecialidad.SelectedValue = empleado.EspecialidadId; this.dtpFechaIngreso.Value = empleado.FechaIngreso; this.dtpFechaNacimiento.Value = empleado.FechaNacimiento; this.imgFotoEmpleado.Image = Imagen.Convertir_Bytes_Imagen(empleado.FotoEmpleado); this.txtApellido.Focus(); } else { Mensaje.Mostrar(new Exception("Error al cargar los Datos"), Constantes.TipoMensaje.Error); } }
public override void CargarDatos(int?entidadId) { // Instancion por medio del Inyector el Objeto Grupo paciente = ObjectFactory.GetInstance <Dominio.DatosPaciente.Entidades.Paciente>(); if (cmbGrupoSanguineo.Items.Count > 0) { this.cmbGrupoSanguineo.SelectedIndex = 3; } if (entidadId.HasValue) { paciente = datosPacienteUoW.PacienteRepositorio.ObtenerPorId(entidadId.Value); this.txtApellido.Text = paciente.Apellido; this.txtNombre.Text = paciente.Nombre; this.txtDni.Text = paciente.Dni; this.txtTelefono.Text = paciente.Telefono; this.txtNroAfiliado.Text = paciente.NumeroAfiliado; this.txtPlanObraSocial.Text = paciente.PlanObraSocial; this.txtCelular.Text = paciente.Celular; this.txtMail.Text = paciente.Mail; this.txtDireccion.Text = paciente.Domicilio; this.dtpFechaNacimiento.Value = paciente.FechaNacimiento; this.dtpFechaNacimiento.MaxDate = DateTime.Today; this.imgFotoPaciente.Image = Imagen.Convertir_Bytes_Imagen(paciente.Foto); this.cmbGrupoSanguineo.SelectedValue = paciente.GrupoSanguineoId; this.cmbObraSocial.SelectedValue = paciente.ObraSocialId; this.cmbSexo.SelectedValue = paciente.SexoId; this.chkEsDown.Checked = paciente.EsDown; this.txtEdad.Text = Edad.Calcular(paciente.FechaNacimiento, DateTime.Today); this.txtApellido.Focus(); } else { Mensaje.Mostrar(new Exception("Error al cargar los Datos"), Constantes.TipoMensaje.Error); } }
public virtual void btnPatologia_Click(object sender, EventArgs e) { var form_Patologia = ObjectFactory.GetInstance <Presentacion.DatosPaciente.Vistas.Patologia._00515_PatologiaPaciente>(); var paciente = _uowDatosPaciente.PacienteRepositorio.ObtenerPorId(base.EntidadId.Value); if (paciente != null) { form_Patologia.Titulo = paciente.ApyNom; form_Patologia.Leyenda = string.Format("OS: {0} Nro Afil: {1} - Edad: {2}", paciente.ObraSocial.Descripcion, paciente.NumeroAfiliado, paciente.Edad); form_Patologia.imgTitulo.Image = Imagen.Convertir_Bytes_Imagen(paciente.Foto); form_Patologia.PacienteId = paciente.Id; VerificarSiTieneAccesoAlFormulario(form_Patologia); } }
public override void CargarDatos(int?entidadId) { // Instancion por medio del Inyector el Objeto Grupo empresa = ObjectFactory.GetInstance <Empresa>(); if (entidadId.HasValue) { empresa = recursosHumanosUoW.EmpresaRepositorio.ObtenerPorId(entidadId.Value); this.txtRazonSocial.Text = empresa.RazonSocial; this.txtNombreFantasia.Text = empresa.NombreFantasia; this.txtDomicilio.Text = empresa.Direccion; this.txtTelefono.Text = empresa.Telefono; this.imgLogo.Image = Imagen.Convertir_Bytes_Imagen(empresa.Logo); this.txtIngresosBrutos.Text = empresa.IngresosBrutos; this.txtCuitCuil.Text = empresa.CuitCuil; } else { Mensaje.Mostrar(new Exception("Error al cargar los Datos"), Constantes.TipoMensaje.Error); } }