public function buscaTipoAcomodacoes() { $_sql = sprintf("\tSELECT COUNT(DISTINCT(h.tipo_acomodacao)) AS tipos \n\t\t\t\t\t\t\tFROM evnts_hotel h, evnts_hotel_evento he\n\t\t\t\t\t\t\tWHERE he.id_evento = %d\n\t\t\t\t\t\t\tAND h.situacao like 'A'\n\t\t\t\t\t\t\tAND he.id_hotel = h.id_hotel;", $this->_evento); $arr = parent::carrega_linha($_sql); return (int) $arr["tipos"]; }
public function __construct() { $this->conexao = BancoPDO::conexao(); }
function contar() { $mySQL = new BancoPDO(); $sql = "SELECT * FROM clientequartos"; $rs = $mySQL->contalinha($sql); //echo $sql; $mySQL->disconnect; return $rs; }
public function buscaHotelQuartos() { $_sql = sprintf("SELECT *\n\t\t\t\t \t\t FROM evnts_hotel_quarto\n\t\t\t\t\t\t WHERE id_hotel = %d;", $this->_hotel); return parent::carrega($_sql); }