public List<Model.TipoServicioModel> buscarTiposServicio()
 {
     List<Model.TipoServicioModel> tiposServicio = new List<Model.TipoServicioModel>();
     SqlConnection myConnection = null;
     try
     {
         myConnection = new SqlConnection(stringConexion);
         myConnection.Open();
         SqlCommand command = null;
         var query = "SELECT id_tipo_servicio, tipo_servicio,costo_adicional FROM MONDONGO.TIPOS_SERVICIO ";
         command = new SqlCommand(query, myConnection);
         using (SqlDataReader reader = command.ExecuteReader())
         {
             while (reader.Read())
             {
                 Model.TipoServicioModel ts = new Model.TipoServicioModel();
                 ts.id = (int)(double)reader.GetDecimal(0);
                 ts.tipoServicio = reader.GetString(1);
                 ts.costoAdicional = (int)(double)reader.GetDecimal(2);
                 tiposServicio.Add(ts);
             }
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show("ERROR" + ex.Message);
     }
     finally
     {
         myConnection.Close();
     }
     return tiposServicio;
 }
        private void btnBuscar_Click(object sender, EventArgs e)
        {
            tipoServicioSeleccionado = cbTipoServicio.SelectedItem as Model.TipoServicioModel;
            Model.RutaModel ruta = rutaController.buscarRuta(ciudadOrigen.ciudadId, ciudadDestino.ciudadId, tipoServicioSeleccionado.id);
            if (ruta != null)
            {
                vuelosEncontrados = viajeController.buscarViajes(ruta.idRuta, tbMatricula.Text, dpFechaSalida.Value);
                if (vuelosEncontrados.Count > 0)
                {
                    gbViajes.Enabled = true;
                    dgvViajes.DataSource = vuelosEncontrados;
                    dgvViajes.SelectionMode = DataGridViewSelectionMode.FullRowSelect;

                    dgvViajes.Columns[0].HeaderText = "Id. de Viaje";
                    dgvViajes.Columns[0].ReadOnly = true;
                    dgvViajes.Columns[0].Width = 75;

                    dgvViajes.Columns[1].HeaderText = "Fecha Salida";
                    dgvViajes.Columns[1].ReadOnly = true;
                    dgvViajes.Columns[1].Width = 135;

                    dgvViajes.Columns[2].HeaderText = "Fecha Llegada Estimada";
                    dgvViajes.Columns[2].ReadOnly = true;
                    dgvViajes.Columns[2].Width = 135;

                    dgvViajes.Columns[3].Visible = false;

                }
                else
                {
                    MessageBox.Show("No existe ningun vuelo para los parámetros ingresados.", "Búsqueda de viajes", MessageBoxButtons.OK);
                }
            }
            else
            {
                MessageBox.Show("No existe ningun vuelo entre las ciudades pedidas.", "Búsqueda de viajes", MessageBoxButtons.OK);
            }
        }