Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.9] [Cases] Fix bug in cases bulk action in the alerts table (#160526) #160543

Merged
merged 2 commits into from Jun 26, 2023

Conversation

kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 8.9:

Questions ?

Please refer to the Backport tool documentation

)

## Summary

In 8.8 we move the logic of the cases action from solutions to the
alerts table. A bug was introduced when you try to attach an alert to a
new case through the cases modal.

Before

https://github.com/elastic/kibana/assets/7871006/771a5d28-e279-43d4-b72e-2dfb6689bae6

Error in `console`

```
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'id')
    at getAttachments (use_bulk_actions.ts:100:1)
    at use_cases_add_to_existing_case_modal.tsx:52:1
    at onRowClick (use_cases_add_to_existing_case_modal.tsx:107:1)
    at all_cases_selector_modal.tsx:36:1
    at all_cases_list.tsx:208:1
    at table_filters.tsx:128:1
    at HTMLUnknownElement.callCallback (react-dom.development.js:3945:1)
    at Object.invokeGuardedCallbackDev (react-dom.development.js:3994:1)
    at invokeGuardedCallback (react-dom.development.js:4056:1)
    at invokeGuardedCallbackAndCatchFirstError (react-dom.development.js:4070:1)
```

After

https://github.com/elastic/kibana/assets/7871006/89e44018-49cf-41f7-8e07-01c6eb197624

### Checklist

Delete any items that are not applicable to this PR.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### For maintainers

- [x] This was checked for breaking API changes and was [labeled
appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

## Release notes
Fix a bug in the alerts table where you cannot create a new case when
attaching alerts to a case from the cases modal

(cherry picked from commit df21ba0)
@cnasikas
Copy link
Member

@elasticmachine merge upstream

@kibanamachine kibanamachine merged commit 769d6a3 into elastic:8.9 Jun 26, 2023
21 checks passed
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
triggersActionsUi 1.4MB 1.4MB +100.0B
Unknown metric groups

ESLint disabled line counts

id before after diff
enterpriseSearch 13 15 +2
securitySolution 416 420 +4
total +6

Total ESLint disabled count

id before after diff
enterpriseSearch 14 16 +2
securitySolution 497 501 +4
total +6

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @cnasikas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants