-
Notifications
You must be signed in to change notification settings - Fork 121
[My Store] Use stored site summary stats for visitors and conversion rate #8427
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
Merged
rachelmcr
merged 8 commits into
trunk
from
issue/8173-sitesummarystats-dashboard-display
Dec 16, 2022
Merged
[My Store] Use stored site summary stats for visitors and conversion rate #8427
rachelmcr
merged 8 commits into
trunk
from
issue/8173-sitesummarystats-dashboard-display
Dec 16, 2022
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 task
Collaborator
You can test the changes from this Pull Request by:
|
Contributor
Author
|
There's a failing unit test that is passing for me locally. I'll take a closer look to get that fixed! |
ealeksandrov
approved these changes
Dec 16, 2022
Contributor
ealeksandrov
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing visitors logic on the dashboard! ![]()
WooCommerce/Classes/ViewRelated/Dashboard/Factories/StatsDataTextFormatter.swift
Outdated
Show resolved
Hide resolved
WooCommerce/Classes/ViewRelated/Dashboard/Factories/StatsDataTextFormatter.swift
Outdated
Show resolved
Hide resolved
...ommerce/WooCommerceTests/ViewRelated/Dashboard/Stats V4/StoreStatsPeriodViewModelTests.swift
Outdated
Show resolved
Hide resolved
Base automatically changed from
issue/8173-sitesummarystats-dashboard-sync
to
trunk
December 16, 2022 11:29
Co-authored-by: Evgeny Aleksandrov <[email protected]>
Generated by 🚫 dangerJS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes: #8173
⚠️ Depends on #8424 ⚠️
Description
This PR updates the My Store dashboard to use site summary stats (
SiteSummaryStats) for the "Visitors" and "Conversion" stats for the selected period.Why we need this:
SiteVisitStatsdata).SiteSummaryStatsdata. We should continue to get the visitor count for specific intervals fromSiteVisitStats, to show when an interval is selected in the stats chart.Note: We should remove the inaccurate
totalVisitorscomputed property fromSiteVisitStats. However, while making these changes I discovered we're also using this property in the store info widget. I've opened #8426 to track that.Changes
StatsDataTextFormatterto have separate methods for getting the visitor count text usingSiteVisitStats(for a single interval) or usingSiteSummaryStats(for the entire period). Also removes an unused method.StoreStatsPeriodViewModelto fetch theSiteSummaryStatsfrom storage for the selected time period, and to use those stats for the visitor and conversion text unless a specific interval is selected.Testing instructions
Screenshots
RELEASE-NOTES.txtif necessary.