Fix Duo Chat buttons that do not work on multithreaded mode

What does this MR do and why?

This MR fixes buttons that do not currently work on Duo Chat multithreaded mode by setting the 'fromButton' flag.

References

Screenshots or screen recordings

N/A

How to set up and validate locally

Troubleshoot button

Prerequisites:

  • Vulnerability must be of sast type to receive the /vulnerability_explain command

Steps:

  1. Create vulnerability via UI:

  2. Update type in rails console:

# Convert to sast type
Vulnerability.last.update!(report_type: :sast)
  1. To skip complex setup, just hardcode this to true for now 😅
  2. Click on the vulnerability from the list and test the 'Explain with AI' button
  3. It should create a new thread

Explain with AI

  1. Go to any code file
  2. Select code
  3. Click the question mark
  4. It should create a new thread

image

View summary

  1. Go to an issue page
  2. Click 'view summary'
  3. It should create a new thread

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #526951 (closed)

Edited by Lesley Razzaghian

Merge request reports

Loading