NCIOCPL / cgov-digital-platform

The Cancer.gov Digital Communications Platform
GNU General Public License v2.0
11 stars 33 forks source link

Unset pretty url on Cgov Blog Topics #4060

Open dev-rana-publicis opened 1 year ago

dev-rana-publicis commented 1 year ago

Issue description

If the pretty url on a cgov blog topic (taxonomy term) is not set, then the url path display the taxonomy term id. The page will be on the selected blog topic page, however the topic will not be highlighted on the right rail (under Categories). We may want to look into using cache contexts and add it to the topics so we would know what topics belongs to the series.

Steps to reproduce the issue

Note: These are steps to reproduce for the Cancer Current Blog Series but this bug can happen to any blog series if there is no pretty url set on a blog topic.

  1. Select Tratamiento as the blog topic for a spanish Cancer Current blog post
  2. Go to the Cancer Currents Blog Series Page and select Treatment and notice that it highlights the term and the url has the topic ID.
  3. Translate the page to Spanish
  4. Notice that Tratamiento is not highlighted and the url has the topic ID.

What's the expected result?

What's the actual result?

Additional details / screenshot

Screenshot 2023-09-21 at 12 45 55 PM Screenshot 2023-09-21 at 12 49 28 PM
blairlearn commented 11 months ago

There seems to be some general flakiness with how topics are being passed and highlighted.

Using the standard content (which has no pretty url for Treatment)

  1. Edit the Spanish translation of a blog post and select "Treatment" as its topic.
  2. Save and publish the post.
  3. Go to https://www-dev-ac.cancer.gov/news-events/cancer-currents-blog
  4. Click Treatment
  5. At this point, "Treatment" is highlighted.
  6. Click the "Espanol" button
  7. Tratamiento is not highlighted.
  8. Click Tratamiento.
  9. Now Tratamiento is highlighted
  10. Click English
  11. Now the topic query parameter is empty and no blog entries are shown at all.
andyvanavery31 commented 10 months ago

Low priority, may be able to be fixed when doing Blog redesign.