Skip to content

Refactor admin labels to use shared HAML partial

What does this MR do and why?

In preparation for Add a delete button to the edit label pages (#345195 - closed) this MR refactors the admin label edit/create views to use a shared HAML partial that already existed. It then removes the old unused partial and fixes a few strings that were not translatable.

Screenshots or screen recordings

Create label

Before After
Screen_Shot_2022-01-04_at_3.56.40_PM Screen_Shot_2022-01-05_at_11.10.52_AM

Edit label

Before After
Screen_Shot_2022-01-04_at_3.57.40_PM Screen_Shot_2022-01-05_at_11.12.14_AM

How to set up and validate locally

  1. Sign in as an admin (root on GDK)
  2. Navigate to /admin/labels
  3. Click New label
  4. Fill in the form and click Create label
  5. Click the pencil button next to the newly created label
  6. Edit the fields and click Save changes

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 #345195 (closed)

Edited by Peter Hegman

Merge request reports