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

[Cases] Search cases by UUID #148084

Closed
cnasikas opened this issue Dec 24, 2022 · 2 comments · Fixed by #149233
Closed

[Cases] Search cases by UUID #148084

cnasikas opened this issue Dec 24, 2022 · 2 comments · Fixed by #149233
Assignees
Labels
Feature:Cases Cases feature Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)

Comments

@cnasikas
Copy link
Member

cnasikas commented Dec 24, 2022

To improve user experience and aid users to find cases easier, we should allow searching cases by UUID. Specifically, if the user puts a UUID in the search bar of the cases table and press enter the search result should return the specific case. To achieve that we should detect if the search term is a valid UUID on the case client level. We can use the validate utility function exposed by the uuid library. To improve performance, if we do detect a UUID in the search term we should do a get call instead of a find. We will not support search terms that contain text and a UUID. The search term should contain only a valid UUID. It is worth noting that if we add a KQL-ish bar in cases the feature will be supported out of the box.

@cnasikas cnasikas added Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams) Feature:Cases Cases feature labels Dec 24, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops-cases (Feature:Cases)

@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

adcoelho added a commit that referenced this issue Jan 16, 2023
Fixes #148085

## Summary

Users want to refer to a case by its UUID in external messaging
applications like Slack.

They are now able to copy the UUID from the cases table or the case view
page.

The ability to search for cases by UUID will be developed in #148084.

## Screenshots

### All Cases View
<img width="791" alt="Screenshot 2023-01-16 at 11 15 14"
src="https://user-images.githubusercontent.com/1533137/212663742-37e3c7df-e983-4ae7-ab04-2ed4326bba03.png">
<img width="1569" alt="Screenshot 2023-01-16 at 11 16 21"
src="https://user-images.githubusercontent.com/1533137/212663745-12941766-fa90-498b-9e61-10ae30f709f6.png">

### Case Detail View

<img width="1398" alt="Screenshot 2023-01-16 at 12 07 10"
src="https://user-images.githubusercontent.com/1533137/212664134-3bc98d20-726e-4dad-9f1b-e08104e5c836.png">
<img width="1391" alt="Screenshot 2023-01-16 at 12 07 16"
src="https://user-images.githubusercontent.com/1533137/212664140-0b750e0a-7fbc-4b53-8d81-251aa183401e.png">


### Checklist

Delete any items that are not applicable to this PR.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)
- [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
- [x] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [x] This renders correctly on smaller devices using a responsive
layout. (You can test this [in your
browser](https://www.browserstack.com/guide/responsive-testing-on-local-server))
- [x] This was checked for [cross-browser
compatibility](https://www.elastic.co/support/matrix#matrix_browsers)

### Release notes

Users can now click a button on Case Detail and All Cases List to copy a
case's UUID to the clipboard.
adcoelho added a commit that referenced this issue Jan 25, 2023
Fixes #148084

[The uuid PR was merged](#149135)
so I am removing the `draft` status here.

## Summary

This PR introduces search by UUID in the Cases table. 

If a user puts a UUID in the search bar and presses enter the search
result will now return the case with that ID.

Additionally, we look for the matches of that search text in the title
and description fields.

See the example below:

<img width="1554" alt="Screenshot 2023-01-19 at 16 06 53"
src="https://user-images.githubusercontent.com/1533137/213477884-498d34c0-d4d1-405d-8d76-f077d46157aa.png">

We are searching for `733e1c40-9586-11ed-a29f-8b57be9cf211`. There are
two matches because that search text matches the ID of a case and the
title of another.

### Checklist

Delete any items that are not applicable to this PR.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)
- [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
- [x] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))


### Release notes

Users can now search for Cases by ID.

Co-authored-by: kibanamachine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Cases Cases feature Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants