15 #ifndef QGSQUERYBUILDER_H 16 #define QGSQUERYBUILDER_H 20 #include <QStandardItemModel> 21 #include <QSortFilterProxyModel> 22 #include <QStandardItem> 23 #include <QModelIndex> 24 #include "ui_qgsquerybuilderbase.h" 43 class GUI_EXPORT
QgsQueryBuilder :
public QDialog,
private Ui::QgsQueryBuilderBase
56 Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
60 void showEvent( QShowEvent *event )
override;
63 void setSql(
const QString &sqlStatement );
66 void accept()
override;
67 void reject()
override;
78 void setDatasourceDescription(
const QString &uri );
81 void btnEqual_clicked();
82 void btnLessThan_clicked();
83 void btnGreaterThan_clicked();
84 void btnPct_clicked();
86 void btnNotIn_clicked();
87 void btnLike_clicked();
88 void btnILike_clicked();
89 void lstFields_clicked(
const QModelIndex &index );
90 void lstFields_doubleClicked(
const QModelIndex &index );
91 void lstValues_doubleClicked(
const QModelIndex &index );
92 void btnLessEqual_clicked();
93 void btnGreaterEqual_clicked();
94 void btnNotEqual_clicked();
95 void btnAnd_clicked();
96 void btnNot_clicked();
98 void onTextChanged(
const QString &text );
104 void btnGetAllValues_clicked();
111 void btnSampleValues_clicked();
118 void populateFields();
125 void setupGuiViews();
126 void setupLstFieldsModel();
127 void fillValues(
int idx,
int limit );
131 QStandardItemModel *mModelFields =
nullptr;
133 QStandardItemModel *mModelValues =
nullptr;
135 QSortFilterProxyModel *mProxyValues =
nullptr;
137 int mPreviousFieldRow;
143 QString mOrigSubsetString;
145 #endif //QGSQUERYBUILDER_H
Query Builder for layers.
Represents a vector layer which manages a vector based data sets.