You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is ok for now since we don't use angular for URL parsing, however it won't be helpful later on. Using $location.search() with such a URL will return an empty object, since there is no '?' in the hash. Angular treats the string as a path instead of a query string.
BC for URLs should not be an issue for the Piwik reporting UI itself (for exported widgets etc it is an issue but this one doesn't affect them).
The PR cannot be put into 2.15, there are several breaking API changes. There were also various problems with those URL changes starting from UI tests to overlay to ... and there were code changes needed in various places. I reckon it would be easier to work with broadcast for now. I had to create a service to access $location.search() anyway (see https://github.com/piwik/piwik/pull/8442/files#diff-a9b4a06fd105d04eaf7fb97abade0dd4R1) which might accesses broadcast again as there are some issues with $location.search:
Eg when having period=day&period=year angular would otherwise return ['day', 'year'] instead of 'year'
and
$location.search() returns empty when query params are not preceded by hash see angular/angular.js#7239
What does it mean? When you have a URL like index.php?module=action&action=test you cannot get the value with $location.search('module'). We have a lot of such URLs... it should be index.php?module=action&action=test as well. We could change this behaviour I think be enabling HTML5 URL mode but then we would always have to test things with a browser that supports HTML 5 mode and with a browser that doesn't. I'm not exactly sure which browser support HTML 5 mode but IE 8 doesn't which should be still supported in 2.15.
Currently the UI frontend will structure URLs like this:
http://localhost/?module=CoreHome&action=index#/module=Goals&action=index
This is ok for now since we don't use angular for URL parsing, however it won't be helpful later on. Using
$location.search()
with such a URL will return an empty object, since there is no '?' in the hash. Angular treats the string as a path instead of a query string.URLs should look like this:
http://localhost/?module=CoreHome&action=index#/?module=Goals&action=index
Changing this may cause problems w/ the
historyService
, would need to test (though UI tests should cover it).The text was updated successfully, but these errors were encountered: