Opened 2 years ago

Closed 2 years ago

#3060 closed Bug (fixed)

&segment= parameter should be forwarded to the hashtag when clicking on menus

Reported by: matt Owned by:
Priority: major Milestone: 1.12.x - Piwik 1.12.x
Component: UI - UX (AngularJS, twig, less) Keywords:
Cc: Sensitive: no

Description (last modified by matt)

currently &segment=country==fr is not forwarded to other menus clicked (it disappears). We should forward it as well as date/period/idGoal/etc. so that at least segmentation works when we manually add it to URL, while we're waiting for #2135

Change History (4)

comment:1 Changed 2 years ago by matt (mattab)

  • Description modified (diff)
  • Summary changed from &segment parameters should be kept when clicking on menus to &segment= parameter should be forwarded to the hashtag when clicking on menus

comment:2 Changed 2 years ago by JulienM (JulienMoumne)

+1

I regularly filter stats based on a custom variable (user login) and I always need to edit the URL to reapply the filter.

comment:3 Changed 2 years ago by matt (mattab)

More complicated than I thought. I think there is a bug in the menu actually.

What I did:

  • Go to index.php?module=CoreHome&action=index&idSite=1&period=day&date=yesterday#module=Actions&action=indexPageUrls&idSite=1&period=day&date=yesterday&segment=country==xx
    • It loads the content as expected with the segment applied
  • OPen firebug > Net panel
  • Click on the same submenu (or any other)
  • You will notice 2 http requests made instead of one:
    • Expected: index.php?module=CoreHome&action=index&idSite=1&period=day&date=yesterday#module=Actions&action=indexPageUrls&idSite=1&period=day&date=yesterday&segment=country==xx
  • But then it also triggers (it seems at the same time) another request this time to the page without the segment: index.php?module=CoreHome&action=index&idSite=1&period=day&date=yesterday#module=Actions&action=indexPageUrls&idSite=1&period=day&date=yesterday

I have tried looking for the bug but couldn't pin point it...

comment:4 Changed 2 years ago by matt (mattab)

  • Resolution set to fixed
  • Status changed from new to closed

(In [6090]) Fixes #3060 How to spend 2 hours fixing some annoying bug ;)

Note: See TracTickets for help on using tickets.