WUT_Computer_Science/Programming/EGUI/lab1/blogsview.h

35 lines
611 B
C
Raw Normal View History

2022-04-04 21:22:50 +02:00
#ifndef BLOGSVIEW_H
#define BLOGSVIEW_H
#include <QMainWindow>
2022-04-06 19:44:14 +02:00
2022-04-04 21:22:50 +02:00
namespace Ui {
class blogsView;
}
class blogsView : public QMainWindow
{
Q_OBJECT
public:
explicit blogsView(QWidget *parent = nullptr);
~blogsView();
2022-04-05 00:26:36 +02:00
void setUserId(const QString &userId);
2022-04-05 14:07:24 +02:00
void setBlogId(const QString &blogId);
2022-04-04 21:22:50 +02:00
private slots:
2022-04-06 02:20:29 +02:00
void displayBlogEntries();
2022-04-06 19:44:14 +02:00
void exit();
2022-04-06 14:30:57 +02:00
2022-04-04 21:22:50 +02:00
private:
2022-04-06 19:44:14 +02:00
void defineConnections() const;
void displayBlogEntriesLoop(const QJsonArray &blogEntries);
void createNewBlogEntry();
2022-04-04 21:22:50 +02:00
Ui::blogsView *ui;
2022-04-05 00:26:36 +02:00
QString userId;
2022-04-05 14:07:24 +02:00
QString blogId;
2022-04-04 21:22:50 +02:00
};
#endif // BLOGSVIEW_H