Update 更新文档

This commit is contained in:
2026-02-25 23:01:42 +08:00
parent 40aff32fb0
commit 80518309a7
679 changed files with 4611263 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
#ifndef HISTORYORDERDIALOG_H
#define HISTORYORDERDIALOG_H
#include <QDialog>
#include <QStandardItemModel>
#include <QSortFilterProxyModel>
#include <QStyledItemDelegate>
#include <QDateEdit>
#include <QTableView>
#include <QComboBox>
#include <QLineEdit>
#include <QPushButton>
#include <QLabel>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QMutex>
#include <QString>
#include "ordertypedelegate.h"
class QHistoryOrderDialog : public QDialog
{
Q_OBJECT
public:
explicit QHistoryOrderDialog(QWidget *parent = nullptr);
~QHistoryOrderDialog() = default;
private slots:
void onDateChanged(const QDate &date);
void onFilterChanged();
void onExportClicked();
private:
void initUI();
void loadOrdersForDate(const QDate &date);
void updateStatistics(const QList<QSharedPointer<class BigOrderInfo>>& orders);
QString m_historyPath;
QList<QSharedPointer<BigOrderInfo>> getHistoryOrders(const QDate& date) const;
QList<QDate> getAvailableDates() const;
QDateEdit *m_dateSelector;
QComboBox *m_orderTypeFilter;
QLineEdit *m_stockCodeFilter;
QTableView *m_tableView;
QPushButton *m_exportButton;
QLabel *m_statsLabel;
QStandardItemModel *m_model;
QSortFilterProxyModel *m_proxyModel;
NumberFormatDelegate *m_numberDelegate;
OrderTypeDelegate *m_typeDelegate;
mutable QMutex m_cacheMutex;
mutable QMap<QDate, QList<QSharedPointer<BigOrderInfo>>> m_historyCache;
};
#endif