Added checkbox for select all items from saved receipt.

This commit is contained in:
2019-07-14 15:53:58 +02:00
parent c8658ba77f
commit 4f2380f3db
4 changed files with 40 additions and 1 deletions
+5
View File
@@ -77,3 +77,8 @@ void ReceiptLoadForm::on_lineEdit_textChanged(const QString &text)
ui->tabVouchers->setCurrentIndex(matchingIndex);
}
}
void ReceiptLoadForm::on_selectAllCheck_clicked(bool checked)
{
m_itemModel->setSelectAll(checked);
}
+2
View File
@@ -22,6 +22,8 @@ public:
private slots:
void on_lineEdit_textChanged(const QString &text);
void on_selectAllCheck_clicked(bool checked);
private:
Ui::ReceiptLoadForm *ui;
AutoTableModel<Voucher> *m_voucherModel;
+15 -1
View File
@@ -50,7 +50,21 @@
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QTableView" name="tabItems"/>
<widget class="QCheckBox" name="selectAllCheck">
<property name="text">
<string>Select &amp;all</string>
</property>
</widget>
</item>
<item>
<widget class="QTableView" name="tabItems">
<property name="selectionMode">
<enum>QAbstractItemView::ExtendedSelection</enum>
</property>
<property name="selectionBehavior">
<enum>QAbstractItemView::SelectRows</enum>
</property>
</widget>
</item>
</layout>
</widget>