[go: up one dir, main page]

Skip to content

Ensure incidents and Service Desk issues use legacy views and workflows

We'd like to ensure that incidents will work using legacy views and workflows although issues and epics use the new work item views.

With the feature flag work_items_view_preference we allow users to switch to the new work item view for all issues and work items using the user preference use_work_items_view.

This involves all workflows related to incidents and Service Desk issues:

  1. Create workflow
  2. List and browse to detail view
  3. Detail view

Feature flags and migration to work items path

We don't care about the 🎏 feature flags work_items_alpha or work_items_beta and so just respect the type. Once we start work on actually migrating to work item incidents or tickets we can guard these conditions with feature flags. Here I decided against introducing another feature flag because conditions are already complex enough and we don't indent to flip switches here. Incidents and Service Desk issues should just use the legacy views no matter the feature flags and settings.

Functionality overview

  1. New route
    1. Legacy view: We reuse the legacy view and
      1. Option a) (current POC behavior) remove the option to change the type from incident to something else (for example if you select new incident from the incidents list page).
      2. Option b) remove the type select altogether and use new incident language throughout the view.
    2. Work items view: If you select the type Incident we’ll redirect you to the legacy view with only the incident type option.
  2. Links from list view (full reload instead of router)
    1. We determine whether we use the router to load the detail view or browse to the detail view for the legacy view.
    2. This now includes a type condition so links to incidents and Service Desk issues will always browse to the legacy view.
  3. Detail view
    1. Depending on the user preference we render a different haml file and run different javascript. The logic now includes the type condition mentioned above, so when you access an incident or Service Desk issue directly it will always render the legacy view.
  4. Work items feedback badge. The badge doesn’t render on
    1. Legacy incidents view
    2. Legacy Service Desk issues view
    3. Legacy new view

Implementation

  1. Detail view renders legacy view for unsupported types.
  2. Links from list view browse to legacy view instead of using the router
  3. Don't render work items feedback badge for unsupported types.
  4. Use work item create workflow for new incidents from incidents list
  5. Use work item create workflow in modal for new incidents from issue list

References

Edited by Marc Saleiko