prospect::prospect(QWidget* parent, const char* name, Qt::WFlags fl) : XWidget(parent, name, fl) { setupUi(this); connect(_crmacct, SIGNAL(clicked()), this, SLOT(sCrmAccount())); connect(_deleteQuote, SIGNAL(clicked()), this, SLOT(sDeleteQuote())); connect(_editQuote, SIGNAL(clicked()), this, SLOT(sEditQuote())); connect(_newQuote, SIGNAL(clicked()), this, SLOT(sNewQuote())); connect(_number, SIGNAL(editingFinished()), this, SLOT(sCheckNumber())); connect(_printQuote, SIGNAL(clicked()), this, SLOT(sPrintQuote())); connect(_quotes, SIGNAL(populateMenu(QMenu*,QTreeWidgetItem*)), this, SLOT(sPopulateQuotesMenu(QMenu*))); connect(_save, SIGNAL(clicked()), this, SLOT(sSave())); connect(_viewQuote, SIGNAL(clicked()), this, SLOT(sViewQuote())); connect(omfgThis, SIGNAL(quotesUpdated(int, bool)), this, SLOT(sFillQuotesList())); if (_privileges->check("MaintainQuotes")) connect(_quotes, SIGNAL(itemSelected(int)), _editQuote, SLOT(animateClick())); else connect(_quotes, SIGNAL(itemSelected(int)), _viewQuote, SLOT(animateClick())); _prospectid = -1; _crmacctid = -1; _taxzone->setAllowNull(true); _taxzone->setType(XComboBox::TaxZones); _quotes->addColumn(tr("Quote #"), _orderColumn, Qt::AlignLeft, true, "quhead_number" ); _quotes->addColumn(tr("Quote Date"), _dateColumn, Qt::AlignLeft, true, "quhead_quotedate" ); _NumberGen = -1; }
user::user(QWidget* parent, const char * name, Qt::WindowFlags fl) : XDialog(parent, name, fl) { setupUi(this); _authCache = false; _cUsername = ""; _crmacctid = -1; _inTransaction = false; _mode = cView; connect(_close, SIGNAL(clicked()), this, SLOT(sClose())); connect(_crmacct, SIGNAL(clicked()), this, SLOT(sCrmAccount())); connect(_save, SIGNAL(clicked()), this, SLOT(sSave())); connect(_add, SIGNAL(clicked()), this, SLOT(sAdd())); connect(_addAll, SIGNAL(clicked()), this, SLOT(sAddAll())); connect(_revoke, SIGNAL(clicked()), this, SLOT(sRevoke())); connect(_revokeAll, SIGNAL(clicked()), this, SLOT(sRevokeAll())); connect(_module, SIGNAL(activated(const QString&)), this, SLOT(sModuleSelected(const QString&))); connect(_granted, SIGNAL(itemSelected(int)), this, SLOT(sRevoke())); connect(_available, SIGNAL(itemSelected(int)), this, SLOT(sAdd())); connect(_username, SIGNAL(editingFinished()), this, SLOT(sCheck())); connect(_enhancedAuth, SIGNAL(toggled(bool)), this, SLOT(sEnhancedAuthUpdate())); connect(_grantedGroup, SIGNAL(itemSelected(int)), this, SLOT(sRevokeGroup())); connect(_availableGroup, SIGNAL(itemSelected(int)), this, SLOT(sAddGroup())); connect(_addGroup, SIGNAL(clicked()), this, SLOT(sAddGroup())); connect(_revokeGroup, SIGNAL(clicked()), this, SLOT(sRevokeGroup())); connect(_grantedSite, SIGNAL(itemSelected(int)), this, SLOT(sRevokeSite())); connect(_availableSite, SIGNAL(itemSelected(int)), this, SLOT(sAddSite())); connect(_addSite, SIGNAL(clicked()), this, SLOT(sAddSite())); connect(_revokeSite, SIGNAL(clicked()), this, SLOT(sRevokeSite())); _available->addColumn("Available Privileges", -1, Qt::AlignLeft); _granted->addColumn("Granted Privileges", -1, Qt::AlignLeft); _availableGroup->addColumn("Available Roles", -1, Qt::AlignLeft); _grantedGroup->addColumn("Granted Roles", -1, Qt::AlignLeft); _availableSite->addColumn("Available Sites", -1, Qt::AlignLeft); _grantedSite->addColumn("Granted Sites", -1, Qt::AlignLeft); _locale->setType(XComboBox::Locales); XSqlQuery modq; modq.exec( "SELECT DISTINCT priv_module FROM priv ORDER BY priv_module;" ); for (int i = 0; modq.next(); i++) _module->append(i, modq.value("priv_module").toString()); if(_evaluation == true) { _enhancedAuth->setEnabled(false); _passwd->setEnabled(false); _verify->setEnabled(false); } if (!_metrics->boolean("MultiWhs")) _tab->removeTab(_tab->indexOf(_siteTab)); }
taxAuthority::taxAuthority(QWidget* parent, const char* name, bool modal, Qt::WFlags fl) : XDialog(parent, name, modal, fl) { setupUi(this); connect(_code, SIGNAL(editingFinished()), this, SLOT(sCheck())); connect(_crmacct, SIGNAL(clicked()), this, SLOT(sCrmAccount())); connect(_save, SIGNAL(clicked()), this, SLOT(sSave())); _crmacctid = -1; _mode = cView; _taxauthid = -1; _NumberGen = -1; }
employee::employee(QWidget* parent, const char * name, Qt::WindowFlags fl) : XDialog(parent, name, fl) { setupUi(this); connect(_attachGroup, SIGNAL(clicked()), this, SLOT(sAttachGroup())); connect(_code, SIGNAL(editingFinished()), this, SLOT(sHandleButtons())); connect(_crmacct, SIGNAL(clicked()), this, SLOT(sCrmAccount())); connect(_deleteCharass, SIGNAL(clicked()), this, SLOT(sDeleteCharass())); connect(_detachGroup, SIGNAL(clicked()), this, SLOT(sDetachGroup())); connect(_editCharass, SIGNAL(clicked()), this, SLOT(sEditCharass())); connect(_editGroup, SIGNAL(clicked()), this, SLOT(sEditGroup())); connect(_newCharass, SIGNAL(clicked()), this, SLOT(sNewCharass())); connect(_save, SIGNAL(clicked()), this, SLOT(sSave())); connect(_viewGroup, SIGNAL(clicked()), this, SLOT(sViewGroup())); XSqlQuery xtmfg; xtmfg.exec("SELECT pkghead_name FROM pkghead WHERE pkghead_name='xtmfg'"); if (xtmfg.first()) { _shift->setEnabled(true); _shift->setVisible(true); shiftLit->setVisible(true); } else { _shift->setEnabled(false); _shift->setVisible(false); shiftLit->setVisible(false); } _charass->addColumn(tr("Characteristic"), _itemColumn, Qt::AlignLeft, true, "char_name"); _charass->addColumn(tr("Value"), -1, Qt::AlignLeft, true, "charass_value"); _groups->addColumn(tr("Name"), _itemColumn, Qt::AlignLeft, true, "empgrp_name"); _groups->addColumn(tr("Description"), -1, Qt::AlignLeft, true, "empgrp_descrip"); _wagetype->setAllowNull(false); _wagetype->append(0, tr("Hourly"), "H"); _wagetype->append(1, tr("Salaried"), "S"); _per->setAllowNull(false); _per->append(0, tr("Hour"), "H"); _per->append(1, tr("Day"), "D"); _per->append(2, tr("Week"), "W"); _per->append(3, tr("Bi-Weekly"), "BW"); _per->append(4, tr("Month"), "M"); _per->append(5, tr("Year"), "Y"); _per->setAllowNull(false); _perExt->append(0, tr("Hour"), "H"); _perExt->append(1, tr("Day"), "D"); _perExt->append(2, tr("Week"), "W"); _perExt->append(3, tr("Bi-Weekly"), "BW"); _perExt->append(4, tr("Month"), "M"); _perExt->append(4, tr("Year"), "Y"); _comments->setId(-1); _comments->setReadOnly(true); _crmacctid = -1; _empid = -1; _NumberGen = -1; _mode = cView; _origmode = cView; }
vendor::vendor(QWidget* parent, const char* name, Qt::WFlags fl) : XWidget(parent, name, fl) { setupUi(this); connect(_crmacct, SIGNAL(clicked()), this, SLOT(sCrmAccount())); connect(_save, SIGNAL(clicked()), this, SLOT(sSave())); connect(_printAddresses, SIGNAL(clicked()), this, SLOT(sPrintAddresses())); connect(_newAddress, SIGNAL(clicked()), this, SLOT(sNewAddress())); connect(_editAddress, SIGNAL(clicked()), this, SLOT(sEditAddress())); connect(_viewAddress, SIGNAL(clicked()), this, SLOT(sViewAddress())); connect(_deleteAddress, SIGNAL(clicked()), this, SLOT(sDeleteAddress())); connect(_deleteTaxreg, SIGNAL(clicked()), this, SLOT(sDeleteTaxreg())); connect(_editTaxreg, SIGNAL(clicked()), this, SLOT(sEditTaxreg())); connect(_newTaxreg, SIGNAL(clicked()), this, SLOT(sNewTaxreg())); connect(_viewTaxreg, SIGNAL(clicked()), this, SLOT(sViewTaxreg())); connect(_next, SIGNAL(clicked()), this, SLOT(sNext())); connect(_previous, SIGNAL(clicked()), this, SLOT(sPrevious())); connect(_mainButton, SIGNAL(clicked()), this, SLOT(sHandleButtons())); connect(_altButton, SIGNAL(clicked()), this, SLOT(sHandleButtons())); connect(_checksButton, SIGNAL(clicked()), this, SLOT(sHandleButtons())); connect(_number, SIGNAL(textEdited(const QString&)), this, SLOT(sNumberEdited())); connect(_number, SIGNAL(editingFinished()), this, SLOT(sCheck())); connect(_newCharacteristic, SIGNAL(clicked()), this, SLOT(sNewCharacteristic())); connect(_editCharacteristic, SIGNAL(clicked()), this, SLOT(sEditCharacteristic())); connect(_deleteCharacteristic,SIGNAL(clicked()), this, SLOT(sDeleteCharacteristic())); connect(_address, SIGNAL(addressChanged(QString,QString,QString,QString,QString,QString, QString)), _contact2, SLOT(setNewAddr(QString,QString,QString,QString,QString,QString, QString))); connect(_address, SIGNAL(addressChanged(QString,QString,QString,QString,QString,QString, QString)), _contact1, SLOT(setNewAddr(QString,QString,QString,QString,QString,QString, QString))); _defaultCurr->setLabel(_defaultCurrLit); QRegExp tmpregex = QRegExp(_metrics->value("EFTAccountRegex")); _accountValidator = new QRegExpValidator (tmpregex, this); tmpregex = QRegExp(_metrics->value("EFTRoutingRegex")); _routingValidator = new QRegExpValidator(tmpregex, this); _routingNumber->setValidator(_routingValidator); _achAccountNumber->setValidator(_accountValidator); _vendaddr->addColumn(tr("Number"), 70, Qt::AlignLeft, true, "vendaddr_code"); _vendaddr->addColumn(tr("Name"), 50, Qt::AlignLeft, true, "vendaddr_name"); _vendaddr->addColumn(tr("City"), -1, Qt::AlignLeft, true, "addr_city"); _vendaddr->addColumn(tr("State"), -1, Qt::AlignLeft, true, "addr_state"); _vendaddr->addColumn(tr("Country"), -1, Qt::AlignLeft, true, "addr_country"); _vendaddr->addColumn(tr("Postal Code"), -1, Qt::AlignLeft, true, "addr_postalcode"); _taxreg->addColumn(tr("Tax Authority"), 100, Qt::AlignLeft, true, "taxauth_code"); _taxreg->addColumn(tr("Tax Zone"), 100, Qt::AlignLeft, true, "taxzone_code"); _taxreg->addColumn(tr("Registration #"), -1, Qt::AlignLeft, true, "taxreg_number"); _charass->addColumn(tr("Characteristic"), _itemColumn, Qt::AlignLeft, true, "char_name" ); _charass->addColumn(tr("Value"), -1, Qt::AlignLeft, true, "charass_value" ); _accountType->append(0, "Checking", "K"); _accountType->append(1, "Savings", "C"); _transmitStack->setCurrentIndex(0); if (_metrics->boolean("EnableBatchManager") && ! (_metrics->boolean("ACHSupported") && _metrics->boolean("ACHEnabled"))) { _checksButton->hide(); } else if (! _metrics->boolean("EnableBatchManager") && (_metrics->boolean("ACHSupported") && _metrics->boolean("ACHEnabled"))) { _checksButton->hide(); _transmitStack->setCurrentIndex(1); } else if (! _metrics->boolean("EnableBatchManager") && ! (_metrics->boolean("ACHSupported") && _metrics->boolean("ACHEnabled"))) ediTab->setVisible(false); // else defaults are OK if (_metrics->boolean("ACHSupported") && _metrics->boolean("ACHEnabled") && omfgThis->_key.isEmpty()) _checksButton->setEnabled(false); _account->setType(GLCluster::cRevenue | GLCluster::cExpense | GLCluster::cAsset | GLCluster::cLiability); _vendid = -1; _crmacctid = -1; _ignoreClose = false; _NumberGen = -1; }