private void OpenDiagWindow(object sender, MouseButtonEventArgs e)
 {
     if (Lista.SelectedItems != null && Lista.SelectedItems.Count != 0)
     {
         if (((Diagnostico)Lista.SelectedItem).Tipo == "Urina Normal" && (DadosForms.TipoPaciente == "Gestante" || DadosForms.TipoPaciente == "Puerpera"))
         {
             Action   acao   = new Action(() => { Lista.Items.Refresh(); });
             UrinaMae Janela = new UrinaMae((Diagnostico)Lista.SelectedItem, acao);
             JanelaServico.AbreJanela(Janela);
         }
         if (((Diagnostico)Lista.SelectedItem).Tipo == "Cólica Uterina" && (DadosForms.TipoPaciente == "Gestante"))
         {
             Action         acao   = new Action(() => { Lista.Items.Refresh(); });
             ColicaGestante Janela = new ColicaGestante((Diagnostico)Lista.SelectedItem, acao);
             JanelaServico.AbreJanela(Janela);
         }
         if (((Diagnostico)Lista.SelectedItem).Tipo == "Edema Periférico" && (DadosForms.TipoPaciente == "Gestante"))
         {
             Action        acao   = new Action(() => { Lista.Items.Refresh(); });
             EdemaGestante Janela = new EdemaGestante((Diagnostico)Lista.SelectedItem, acao);
             JanelaServico.AbreJanela(Janela);
         }
         if (((Diagnostico)Lista.SelectedItem).Tipo == "Gravidez" && (DadosForms.TipoPaciente == "Gestante"))
         {
             Action           acao   = new Action(() => { Lista.Items.Refresh(); });
             GravidezGestante Janela = new GravidezGestante((Diagnostico)Lista.SelectedItem, acao);
             JanelaServico.AbreJanela(Janela);
         }
     }
 }
        private void AbreCabecalho(object sender, RoutedEventArgs e)
        {
            string tipoPaciente = "";

            if (Gestante.IsChecked == true)
            {
                tipoPaciente = Gestante.Name;
            }
            else if (Puerpera.IsChecked == true)
            {
                tipoPaciente = Puerpera.Name;
            }
            else if (RecemNascido.IsChecked == true)
            {
                tipoPaciente = RecemNascido.Name;
            }
            else
            {
                MessageBox.Show("Por favor, marque uma opção antes de prosseguir.");
            }
            if (!string.IsNullOrEmpty(tipoPaciente))
            {
                DataClass DadosForms = new DataClass(tipoPaciente);
                Cabecalho cabecalho  = new Cabecalho(DadosForms);
                JanelaServico.AbreJanela(cabecalho);
            }
        }
Exemple #3
0
        private void AbreDiagnosticos(object sender, RoutedEventArgs e)
        {
            DadosForms.Nome     = Nome.Text;
            DadosForms.Registro = Registro.Text;
            DadosForms.Leito    = Leito.Text;
            DadosForms.Data     = Data.SelectedDate;
            DadosForms.Tipo     = Tipo.Text;
            DiagnosticosEIntervencoes diag = new DiagnosticosEIntervencoes(DadosForms);

            JanelaServico.AbreJanela(diag);
            JanelaServico.FechaJanela(this);
        }
 private void ConfirmareFechar(object sender, RoutedEventArgs e)
 {
     Confirmar(sender, e);
     JanelaServico.FechaJanela(this);
 }
 private void JanelaPrincipalFechada(object sender, EventArgs e)
 {
     JanelaServico.FechaTudo();
 }