Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site Search hover help bug #16374

Closed
MISTAnalytics opened this issue Sep 3, 2020 · 4 comments · Fixed by #17264
Closed

Site Search hover help bug #16374

MISTAnalytics opened this issue Sep 3, 2020 · 4 comments · Fixed by #17264
Assignees
Labels
Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement.
Milestone

Comments

@MISTAnalytics
Copy link

MISTAnalytics commented Sep 3, 2020

What
In the Matomo site search report, the explanation is a bit confusing. It cannot be that there are 738.755 searches in July 2020? While the 'All visits' segment shows a total of 16.655 searches?

Search bug Matomo

Why
Because currently when you hover over the help section in the site search report you will see two explanations and this is confusing.

Suggestion
Remove the latter sentence.

@tsteur tsteur added Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement. labels Sep 3, 2020
@tsteur tsteur added this to the 4.2.0 milestone Sep 3, 2020
@tsteur
Copy link
Member

tsteur commented Sep 3, 2020

I can reproduce this and I'm pretty sure it's meant to say in the second sentence "0% of all 738.755 visits in Jul 2020".

@MISTAnalytics
Copy link
Author

@tsteur,

Yes correct, this should be visits instead of searches.

@TheCrowned
Copy link

I'll take this and submit a PR :)

@TheCrowned
Copy link

So, I've nailed this down to the file plugins/CoreVisualizations/templates/_dataTableViz_htmlTable_ratio.twig, where the second sentence is generated by
{% if totalPercentage|default is not empty %} {% set totalRatioTooltip = 'General_TotalRatioTooltip'|translate(totalPercentage, siteTotal|number(2,0), metricTitle, periodTitlePretty) %}

The problem is that metricTitle is defined earlier as
{% set metricTitle = translations[column]|default(column) %}
and is also used in the first sentence
{% set reportRatioTooltip = 'General_ReportRatioTooltip'|translate(label, rowPercentage|e('html_attr'), reportTotal|e('html_attr'), metricTitle|e('html_attr'), '"' ~ segmentTitlePretty ~ '"', translations[labelColumn]|default(labelColumn)|e('html_attr')) %}

Thus it looks like they cannot really be detached and whatever goes in the first sentence will go in the second as well, or am I wrong? I am wondering if that tooltip ever even worked fine, since looking bback at past commits it looks like the relevant file has always been the way it is now
3f26e78#diff-02df9be9bffb622de389dc42a0cd753d

(I'm having a bit of an issue with setting up a good dev environment because of #16515)

@flamisz flamisz mentioned this issue Feb 24, 2021
9 tasks
@mattab mattab modified the milestones: 4.5.0, 4.4.0 May 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants