This commit is contained in:
2026-02-07 08:28:56 +03:00
parent eff857a55e
commit 451ddd9ae0
30 changed files with 3993 additions and 1233 deletions
+29
View File
@@ -13,6 +13,7 @@
#include <QTableWidget>
#include "timerinfo.h"
#include "webserverchat.h"
#include "webservernotify.h"
struct ChatSettings {
int id;
@@ -35,6 +36,28 @@ struct ChatSettings {
bool deleteByTime;
};
struct NotificationSettings {
int id;
QString name;
QString type;
int port;
QString blockColor;
QString borderColor;
int borderSize;
int transparency;
QString pageBackgroundColor;
QString titleFamily;
int titleSize;
QString titleColor;
QString contentFamily;
int contentSize;
QString contentColor;
int duration;
QDateTime createdAt;
};
class uDataBase : public QObject
{
Q_OBJECT
@@ -84,6 +107,12 @@ public:
bool deleteChat(int port);
QList<ChatSettings> loadAllChats();
// Методы для уведомлений
bool createNotificationsTable();
bool saveNotification(const QString &name, HttpServer *server);
bool updateNotification(const QString &name, HttpServer *server, int oldPort);
QList<NotificationSettings> loadAllNotifications();
bool deleteNotification(int port);
// Проверка подключения к БД
bool isConnected() const;