Пример #1
0
        private void CargarGraficaTension()
        {
            try
            {
                negocioPaciente = new PacienteNegocio();
                RadHtmlChartTension.DataSource = negocioPaciente.ConsultaGraficaTension(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOTENSION);
                RadHtmlChartTension.DataBind();
                RadHtmlChartTension.PlotArea.XAxis.DataLabelsField = "fechaEvento";
                RadHtmlChartTension.PlotArea.XAxis.LabelsAppearance.RotationAngle = 90;

                PlotBand xAxisPlotBand = new PlotBand();
                xAxisPlotBand.From  = (decimal?)Convert.ToInt16(Request.QueryString["limiteInferiorSistolica"]);
                xAxisPlotBand.To    = (decimal?)Convert.ToInt16(Request.QueryString["limiteSuperiorSistolica"]);
                xAxisPlotBand.Color = System.Drawing.ColorTranslator.FromHtml("#6453FD");
                xAxisPlotBand.Alpha = (byte)190;
                RadHtmlChartTension.PlotArea.YAxis.PlotBands.Add(xAxisPlotBand);

                PlotBand xAxisPlotBand2 = new PlotBand();
                xAxisPlotBand2.From  = (decimal?)Convert.ToInt16(Request.QueryString["limiteSuperiorDiastolica"]);
                xAxisPlotBand2.To    = (decimal?)Convert.ToInt16(Request.QueryString["limiteInferiorDiastolica"]);
                xAxisPlotBand2.Color = System.Drawing.ColorTranslator.FromHtml("#FC6969");
                xAxisPlotBand2.Alpha = (byte)190;
                RadHtmlChartTension.PlotArea.YAxis.PlotBands.Add(xAxisPlotBand2);
            }
            catch (Exception ex)
            {
                RadNotificationMensajes.Show(ex.Message);
            }
        }
Пример #2
0
        //
        // GET: /Resporte/
        public ActionResult ListadoPacientes()
        {
            PacienteNegocio control   = new PacienteNegocio();
            List <Paciente> pacientes = control.ObtenerPacientes(string.Empty, string.Empty, string.Empty, string.Empty, string.Empty);

            return(View(pacientes));
        }
Пример #3
0
        public ActionResult GraficoPacientes()
        {
            PacienteNegocio control     = new PacienteNegocio();
            List <Paciente> deportistas = control.ObtenerPacientes(string.Empty, string.Empty, string.Empty, string.Empty, string.Empty);

            var pacientesPorAnyo = pacientes.GroupBy(p => p.FechaNacimiento.Year).Select(p => new { Year = p.Key, Cantidad = p.Count() });
            var datosGrafico     = "[";

            if (pacientesPorAnyo.Count() > 0)
            {
                foreach (var valor in pacientesPorAnyo)
                {
                    datosGrafico += "['" + valor.Year + "', " + valor.Cantidad + "],";
                }
                datosGrafico  = datosGrafico.Substring(0, datosGrafico.Length - 1);
                datosGrafico += "]";
            }
            else
            {
                datosGrafico = "[]";
            }

            ViewBag.DatosGrafico = datosGrafico;
            return(View());
        }
