Skip to content

Resolve "Add Incident Tag to the 'add item' form"

Paulina Sedlak-Jakubowska requested to merge 373854-incident-tag-create into master

What does this MR do and why?

Create timeline event form

  • Adds a dropdown with multiple select options for event tags
  • Fills event note with default note, when tag is selected and note is empty
  • Allows for creating an event with or without tags

Notes

I decided to allow multi select option on the dropdown, even though we now have only "Start time" and "End time" on the list and they may be contradictory. However, dropdown returns a different data structure with multi select option and this will save us going back to all occurrences and unit tests, when adding more option. Whats more, adding more options will probably come in the following milestone anyways.

I also decided not to manipulate the event note, as there would be too many edge cases. This means that it is possible to create event with default event after selecting "Start time" tag. Then change the tag to "End time" but still have the default start note.

Since I used a new dropdown component - GlListbox - it looks a bit different than the one on design.

I changed showDelete flag for the delete button in event edition to isEditing to better show the purpose. And use it to hide the dropdown, when editing and exisiting event - that part will come in the following MR.

Screenshots or screen recordings

description before after
default create form before_create_event_without_select_copy after_timeline_create_default_state
one tag selected after_timeline_create_one_tag_selected
two tags selected after_timeline_create_two_tags_selected

How to set up and validate locally

  1. Navigate to Monitor > Incidents page
  2. Create new or open an existing incident
  3. Navigate to Timeline tab of the incident
  4. Click "Add new timeline event" button at the bottom
  5. Choose a tag from dropdown to fill in the note with default content

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #373854 (closed)

Edited by Paulina Sedlak-Jakubowska

Merge request reports