예제 #1
0
        void llenarCmb()
        {
            cmbController cmb = new cmbController();

            cmbCategoria.DisplayMember = "name";
            cmbCategoria.ValueMember   = "category_id";
            cmbCategoria.DataSource    = cmb.getCategories();
        }
예제 #2
0
        void cargarDepartaments()
        {
            cmbController dc = new cmbController();

            cmbDepartaments.DisplayMember = "name";
            cmbDepartaments.ValueMember   = "departament_id";
            cmbDepartaments.DataSource    = dc.getDepartaments();
            cmbSpecialties.DisplayMember  = "name";
            cmbSpecialties.ValueMember    = "specialty_id";
            cmbSpecialties.DataSource     = dc.getSpecialties();
        }
예제 #3
0
        public FichaMedica(PatientModel p, User c)
        {
            InitializeComponent();
            this.currentUser           = c;
            this.patient               = p;
            this.catalogControllers    = new cmbController();
            this.appController         = new AppointmentController();
            this.appointmentsOfPatient = this.appController.getAppointmentsByPatientId(this.patient.Id, this.currentUser.Id);
            txtId.Text           = "000" + p.Id + "";
            txtNameApp.Text      = p.Name + " " + p.Last_name;
            txtGrade.Text        = p.Grade;
            txtUnidad.Text       = p.Unit;
            txtAdmin.Text        = p.Sit_admin;
            txtSexo.Text         = p.GenderId == 0 ? "Masculino" : "Femenino";
            txtDni.Text          = p.Dni;
            txtSexo.Text         = p.Gender;
            txtArma.Text         = p.Arma;
            txtCategoria.Text    = catalogControllers.findCategoryByName(p.CatetegoryValue).Name;
            txtSpecialty.Text    = catalogControllers.findSpecialtyById(currentUser.Specialty).Name;
            txtGuarnicion.Text   = p.Guarnicion;
            txtActasMédicas.Text = "0-" + this.appointmentsOfPatient.Rows.Count + "";

            txtDactasMedicas.Text    = "0-" + this.appointmentsOfPatient.Rows.Count + "";
            txtDNumEspecialidad.Text = currentUser.Specialty + "";
            txtDEspeciliad.Text      = txtSpecialty.Text;
            txtDNAditivo.Text        = txtId.Text;
            txtDNombrePaciente.Text  = txtNameApp.Text;
            txtDGrado.Text           = txtGrade.Text;
            txtDUnidad.Text          = txtUnidad.Text;
            txtDSitAdmin.Text        = txtAdmin.Text;
            t.Text                     = txtSexo.Text;
            txtDDNI.Text               = txtDni.Text;
            txtDArma.Text              = txtArma.Text;
            txtDGuarnicion.Text        = txtGuarnicion.Text;
            txtDCategoria.Text         = txtCategoria.Text;
            txtDDescanso.SelectedIndex = 0;
        }