Пример #4
0
        protected void rdpFecchaFin_SelectedDateChanged(object sender, Telerik.Web.UI.Calendar.SelectedDateChangedEventArgs e)
        {
            try
            {
                if (rdpFechaInicio.SelectedDate != null && rdpFecchaFin.SelectedDate != null)
                {
                    negocioPaciente = new PacienteNegocio();
                    RadHtmlChartTension.PlotArea.XAxis.DataLabelsField = "Fecha";
                    RadHtmlChartTension.PlotArea.Series[0].DataFieldY  = "valor1";
                    RadHtmlChartTension.PlotArea.Series[1].DataFieldY  = "valor2";
                    RadHtmlChartTension.DataSource = negocioPaciente.ConsultaGraficaFiltroFechas(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOTENSION, Convert.ToDateTime(rdpFechaInicio.SelectedDate), Convert.ToDateTime(rdpFecchaFin.SelectedDate));
                    RadHtmlChartTension.DataBind();

                    PlotBand xAxisPlotBand = new PlotBand();
                    xAxisPlotBand.From  = (decimal?)Convert.ToInt16(Request.QueryString["limiteInferiorSistolica"]);
                    xAxisPlotBand.To    = (decimal?)Convert.ToInt16(Request.QueryString["limiteSuperiorSistolica"]);
                    xAxisPlotBand.Color = System.Drawing.ColorTranslator.FromHtml("#6453FD");
                    xAxisPlotBand.Alpha = (byte)190;
                    RadHtmlChartTension.PlotArea.YAxis.PlotBands.Add(xAxisPlotBand);

                    PlotBand xAxisPlotBand2 = new PlotBand();
                    xAxisPlotBand2.From  = (decimal?)Convert.ToInt16(Request.QueryString["limiteSuperiorDiastolica"]);
                    xAxisPlotBand2.To    = (decimal?)Convert.ToInt16(Request.QueryString["limiteInferiorDiastolica"]);
                    xAxisPlotBand2.Color = System.Drawing.ColorTranslator.FromHtml("#FC6969");
                    xAxisPlotBand2.Alpha = (byte)190;
                    RadHtmlChartTension.PlotArea.YAxis.PlotBands.Add(xAxisPlotBand2);
                }
            }
            catch (Exception ex)
            {
                RadNotificationMensajes.Show(ex.Message);
            }
        }
Пример #5
0
 public controlTelefonos()
 {
     InitializeComponent();
     dgvTelefonos.ReadOnly = true;
     pn = new PacienteNegocio();
     gn = new GeneralNegocio();
 }
        private void TxtBuscar_KeyPress(object sender, KeyPressEventArgs e)
        {
            if (txtBuscar.Text != "")
            {
                tbPacientes.CurrentCell = null;
                foreach (DataGridViewRow r in tbPacientes.Rows)
                {
                    r.Visible = false;
                }

                foreach (DataGridViewRow r in tbPacientes.Rows)
                {
                    foreach (DataGridViewCell c in r.Cells)
                    {
                        if ((c.Value.ToString().ToUpper()).IndexOf(txtBuscar.Text.ToUpper()) == 0)
                        {
                            r.Visible = true;
                            break;
                        }
                    }
                }
            }
            else
            {
                tbPacientes.DataSource = PacienteNegocio.DevolverListadoPacientesNegocio();
            }
        }
