- Added a new modal for reporting bugs, including fields for describing the issue and attaching files. - Implemented backend API for creating bug reports, including rate limiting and metadata logging. - Introduced a new database table to track bug report submissions for auditing purposes. - Enhanced the frontend to capture screenshots automatically and allow manual file uploads. - Added error handling and user feedback for the bug reporting process. - Updated existing templates and scripts to integrate the new bug reporting functionality.
16 lines
611 B
SQL
16 lines
611 B
SQL
-- Track bug report submissions for rate limiting and auditing.
|
|
|
|
CREATE TABLE IF NOT EXISTS bug_report_submissions (
|
|
id SERIAL PRIMARY KEY,
|
|
sag_id INTEGER NOT NULL REFERENCES sag_sager(id) ON DELETE CASCADE,
|
|
user_id INTEGER NOT NULL REFERENCES users(user_id) ON DELETE CASCADE,
|
|
screenshot_attached BOOLEAN DEFAULT FALSE,
|
|
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
|
|
);
|
|
|
|
CREATE INDEX IF NOT EXISTS idx_bug_report_submissions_user_time
|
|
ON bug_report_submissions(user_id, created_at DESC);
|
|
|
|
CREATE INDEX IF NOT EXISTS idx_bug_report_submissions_sag
|
|
ON bug_report_submissions(sag_id);
|