Skip to content

Fix relative root on Broadcast messages

What does this MR do and why?

  • Fixes the relative path url issue for broadcast messages as per #396368 (closed)
  • Switches to use rails defined routes as the SSOT instead of recreating this as a constant in the frontend
  • Adds some space between Add broadcast message button and table
  • Adds feature specs handling edit, create, list concepts of broadcast messages to ensure glue between backend and frontend is correct.

Screenshots or screen recordings

Relative url bug

before before

after - no errors

Space between button and listing of messages

before after
Screenshot_2023-03-27_at_6.45.38_PM Screenshot_2023-03-27_at_6.44.24_PM

How to set up and validate locally

  1. Make your gdk operate with a relative path by setting relative_url_root in your gitlab.yml to /gitlab (from https://docs.gitlab.com/ee/install/relative_url.html#enable-relative-url-in-gitlab) and restart gdk.
  2. visit the admin / messages area
  3. confirm you can create/preview/edit a broadcast message without errors. (this is the fix)
  4. switch branch to master and confirm there are now errors for the previous step.

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

Edited by Doug Stull

Merge request reports