Пример #7
0
        private void btnBuscarPte_Click(object sender, EventArgs e)
        {
            try
            {
                pteNeg   = new PacienteNegocio();
                listaPte = new List <Paciente>();
                listaPte = pteNeg.Buscar(txtDNI.Text.Trim());
                pte      = listaPte[0];
                txtApellidoNombre.Text = pte.Apellido + ", " + pte.Nombre;
                listaHC     = new List <HC>();
                histClinNeg = new HCnegocio();
                listaHC     = histClinNeg.cargarHCactivas(pte.IdPaciente);
                dgvHistoriasClinicas.DataSource = listaHC;

                dgvHistoriasClinicas.Columns["IdHC"].Visible          = false;
                dgvHistoriasClinicas.Columns["IdRazonSocial"].Visible = false;
                dgvHistoriasClinicas.Columns["IdPaciente"].Visible    = false;
                dgvHistoriasClinicas.Columns["IdAdminAlta"].Visible   = false;
                dgvHistoriasClinicas.Columns["FechaHrModif"].Visible  = false;
                dgvHistoriasClinicas.Columns["IdAdminModif"].Visible  = false;
                dgvHistoriasClinicas.Columns["FechaHrBaja"].Visible   = false;
                dgvHistoriasClinicas.Columns["IdAdminBaja"].Visible   = false;
                dgvHistoriasClinicas.Columns["Estado"].Visible        = false;
                dgvHistoriasClinicas.AutoResizeColumns();
            }
            catch (ArgumentOutOfRangeException)
            {
                MessageBox.Show("DNI no encontrado o se encuentra inactivo");
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }
        private void BtnLogiar_Click(object sender, EventArgs e)
        {
            Paciente paciente = new Paciente();

            if (txtIdAuxiliar.Text == "")
            {
                paciente.id = 0;
            }
            else
            {
                paciente.id = Convert.ToInt32(txtIdAuxiliar.Text);
            }
            paciente.cedula          = txtCedula.Text;
            paciente.apellido1       = txtApellido1.Text;
            paciente.apellido2       = txtApellido2.Text;
            paciente.nombre1         = txtNombre1.Text;
            paciente.nombre2         = txtNombre2.Text;
            paciente.fechaNacimiento = Convert.ToDateTime(txtFechaNac.Text);
            paciente.genero          = cbGenero.SelectedItem.ToString();
            paciente.fechaIngreso    = Convert.ToDateTime(txtFechaIngresPac.Text);
            paciente.telefono        = txtTelefono.Text;
            paciente.direccion       = txtDireccion.Text;


            paciente = PacienteNegocio.GuardarPacienteNegocio(paciente);

            //PacientesListado pacientesListado = new PacientesListado();
            //pacientesListado.ShowDialog();
            //this.Close();
        }
        private void cargar()
        {
            PacienteNegocio neg = new PacienteNegocio();

            try
            {
                listaPacientes = (List <Paciente>)neg.Buscar(dni, apellido, nombre);
                dgvConsultasPacientes.DataSource = listaPacientes;

                dgvConsultasPacientes.Columns["Idpaciente"].Visible     = false;
                dgvConsultasPacientes.Columns["Id"].Visible             = false;
                dgvConsultasPacientes.Columns["IdSexo"].Visible         = false;
                dgvConsultasPacientes.Columns["IdMunicipio"].Visible    = false;
                dgvConsultasPacientes.Columns["IdNacionalidad"].Visible = false;
                dgvConsultasPacientes.Columns["FechaAlta"].Visible      = false;
                dgvConsultasPacientes.Columns["IdUsuarioAlta"].Visible  = false;
                dgvConsultasPacientes.Columns["FechaModif"].Visible     = false;
                dgvConsultasPacientes.Columns["IdUsuarioModif"].Visible = false;
                dgvConsultasPacientes.Columns["FechaBaja"].Visible      = false;
                dgvConsultasPacientes.Columns["IdUsuarioBaja"].Visible  = false;
                dgvConsultasPacientes.Columns["Estado"].Visible         = false;
                dgvConsultasPacientes.AutoResizeColumns();
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }
Пример #10
0
        public void GetMeusPacientes()
        {
            PacienteNegocio   negPaciente = new PacienteNegocio();
            List <PacienteTO> pacientes   = negPaciente.GetMeusPacientes();

            Assert.IsNotNull(pacientes);
        }
Пример #11
0
 protected void cboRangoGlucosa_SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
 {
     try
     {
         if (cboRangoGlucosa.SelectedValue != null && rdpFechaInicioGlucosa.SelectedDate != null && rdpFechaFinGlucosa.SelectedDate != null)
         {
             negocioPaciente = new PacienteNegocio();
             RadHtmlChartTalla.PlotArea.XAxis.DataLabelsField = "Fecha";
             RadHtmlChartTalla.PlotArea.Series[0].DataFieldY  = "valor1";
             RadHtmlChartTalla.PlotArea.Series[1].DataFieldY  = "valor2";
             RadHtmlChartTalla.DataSource = negocioPaciente.ConsultaGraficaFiltroHora(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOGLUCOSA, Convert.ToDateTime(rdpFechaInicioGlucosa.SelectedDate), Convert.ToDateTime(rdpFechaFinGlucosa.SelectedDate), cboRangoGlucosa.SelectedValue);
             RadHtmlChartTalla.DataBind();
             PlotBand xAxisPlotBand = new PlotBand();
             xAxisPlotBand.From  = (decimal?)Convert.ToInt16(Request.QueryString["limiteInferiorGlucosa"]);
             xAxisPlotBand.To    = (decimal?)Convert.ToInt16(Request.QueryString["limiteSuperiorGlucosa"]);
             xAxisPlotBand.Color = System.Drawing.ColorTranslator.FromHtml("#e83737");
             xAxisPlotBand.Alpha = (byte)190;
             RadHtmlChartTalla.PlotArea.YAxis.PlotBands.Add(xAxisPlotBand);
         }
         else
         {
             RadNotificationMensajes.Show("Por favor escoger primero el rango de fechas");
         }
     }
     catch (Exception ex)
     {
         RadNotificationMensajes.Show(ex.Message);
     }
 }
Пример #12
0
        private void btnGrabar_Click(object sender, EventArgs e)
        {
            if (txtDni.TextLength > 0 && txtApellido.TextLength > 0 && txtNombre.TextLength > 0 && txtCalle.TextLength > 0 && txtNumero.TextLength > 0)
            {
                PacienteNegocio neg = new PacienteNegocio();
                try
                {
                    aux.Dni             = txtDni.Text;
                    aux.Apellido        = txtApellido.Text;
                    aux.Nombre          = txtNombre.Text;
                    aux.IdSexo          = int.Parse(cboSexo.SelectedValue.ToString());
                    aux.FechaNacimiento = DateTime.Parse(dtpFechaNacimiento.Text);
                    aux.IdNacionalidad  = int.Parse(cboNacionalidad.SelectedValue.ToString());
                    aux.Calle           = txtCalle.Text;
                    aux.Altura          = txtNumero.Text;
                    aux.Piso            = txtPiso.Text;
                    aux.Dpto            = txtDepto.Text;
                    aux.IdMunicipio     = int.Parse(cboMunicipio.SelectedValue.ToString());
                    aux.TelCelular      = txtTelMovil.Text;
                    aux.TelFijo         = txtTelFijo.Text;
                    aux.Mail            = txtMail.Text;
                    aux.IdUsuarioModif  = 1;

                    neg.Modificar(aux);
                    MessageBox.Show("Se grabo con exito");
                    Close();
                }
                catch (Exception ex)
                {
                    MessageBox.Show(ex.ToString());
                }
            }
        }
Пример #13
0
        private void btnConfirmar_Click(object sender, EventArgs e)
        {
            if (txtNombre.Text == "" | txtApellido.Text == "" | txtDni.Text == "" | txtDireccion.Text == "" | txtTelParticular.Text == "" | txtTelPersonal.Text == "" | txtCorreo.Text == "")
            {
                MessageBox.Show("falta llenar campos");
                return;
            }
            else if (dtpFechaNac.Value > DateTime.Today)
            {
                MessageBox.Show("LA FECHA NO SE PUEDE SER MAYOR AL DIA DE HOY...");
            }
            else
            {
                try
                {
                    PacienteNegocio pacNuev = new PacienteNegocio();
                    if (pacie != null)
                    {
                        pacie.Nombre    = txtNombre.Text.Trim();
                        pacie.Apellido  = txtApellido.Text.Trim();
                        pacie.Dni       = Convert.ToInt64(txtDni.Text.Trim());
                        pacie.Direccion = txtDireccion.Text.Trim();
                        Localidad a = (Localidad)cboLocalidad.SelectedItem;
                        pacie.Idlocalidad = a.Idlocalidad;
                        pacie.Celular     = Convert.ToInt64(txtTelPersonal.Text.Trim());
                        pacie.Telefono    = Convert.ToInt64(txtTelParticular.Text.Trim());
                        pacie.Email       = txtCorreo.Text.Trim();
                        pacie.FechaNac    = Convert.ToDateTime(dtpFechaNac.Value.ToString());
                        pacie.Sexo        = Convert.ToString(cboSexo.SelectedItem);
                        pacNuev.modificarPaciente(pacie);

                        MessageBox.Show("Paciente modificado...");
                        cargar();
                    }
                    else
                    {
                        Paciente nuevo = new Paciente();
                        nuevo.Nombre    = txtNombre.Text.Trim();
                        nuevo.Apellido  = txtApellido.Text.Trim();
                        nuevo.Dni       = Convert.ToInt64(txtDni.Text.Trim());
                        nuevo.Direccion = txtDireccion.Text.Trim();
                        Localidad a = (Localidad)cboLocalidad.SelectedItem;
                        nuevo.Idlocalidad = a.Idlocalidad;
                        nuevo.Celular     = Convert.ToInt64(txtTelPersonal.Text.Trim());
                        nuevo.Telefono    = Convert.ToInt64(txtTelParticular.Text.Trim());
                        nuevo.Email       = txtCorreo.Text.Trim();
                        nuevo.FechaNac    = Convert.ToDateTime(dtpFechaNac.Value.ToString());
                        nuevo.Sexo        = Convert.ToString(cboSexo.SelectedItem);

                        pacNuev.agregarPaciente(nuevo);
                        MessageBox.Show("Paciente agregado exitosamente...");
                        cargar();
                    }
                }
                catch (Exception ex)
                {
                    throw ex;
                }
            }
Пример #14
0
 public controlTelefonos(int id)
 {
     //this.telefonos = telefonos;
     pn = new PacienteNegocio();
     InitializeComponent();
     dgvTelefonos.ReadOnly   = true;
     dgvTelefonos.DataSource = pn.listarTelefonos(id);
 }
Пример #15
0
        public void cargarCboPacientes()
        {
            PacienteNegocio pacneg = new PacienteNegocio();

            cboPacientes.DataSource    = pacneg.traerTodos();
            cboPacientes.DisplayMember = "Apellido";
            cboPacientes.ValueMember   = "idpaciente";
        }
Пример #16
0
 /// <summary>
 /// Carga lista de identificaciones
 /// </summary>
 private void CargarIdentificaciones()
 {
     negocioPaciente = new PacienteNegocio();
     cboTipoIdentificacion.DataSource     = negocioPaciente.listarTiposIdentificacion();
     cboTipoIdentificacion.DataValueField = "idTipoIdentificacion";
     cboTipoIdentificacion.DataTextField  = "nombre";
     cboTipoIdentificacion.Items.Insert(0, new ListItem("Seleccione...", "-1"));
     cboTipoIdentificacion.DataBind();
 }
Пример #17
0
        public void cargar()
        {
            PacienteNegocio pacNeg = new PacienteNegocio();

            dgvPacientes.DataSource          = pacNeg.traerTodos();
            dgvPacientes.Columns[0].Visible  = false;
            dgvPacientes.Columns[5].Visible  = false;
            dgvPacientes.Columns[12].Visible = false;
        }
 private void btnEliminarPte_Click(object sender, EventArgs e)
 {
     if (MessageBox.Show("¿Eliminar el paciente?", "Eliminar", MessageBoxButtons.YesNo).ToString() == "Yes")
     {
         aux = (Paciente)dgvConsultasPacientes.CurrentRow.DataBoundItem;
         PacienteNegocio neg = new PacienteNegocio();
         neg.Eliminar(aux.IdPaciente, 1);
         cargar();
     }
 }
Пример #19
0
        protected void Page_Load(object sender, EventArgs e)
        {
            paciente = (Paciente)Session["paciente"];

            if (paciente == null)
            {
                Response.Redirect("~/Index.aspx");
            }
            pacienteNegocio = new PacienteNegocio();

            if (this.tbxMail.Text.Length > 0)
            {
                return;
            }

            this.tbxDNI.Text      = paciente.dni;
            this.tbxDNI.Enabled   = false;
            this.tbxFechaNac.Text = paciente.fecha_nacimiento.Date.ToString();
            pos   = this.tbxFechaNac.Text.IndexOf(" ");
            fecha = this.tbxFechaNac.Text.Substring(0, pos);
            this.tbxFechaNac.Text          = fecha;
            tbxFechaNac.Enabled            = false;
            this.tbxApellido.Text          = paciente.apellido;
            this.tbxApellido.Enabled       = false;
            this.tbxNombre.Text            = paciente.nombre;
            this.tbxNombre.Enabled         = false;
            this.tbxMail.Text              = paciente.mail;
            this.tbxMail.Enabled           = false;
            this.tbxTelefono.Text          = paciente.telefono;
            this.tbxTelefono.Enabled       = false;
            this.tbxObraSocial.Text        = paciente.obra_social.nombre;
            this.tbxObraSocial.Enabled     = false;
            this.tbxPlan.Text              = paciente.plan.nombre;
            this.tbxPlan.Enabled           = false;
            this.tbxNumeroAfiliado.Text    = paciente.numeroAfiliado;
            this.tbxNumeroAfiliado.Enabled = false;

            if (paciente.sexo == 'F')
            {
                this.ddlSexo.Items[0].Selected = true;
                this.ddlSexo.Text = "Femenino";
            }
            if (paciente.sexo == 'M')
            {
                this.ddlSexo.Items[1].Selected = true;
                this.ddlSexo.Text = "Masculino";
            }
            if (paciente.sexo == 'O')
            {
                this.ddlSexo.Items[2].Selected = true;
                this.ddlSexo.Text = "Otros";
            }

            this.ddlSexo.Enabled = false;
        }
Пример #20
0
 protected void radGridDiagnosticos_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
 {
     try
     {
         negocioPaciente = new PacienteNegocio();
         radGridDiagnosticos.DataSource = negocioPaciente.ConsultaBandejaDiagnostico(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTODIAGNOSTICO, Constantes.TIPOEVENTOOTROSDIAGNOSTICOS);
     }
     catch (Exception ex)
     {
         RadNotificationMensajes.Show(ex.Message);
     }
 }
Пример #21
0
 protected void radGridMedicamentos_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
 {
     try
     {
         negocioPaciente = new PacienteNegocio();
         radGridMedicamentos.DataSource = negocioPaciente.ConsultaMedicamentosPaciente(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOMEDICAMENTOS);
     }
     catch (Exception ex)
     {
         RadNotificationMensajes.Show(ex.Message);
     }
 }
Пример #22
0
 protected void radGridExamenesAyudas_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
 {
     try
     {
         negocioPaciente = new PacienteNegocio();
         radGridExamenesAyudas.DataSource = negocioPaciente.ConsultaBandejaInterconsultasAgrupadas(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOEXAMENES, Constantes.TIPOEVENTOOTRASAYUDAS);
     }
     catch (Exception)
     {
         throw;
     }
 }
Пример #23
0
        public ActionResult Crear(Paciente paciente)
        {
            var tiposIdentificacion = new List <SelectListItem>();

            tiposIdentificacion.Add(new SelectListItem()
            {
                Text  = "Cédula de Ciudadanía",
                Value = "1"
            });
            tiposIdentificacion.Add(new SelectListItem()
            {
                Text  = "Tarjeta de Identidad",
                Value = "2"
            });
            ViewBag.TiposIdentificacion = tiposIdentificacion;

            PacienteNegocio PacienteNegocio = new PacienteNegocio();

            Entidades.Paciente nuevoPaciente = new Entidades.Paciente()
            {
                FechaNacimiento      = paciente.FechaNacimiento,
                NombreCompleto       = paciente.NombreCompleto,
                TipoIdentificacion   = paciente.TipoIdentificacion,
                numeroIdentificacion = paciente.numeroIdentificacion,
                Genero              = paciente.Genero,
                Edad                = paciente.Edad,
                EstadoCivil         = paciente.EstadoCivil,
                DireccionResidencia = paciente.DireccionResidencia,

                BarrioResidencia  = paciente.BarrioResidencia,
                Telefono          = paciente.Telefono,
                Ocupacion         = paciente.Ocupacion,
                NivelEscolaridad  = paciente.NivelEscolaridad,
                correoElectronico = paciente.correoElectronico,
                Eps                 = paciente.Eps,
                Regimen             = paciente.Regimen,
                ContactoEmergencia  = paciente.ContactoEmergencia,
                TratamientoRealizar = paciente.TratamientoRealizar,
                AntecedenteMedico   = paciente.AntecedenteMedico,
            };
            try
            {
                P + acienteNegocio.IngresarDeportista(nuevoPaciente);
                ViewBag.Mensaje = "Se ingresó el deportista";
            }
            catch (Exception exc)
            {
                ViewBag.Mensaje = "No se pudo ingresar el deportista";
                //Log.Error(exc);
            }
            return(View());
        }
Пример #24
0
        public void NovoPaciente()
        {
            PacienteTO paciente = new PacienteTO();

            paciente.Nome       = "Criado por Teste Unitário";
            paciente.NomeMae    = "TESTE";
            paciente.Nascimento = DateTime.Today.AddYears(-18);
            paciente.Sexo       = SexoEnum.Masculino;

            PacienteNegocio negPaciente = new PacienteNegocio();

            negPaciente.NovoPaciente(paciente);
        }
Пример #25
0
 private void CargarGraficaPeso()
 {
     try
     {
         negocioPaciente             = new PacienteNegocio();
         RadHtmlChartPeso.DataSource = negocioPaciente.ConsultaBandejaTomas(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOPESO);
         RadHtmlChartPeso.DataBind();
     }
     catch (Exception ex)
     {
         RadNotificationMensajes.Show(ex.Message);
     }
 }
Пример #26
0
 private void CargarCalendario()
 {
     try
     {
         negocioPaciente          = new PacienteNegocio();
         RadScheduler1.DataSource = negocioPaciente.ConsultarCalendarioPaciente(Convert.ToInt16(Request.QueryString["idTipoIdentificacion"]), Request.QueryString["NumeroIdentifacion"], Constantes.TIPOEVENTOCITASMEDICAS);
         RadScheduler1.DataBind();
     }
     catch (Exception ex)
     {
         RadNotificationMensajes.Show(ex.Message);
     }
 }
Пример #27
0
 private void btnEliminar_Click(object sender, EventArgs e)
 {
     try
     {
         int id = Int32.Parse(tbxIdEliminar.Text);
         MessageBox.Show("Esta seguro que quiere eliminar el registro: " + id);
         int reg = new PacienteNegocio().eliminar(id);
         MessageBox.Show("Registro modificados: " + reg);
     }catch (Exception ex)
     {
         MessageBox.Show("Error al eliminar el registro");
     }
 }
 protected void Page_Load(object sender, EventArgs e)
 {
     try
     {
         negocioPaciente = new PacienteNegocio();
         if (!Page.IsPostBack)
         {
             CargarGraficaHitorica();
         }
     }
     catch (Exception ex)
     {
         //TODO: Implemetar el manejador de mensajes
     }
 }
Пример #29
0
        private void btnConsultar_Click(object sender, EventArgs e)
        {
            PacienteNegocio pacienteNegocio = new PacienteNegocio();

            List <Paciente> pacientes = new List <Paciente>();

            if (txtNome.Text == "")
            {
                pacientes = pacienteNegocio.BuscarPacienteNome();
            }
            else
            {
                pacientes = pacienteNegocio.BuscarPacienteNome(txtNome.Text);
            }
        }
Пример #30
0
 //Metodo Listar
 private void Listar()
 {
     try
     {
         dgvGrilla.DataSource = PacienteNegocio.Listar();
         this.Formatear();
         this.Limpiar();
         this.Visualizar();
         lblCantidad.Text = "Total de registros: " + Convert.ToString(dgvGrilla.Rows.Count);
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message + ex.StackTrace);
     }
 }