Example #1
0
 public static bool insertar(Hotel hotel)
 {
     string nombre = hotel.Nombre;
     string mail = hotel.Mail;
     int telefono = hotel.Telefono;
     string dir_calle = hotel.Direccion.calle_direccion;
     int dir_numero = hotel.Direccion.calle_altura;
     string ciudad = hotel.Ciudad;
     string pais = hotel.Pais;
     int estrellas = hotel.Estrellas;
     int recargo = hotel.Recargo;
     return executeProcedure("insertHotel", nombre, mail, telefono, dir_calle, dir_numero, ciudad, pais, estrellas, recargo);
 }
Example #2
0
 public logueo(Usuario a, Rol b,Hotel c)
 {
     User = a;
     Rol = b;
     Hotel= c;
 }
Example #3
0
 private static List<Hotel> tranductor(DataTable dataTable)
 {
     List<Hotel> lista = new List<Hotel>();
     if (dataTable != null)
     {
         foreach(DataRow fila in dataTable.Rows)
         {
             Hotel hotelito = new Hotel();
             hotelito.CodHotel = Convert.ToInt32(fila["codHotel"]);
             hotelito.Nombre = Convert.ToString(fila["nombreHotel"]);
             hotelito.Mail = Convert.ToString(fila["mail"]);
             hotelito.Telefono = Convert.ToInt32(fila["telefono"]);
             hotelito.Direccion.calle_direccion = Convert.ToString(fila["direccionCalle"]);
             hotelito.Direccion.calle_altura = Convert.ToInt32(fila["direccionNumero"]);
             hotelito.Ciudad = Convert.ToString(fila["ciudad"]);
             hotelito.Pais = Convert.ToString(fila["pais"]);
             hotelito.Estrellas = Convert.ToInt32(fila["cantEstrellas"]);
             lista.Add(hotelito);
         }
     }
     return lista;
 }