Skip to content

Commit

Permalink
[Cases] Version cases and comment domain and apis (#161954)
Browse files Browse the repository at this point in the history
## Summary

This PR versions the `cases` and `comment` domain objects and their
corresponding APIs. It was not possible to do them separately as I got
errors due to circular dependencies.

## Notable Changes
- The `Comment` type was renamed to `Attachment`
- The `Comments` type was renamed to `Attachments`
- The `*CommentRequestRt` type was renamed to `*AttachmentPayload`
- The `CommentType` type was  renamed to `AttachmentType`
- The `AttributesType*` type was renamed to `*AttachmentAttributes`
- The `*ResponseTypeUserRt` type was renamed to `*AttachmentRt`
- The word `comment` got replaced with the word `attachment` in all
types
- The `RelatedCaseInfo` type was renamed to `RelatedCase`
- The `CasesByAlertId` type was renamed to
`GetRelatedCasesByAlertResponse`

Depends on: #161783,
#162059

### Checklist

Delete any items that do not apply 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)

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
  • Loading branch information
cnasikas and kibanamachine authored Jul 26, 2023
1 parent da5554f commit 2221ff8
Show file tree
Hide file tree
Showing 388 changed files with 4,911 additions and 4,492 deletions.
8 changes: 8 additions & 0 deletions packages/kbn-cases-components/src/status/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,14 @@
* Side Public License, v 1.
*/

/**
* This is being used by Cases in
* x-pack/plugins/cases/common/types/domain/case/v1.ts.
* Introducing a breaking change in this enum will
* force cases to create a version of the domain object
* which in turn will force cases to create a new version
* to most of the Cases APIs.
*/
export enum CaseStatuses {
open = 'open',
'in-progress' = 'in-progress',
Expand Down
41 changes: 0 additions & 41 deletions x-pack/plugins/cases/common/api/cases/assignee.test.ts

This file was deleted.

Loading

0 comments on commit 2221ff8

Please sign in to comment.