void AccountsComponent::receivedResults(QueryEntry *qe_) { if (qe_->num_fields > 1) { if (qe_->request.startsWith("SELECT * FROM events WHERE ")) { qe = qe_; AccountsTableListBoxModel->setQueryEntry(qe); // AccountsTableListBoxModel->update(); } else { qeTransactions = qe_; AccountsTableListBoxModel->setQueryEntryForTransactions(qeTransactions); AccountsTableListBoxModel->update(); } } else { // if update if (AccountsTableListBoxModel->savedpks.size()) { // fix this v StringArray pk = AccountsTableListBoxModel->savedpks[0]; AccountsTableListBoxModel->wasSaved(pk); } // if delete else { searchButtonPressed(); } } addOverlayComp->setVisible(false); }
TableData::TableData( QWidget *parent) : QWidget(parent), ui(new Ui::TableData) { ui->setupUi(this); this->multiSampleMode =false; dw = 500; statsText = new QString(); titleLabel = this->findChild<QLabel *>("titleLabel"); tableWidget = this->findChild<QTableWidget *>("tableWidget"); searchButton = this->findChild<QPushButton *>("searchButton"); exportButton = this->findChild<QPushButton *>("exportButton"); alpha = this->findChild<QComboBox *>("alphaValue"); lcaDepth = this->findChild<QSpinBox *>("lcaDepth"); functionTable = this->findChild<QPushButton *>("functionTable"); connect(searchButton, SIGNAL(clicked()), this, SLOT(searchButtonPressed())); connect(exportButton, SIGNAL(clicked()), this, SLOT(exportButtonPressed())); #ifdef DISABLE_LCASTAR connect(alpha, SIGNAL(currentIndexChanged(int)) , this, SLOT(updateLCAStar(int)) ); connect(lcaDepth, SIGNAL(valueChanged(int)) , this, SLOT(updateLCAStar(int)) ); #else alpha->hide(); lcaDepth->hide(); #endif connect(tableWidget->verticalScrollBar(), SIGNAL(valueChanged(int)), this, SLOT(outputRows(int))); connect(tableWidget->horizontalHeader(), SIGNAL(sectionClicked(int)), this, SLOT(headerClicked(int))); // this->searchWidget = new SearchWidget(this); // this->searchWidget->hide(); connect(functionTable, SIGNAL(clicked()), this, SLOT(spawnFunctionTable()) ); #ifdef SECTION tableWidget->horizontalHeader()->sectionResizeMode(QHeaderView::Stretch); tableWidget->verticalHeader()->sectionResizeMode(QHeaderView::Stretch); #else tableWidget->horizontalHeader()->setResizeMode(QHeaderView::Interactive); // tableWidget->horizontalHeader()->setResizeMode(QHeaderView::Stretch); tableWidget->verticalHeader()->setResizeMode(QHeaderView::Stretch); #endif //this->exportBox = new ExportBox(this); //this->exportBox->hide(); this->p =0; this->g =0; this->exportType = OTHERSTABLEEXP; this->addLCAStar = false; }