Always target correct pipeline for cancel

What does this MR do and why?

Fixes a bug where reactive data from new pipelines coming into the UI (polling) caused the confirmation modal to target the newest pipeline when the modal was open (instead of the pipeline initially clicked). This MR ensures we don't use the reactive data but set a static pipeline that was clicked for cancel.

MR acceptance checklist

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

Screenshots or screen recordings

Screenshot_2024-08-09_at_11.52.55_AM

How to set up and validate locally

  1. Visit a project with pipelines
  2. Have a running pipeline and click cancel (leave the modal open)
  3. Start another pipeline while the modal is still open (via API request or new tab)
  4. Ensure that the modal data targets the pipeline where cancel was clicked and not the most recent pipeline fetched

Related to #478088 (closed)

Edited by Payton Burdette

Merge request reports

Loading