30 lines
755 B
C++
30 lines
755 B
C++
#ifndef PRESENTER_H
|
|
#define PRESENTER_H
|
|
|
|
#include <QObject>
|
|
|
|
#include "apiclient.h"
|
|
#include "mainwindow.h"
|
|
|
|
class Presenter : public QObject
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
Presenter(QObject *parent = nullptr);
|
|
~Presenter();
|
|
|
|
private slots:
|
|
void onDevicesReceived(const QList<Device> &devices);
|
|
void onDepartmentsReceived(const QMap<int, Department> &departments);
|
|
void onDeviceModelsReceived(const QMap<int, DeviceModel> &deviceModels);
|
|
void onDeviceTypesReceived(const QMap<int, DeviceType> &deviceTypes);
|
|
void onManufacturersReceived(const QMap<int, Manufacturer> &manufacturers);
|
|
void onLocationsReceived(const QMap<int, Location> &locations);
|
|
|
|
private:
|
|
ApiClient *client;
|
|
MainWindow *window;
|
|
};
|
|
|
|
#endif // PRESENTER_H
|