feat(side-conversations): side conversations#67
Merged
Conversation
Port side conversations from the Laravel reference. Adds SideConversation and SideConversationReply models + tables (private internal/email threads attached to a ticket, opened with a first reply, appendable, and closable) and a SideConversationService enforcing the rules: subject and body required, channel must be internal or email.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Ports side conversations from the Laravel reference, closing WordPress''s last core-engine parity gap.
What
SideConversation+SideConversationReplymodels + tables (escalated_side_conversations,escalated_side_conversation_repliesvia dbDelta): private internal/email threads attached to a ticket. A conversation opens with a first reply, replies append, and it can be closed. Channel ∈ {internal,email}; statusopen→closed. Purevalid_channel()helper.SideConversationService— mirrors the LaravelSideConversationController:create()(validates subject/channel/body, opens with first reply),add_reply(),close(),for_ticket()(newest first, replies attached).Verification
php -lclean on all files.vendor/bin/pint --test(the lint CI gate) passes on all changed files.Test_Side_Conversation_Service— purevalid_channeltest + live-wpdb flow (create opens with first reply; rejects empty subject/body + bad channel; reply + close; for_ticket attaches replies newest-first). Runs in CI against the WP test harness.