예제 #1
0
파일: oficina.cpp 프로젝트: roiso/unisys
void oficina::showNegos(){
    std::string origen=ui->comboOrigenFilter->currentText().toStdString();
    criterio.setOrigen(origen);
    std::string destino=ui->comboDestinoFilter->currentText().toStdString();
    criterio.setDestino(destino);
    bool fechaActivada=false;
    fechaActivada=ui->checkFecha->checkState();

    QTime time;
    time.setHMS(01,01,01);

    if(fechaActivada==true){
        ui->dateFechaFilter->setEnabled(true);
        ui->labelFechaFilter->setEnabled(true);

        QDate fecha;
        fecha=ui->dateFechaFilter->date();

        criterio.setFecha(fecha, time);
    }else{
        ui->dateFechaFilter->setEnabled(false);
        ui->labelFechaFilter->setEnabled(false);

        QDate date;
        date.setDate(1900,01,01);

        criterio.setFecha(date,time);
    }

    rellenarTabla(controller_->getNegos(), ui->tablaNegos, &criterio);
}
예제 #2
0
파일: log.cpp 프로젝트: roiso/unisys
void Log::showPeticiones(){
    this->limpiarLabel();

    std::string owner=ui->comboOwnerFilter->currentText().toStdString();
    criterio.setOwner(owner);
    std::string oficina=ui->comboOficinaFilter->currentText().toStdString();
    criterio.setOficina(oficina);
    std::string continente=ui->comboContinenteFilter->currentText().toStdString();
    criterio.setContinente(continente);
    std::string pais=ui->comboPais->currentText().toStdString();
    criterio.setPais(pais);
    std::string estado=ui->comboEstado->currentText().toStdString();
    qDebug()<<"current estado" << ui->comboEstado->currentText();
    criterio.setAceptada(estado);

    bool fechaActivada=false;
    fechaActivada=ui->checkFecha->checkState();

    QTime time;
    time.setHMS(01,01,01);
    QDateTime fecha;

    if(fechaActivada==true){
        ui->dateFechaFilter->setEnabled(true);
        ui->labelFechaFilter->setEnabled(true);

        QDate date;
        date=ui->dateFechaFilter->date();

        fecha.setDate(date);
        fecha.setTime(time);
        criterio.setPeticion(fecha);
    }else{
        ui->dateFechaFilter->setEnabled(false);
        ui->labelFechaFilter->setEnabled(false);

        QDate date;
        date.setDate(1900,01,01);

        fecha.setDate(date);
        fecha.setTime(time);
        criterio.setPeticion(fecha);
    }

    rellenarTabla(controller_->getPeticiones(), ui->tablePeticiones, &criterio);
}
예제 #3
0
void selectUserLogin::showUsers (){

    int iowner=ui->comboOwner->currentIndex();
    int owner= 0;
    if (buscarOwn.empty()!=true && iowner>0){
        owner=buscarOwn.at(iowner-1);
    }
    int ioficina=ui->comboOficina->currentIndex();
    int oficina = 0;
    if(buscarOfi.empty()!=true && ioficina>0){
        oficina=buscarOfi.at(ioficina-1);
    }

    criterio.setID_owner(owner);
    criterio.setID_oficina(oficina);

    rellenarTabla(controller_->getUsers(), ui->tableUser, &criterio);
}
예제 #4
0
void consultarNegos::showNegos(){
    rellenarTabla(controller_->getNegos(),ui->tablaNegos, &criterio);
}