20#ifndef ORES_QT_LEI_ENTITY_PICKER_HPP
21#define ORES_QT_LEI_ENTITY_PICKER_HPP
28#include <QStandardItemModel>
29#include <QSortFilterProxyModel>
30#include "ores.qt/ClientManager.hpp"
31#include "ores.logging/make_logger.hpp"
46 inline static std::string_view logger_name =
47 "ores.qt.lei_entity_picker";
49 [[nodiscard]]
static auto& lg() {
51 static auto instance = make_logger(logger_name);
57 QWidget* parent =
nullptr);
107 void onSearchTextChanged(
const QString& text);
108 void onCountryFilterChanged(
int index);
109 void onSelectionChanged();
114 void loadEntitiesForCountry(
const QString& country);
117 QLineEdit* searchEdit_;
118 QComboBox* countryFilter_;
119 QTableView* tableView_;
120 QStandardItemModel* model_;
121 QSortFilterProxyModel* proxyModel_;
122 QLabel* statusLabel_;
123 QString selectedLei_;
124 QString selectedName_;
125 bool countriesLoaded_ =
false;
Implements logging infrastructure for ORE Studio.
Definition boost_severity.hpp:28
Qt-based graphical user interface for ORE Studio.
Definition AboutDialog.hpp:29
Manages the lifecycle of the NATS client and login state.
Definition ClientManager.hpp:109
Reusable widget for searching and selecting an LEI entity.
Definition LeiEntityPicker.hpp:42
bool hasSelection() const
Check whether an entity is currently selected.
Definition LeiEntityPicker.cpp:138
void selectionCleared()
Emitted when the selection is cleared.
void load()
Trigger an asynchronous load of LEI entities from the server.
Definition LeiEntityPicker.cpp:142
QString selectedName() const
Get the entity legal name of the currently selected entity.
Definition LeiEntityPicker.cpp:134
void loadCompleted(int entityCount)
Emitted when entities are successfully loaded from the server.
QString selectedLei() const
Get the LEI of the currently selected entity.
Definition LeiEntityPicker.cpp:130
void entitySelected(const QString &lei, const QString &name)
Emitted when the user selects an entity.
void loadFailed(const QString &errorMessage)
Emitted when loading entities fails.