With translation some links don't work because of a missing slash

Created on 7 May 2023, about 1 year ago

Problem/Motivation

If you use the burndown module with translation and URL language like /de/ for German, some links are not working.

Steps to reproduce

1) Go to the backlog and click on the title of the task. Go to the icons for "edit", "sent to board", "close".
2) Go to the board. The same behavior.
3) Go to completed. The same behavior.

Proposed resolution

Add code to produce the missing slash after the language detection like "de" and "burndown", so that the link is not "deburndown" but "de/burndown".

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Active

Version

1.0

Component

User interface

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @chlodewig
  • πŸ‡¨πŸ‡¦Canada jeremylichtman

    The relevant code is in two twig files that render cards:

    burndown-task.html.twig and
    burndown-task-card.html

    We'll need to check if there's any others, but most of the task functionality should be contained there.

    I believe each of the hard-coded links needs to be replaced with {{ path(... }} type links.

    See: https://mycode.blog/lakshmi/how-to-generate-drupal-89-url-path-by-route-...

    I don't have a running local env right now so will need to set that up first before fixing.

    The routes that are relevant are:

    * burndown.close_task (params: ticket_id and board_
    * edit task (need to look up)
    * burndown.board_send_to_backlog (param - ticket_id)
    * etc.

Production build 0.69.0 2024