Skip to content

Added code field to SystemLog#6

Merged
Patabugen merged 7 commits intomainfrom
feature/add-system-log-codes
Jan 26, 2026
Merged

Added code field to SystemLog#6
Patabugen merged 7 commits intomainfrom
feature/add-system-log-codes

Conversation

@Patabugen
Copy link
Copy Markdown
Member

This PR adds a code field/attribute to SystemLogs, along with columns/tables.

The code is for a shared grouping of similar SystemLogs which might have different messages (e.g. SYNC_ERROR).

The use-case I'm adding it for is to be able to send an email when a SystemLog is created based on the code.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a code field to the SystemLog model to enable grouping of similar log entries that may have different messages (e.g., SYNC_ERROR). The implementation includes database migration, model updates, API changes, and UI integration.

Key changes:

  • Added nullable code string field to the SystemLog model with database column and index
  • Updated the addSystemLog() method signature to accept an optional code parameter
  • Added code column and filter to the Filament admin table interface

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
database/migrations/create_system_log_table.php.stub Adds nullable indexed code column to system_logs table
src/Models/SystemLog.php Adds code property to model docblock and fillable array
src/Concerns/HasSystemLogger.php Adds optional $code parameter to addSystemLog() method
src/Stubs/Filament/PanelName/Resources/SystemLogs/Tables/SystemLogsTable.php Adds code column and filter to Filament table interface
README.md Documents the new code field in the SystemLog properties table
CHANGELOG.md Records the addition of the code field in version 1.2

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread README.md Outdated
Comment thread src/Concerns/HasSystemLogger.php Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Concerns/HasSystemLogger.php Outdated
Comment thread src/Concerns/HasSystemLoggerAssertions.php Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Concerns/HasSystemLoggerAssertions.php Outdated
Comment thread tests/Feature/Concerns/HasSystemLoggerTest.php
@jamesmpigott jamesmpigott self-requested a review January 14, 2026 09:14
@Patabugen Patabugen merged commit 75afce8 into main Jan 26, 2026
10 checks passed
@Patabugen Patabugen deleted the feature/add-system-log-codes branch January 26, 2026 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants