2021-12-30 10:27:03 +08:00
|
|
|
#ifndef OPERATIONLOG_H
|
|
|
|
#define OPERATIONLOG_H
|
|
|
|
|
|
|
|
#include <QStackedWidget>
|
|
|
|
#include <QTableWidget>
|
|
|
|
#include "../common/utils.h"
|
|
|
|
|
|
|
|
class OperationLog : public QStackedWidget
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2022-01-19 14:42:11 +08:00
|
|
|
enum Column_Index {
|
|
|
|
Backup_Name = 0,
|
|
|
|
UUID,
|
|
|
|
Operation,
|
|
|
|
Operation_Time,
|
|
|
|
};
|
2021-12-30 10:27:03 +08:00
|
|
|
explicit OperationLog(QWidget* parent = nullptr);
|
|
|
|
virtual ~OperationLog();
|
|
|
|
|
|
|
|
private:
|
|
|
|
void initFirstWidget();
|
|
|
|
void initOperationLogs(const QList<BackupWrapper>& list);
|
|
|
|
void setItem(int row, int column, const QString& text, int alignFlag = Qt::AlignLeft | Qt::AlignVCenter);
|
|
|
|
QString castTypeToString(int type);
|
|
|
|
|
|
|
|
QTableWidget *m_tableWidget;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // OPERATIONLOG_H
|