提交测试,基本完成

This commit is contained in:
Mike Solar
2023-08-13 12:16:22 +08:00
parent b8da134809
commit 098e06a39b
40 changed files with 3219 additions and 1782 deletions

View File

@ -31,7 +31,13 @@ typedef struct tagRecord{
bool status;
}Record;
#include "netio.h"
struct Categrory
{
int id;
QString name;
bool display;
int sort;
};
class SQLiteHelper : public QObject
{
Q_OBJECT
@ -39,8 +45,16 @@ class SQLiteHelper : public QObject
public:
SQLiteHelper(QObject *parent = nullptr);
bool update_software();
bool insert_software(QString name, QString orig_name, QString path, QString sort, bool* categories);
bool edit_software(QString name, QString orig_name, QString path, QString sort, bool* categories,QString type="");
bool get_software(QList<ButtonStruct>* buttons, ConfigResponse* config_response);
bool update_app();
bool get_buttons(QList<ButtonStruct> &buttons);
bool get_category(QList<Categrory> &categrories);
bool set_category(QList<Categrory>& categrories);
bool get_all_software(QList<Record> &softwares,int category);
QSqlDatabase db;
~SQLiteHelper();
private:
@ -48,6 +62,5 @@ private:
QEventLoop eventLoop;
bool downloadSuccess;
QSqlDatabase db;
void cancelDownload();
};