mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-06-06 14:54:22 +00:00
Add dashboard audit log and configuration management
- Implemented dashboard audit logging with InsertAuditLog, GetRecentAuditLogs, GetAuditLogsByIP, and CleanupOldAuditLogs methods. - Created dashboard configuration management with GetDashboardConfig and SetDashboardConfig methods. - Added new tables for dashboard_audit_log and dashboard_config in both MySQL and SQLite migrations. - Updated CMakeLists to include Crow and ASIO for dashboard server functionality. - Enhanced existing database classes to support new dashboard features, including character, play key, and property management. - Added new methods for retrieving and managing play keys, properties, and pet names. - Updated TestSQLDatabase to include stubs for new dashboard-related methods. - Modified shared and dashboard configuration files for new settings.
This commit is contained in:
@@ -2,7 +2,10 @@
|
||||
#define __IBUGREPORTS__H__
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
#include <vector>
|
||||
#include <optional>
|
||||
|
||||
class IBugReports {
|
||||
public:
|
||||
@@ -14,7 +17,29 @@ public:
|
||||
LWOOBJID characterId{};
|
||||
};
|
||||
|
||||
struct DetailedInfo {
|
||||
uint64_t id{};
|
||||
std::string body;
|
||||
std::string clientVersion;
|
||||
std::string otherPlayer;
|
||||
std::string selection;
|
||||
LWOOBJID characterId{};
|
||||
uint64_t submitted{};
|
||||
uint64_t resolved_time{};
|
||||
uint32_t resolved_by_id{};
|
||||
std::string resolution;
|
||||
};
|
||||
|
||||
// Add a new bug report to the database.
|
||||
virtual void InsertNewBugReport(const Info& info) = 0;
|
||||
|
||||
// Dashboard methods
|
||||
virtual std::vector<DetailedInfo> GetAllBugReports() = 0;
|
||||
virtual std::vector<DetailedInfo> GetUnresolvedBugReports() = 0;
|
||||
virtual std::vector<DetailedInfo> GetResolvedBugReports() = 0;
|
||||
virtual std::optional<DetailedInfo> GetBugReportById(const uint64_t reportId) = 0;
|
||||
virtual void ResolveBugReport(const uint64_t reportId, const uint32_t resolvedById, const std::string_view resolution) = 0;
|
||||
virtual uint32_t GetBugReportCount() = 0;
|
||||
virtual uint32_t GetUnresolvedBugReportCount() = 0;
|
||||
};
|
||||
#endif //!__IBUGREPORTS__H__
|
||||
|
||||
Reference in New Issue
Block a user