If macro EET is not defined EET functions will be hidden.

This commit is contained in:
2023-06-02 15:04:53 +02:00
parent 8b132c6c51
commit 93eb98c10a
8 changed files with 105 additions and 8 deletions
+9 -1
View File
@@ -47,12 +47,20 @@ PaydVouchersDialog::PaydVouchersDialog(QWidget *parent) :
ui->tableItems->setColumnHidden(0, true);
ui->tableItems->verticalScrollBar()->setStyleSheet("QScrollBar:vertical { width: 30px; }");
#ifndef EET
ui->btnEetNotSen->setVisible(false);
ui->btnSendEet->setVisible(false);
ui->label_2->setVisible(false);
ui->lblEetStatus->setVisible(false);
#endif
ShopService srv;
m_voucherModel->setData(srv.paiedVouchers());
ui->tableVouchers->sortByColumn(0,Qt::AscendingOrder);
ui->tableVouchers->verticalScrollBar()->setStyleSheet("QScrollBar:vertical { width: 30px; }");
connect(ui->tableVouchers->selectionModel(), &QItemSelectionModel::currentRowChanged, [this, &srv](const QModelIndex &current, const QModelIndex &) {
connect(ui->tableVouchers->selectionModel(), &QItemSelectionModel::currentRowChanged, [this](const QModelIndex &current, const QModelIndex &) {
ShopService srv;
QSharedPointer<Voucher> voucher = m_voucherModel->itemFromIndex(current);
if (voucher->items().isEmpty()) {
srv.load(voucher);