Skip to content

[ResponseOps][Cases] Add tags to template in configure api#183743

Merged
js-jankisalvi merged 5 commits intoelastic:feat/case_templatesfrom
js-jankisalvi:add-template-tags-api
May 21, 2024
Merged

[ResponseOps][Cases] Add tags to template in configure api#183743
js-jankisalvi merged 5 commits intoelastic:feat/case_templatesfrom
js-jankisalvi:add-template-tags-api

Conversation

@js-jankisalvi
Copy link
Copy Markdown
Contributor

Summary

Parent issue: #181309

This PR adds optional tags field in template.

Checklist

@js-jankisalvi js-jankisalvi added release_note:skip Skip the PR/issue when compiling release notes Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// Feature:Cases Cases feature v8.15.0 labels May 17, 2024
@js-jankisalvi js-jankisalvi self-assigned this May 17, 2024
@js-jankisalvi js-jankisalvi requested a review from a team as a code owner May 17, 2024 13:40
@elasticmachine
Copy link
Copy Markdown
Contributor

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

@elasticmachine
Copy link
Copy Markdown
Contributor

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

caseFields: rt.union([rt.null, CaseBaseOptionalFieldsRequestRt]),
});
rt.exact(
rt.partial({
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

super nit: Do the tags need to be partial? I feel like saying they're an array with minlength 0 achieves the same and is way less verbose.

Copy link
Copy Markdown
Contributor Author

@js-jankisalvi js-jankisalvi May 17, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without partial and with minLength: 0 , it will still force user to add tags:[] param in each request. Where as partial makes it optional to add

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yy I know, but I thought why not have tags: [] anyway if they are the same 🤷 Anyway, not a big deal. Feel free to leave as is 👍

@js-jankisalvi
Copy link
Copy Markdown
Contributor Author

@elasticmachine merge upstream

@js-jankisalvi
Copy link
Copy Markdown
Contributor Author

@elasticmachine merge upstream

@kibana-ci
Copy link
Copy Markdown

💔 Build Failed

Failed CI Steps

Metrics [docs]

‼️ ERROR: no builds found for mergeBase sha [5eb9e81]

History

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

cc @js-jankisalvi

@js-jankisalvi js-jankisalvi merged commit b7fec99 into elastic:feat/case_templates May 21, 2024
@js-jankisalvi js-jankisalvi deleted the add-template-tags-api branch May 21, 2024 11:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature:Cases Cases feature release_note:skip Skip the PR/issue when compiling release notes Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// v8.15.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants