Skip to content
This repository was archived by the owner on Sep 3, 2025. It is now read-only.

Conversation

@whitdog47
Copy link
Contributor

@whitdog47 whitdog47 commented Nov 23, 2024

This feature enhancement introduces the ability to add users to a threaded case in Slack when they are mentioned. This functionality aims to streamline collaboration by ensuring that all relevant participants are included in the case discussions.

Key Changes:

  1. New Enum Values:

    • Added add_user and do_nothing actions to CaseNotificationActions in enums.py.
  2. User Mention Handling:

    • Implemented handle_user_mention function in case/interactive.py to detect user mentions in messages.
    • Extracts mentioned users and checks if they are part of the case.
    • Sends a private message to the user who mentioned others, offering to add the mentioned users to the case.
  3. User Addition Workflow:

    • Added add_users_to_case function to handle the addition of users to a case when the "Add Them" button is clicked.
    • Utilizes AddUserMetadata to manage user data and case context.
  4. Middleware Enhancements:

    • Introduced add_user_middleware in middleware.py to process user addition requests.
    • Ensures the correct context is passed for user addition actions.
  5. UI Components:

    • Created UI blocks for user notification and action buttons in Slack messages.
    • Utilized DefaultBlockIds for consistent block identification.
  6. Model Updates:

    • Added AddUserMetadata class in models.py to encapsulate user and case metadata.
image

@whitdog47 whitdog47 added the enhancement New feature or request label Nov 23, 2024
@whitdog47 whitdog47 requested a review from wssheldon November 23, 2024 01:18
@whitdog47 whitdog47 self-assigned this Nov 23, 2024
@whitdog47 whitdog47 requested a review from wssheldon November 25, 2024 17:37
@whitdog47 whitdog47 merged commit 4d78bcf into master Nov 25, 2024
8 checks passed
@whitdog47 whitdog47 deleted the enhancement/add-to-threaded-case branch November 25, 2024 23:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants