Skip to content

Conversation

RafaelKayumov
Copy link
Contributor

@RafaelKayumov RafaelKayumov commented Sep 10, 2025

WOOMOB-1266

Description

Makes sure "Blaze" and "Stock" cards are hidden from Dashboard.
Also fixes a bug where blaze card wasn't appearing in dashboard until manually pulled-to-refresh.

  • Updates BlazeCampaignDashboardViewModel to rely on published stores.site instead of sessionManager.defaultSite
  • Uses CIABEligibility checker in BlazeCampaignDashboardViewModel and DashboardViewModel to determine cards visibility
  • Updates DashboardViewModel to rely on published stores.site
  • Adds corresponding tests in DashboardViewModelTests and BlazeCampaignDashboardViewModelTests

Testing Steps

  • Use a store eligible for Blaze.
  • Make sure the site doesn't contain "garden" or "ciab" in name (this is the temp CIAB / non-CIAB site distinguishing logic).
  • In dashboard open the "Edit" screen to select cards
  • Make sure "Blaze Campaigns" and "Stock" options are presented.
  • Consider enabling these options to make sure that the cards are also displayed on dashboard and present correct info
  • Go to wp admin dashboard of the site
  • Change the site name to contain "garden" or "ciab" and save changes
  • Restart the app
  • In dashboard make sure the Blaze and Stock cards aren't presented anymore.
  • Go to "Edit" in Dashboard and make sure the Blaze and Stock cards aren't presented there either.
  • Delete "garden" or "ciab" from your site name and repeat the steps
  • Cards should be visible again

Testing information

Tested the above scenarios on iPhone Simulator 18.4. Added unit tests covering the behaviour.


  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@RafaelKayumov RafaelKayumov added this to the 23.3 milestone Sep 10, 2025
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Sep 10, 2025

App Icon📲 You can test the changes from this Pull Request in WooCommerce iOS Prototype by scanning the QR code below to install the corresponding build.

App NameWooCommerce iOS Prototype
Build Numberpr16116-a604522
Version23.2
Bundle IDcom.automattic.alpha.woocommerce
Commita604522
Installation URL5ospgsl2rj2cg
Automatticians: You can use our internal self-serve MC tool to give yourself access to those builds if needed.

Base automatically changed from WOOMOB-1272-hide-blaze-and-payments-from-hub-menu to trunk September 11, 2025 15:10
@RafaelKayumov RafaelKayumov force-pushed the WOOMOB-1266-hide-blaze-and-stock-cards-from-dashboard-for-CIAB branch from 249aab1 to 7e73f66 Compare September 12, 2025 13:58
@RafaelKayumov RafaelKayumov marked this pull request as ready for review September 12, 2025 14:44
@itsmeichigo itsmeichigo self-assigned this Sep 15, 2025
Copy link
Contributor

@itsmeichigo itsmeichigo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works great! 🚢

@@ -586,6 +615,7 @@ private extension DashboardViewModel {
canShowGoogle: Bool,
canShowAnalytics: Bool,
canShowLastOrders: Bool,
canSowStock: Bool,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: typo canShowStock

@RafaelKayumov RafaelKayumov merged commit 95a8b27 into trunk Sep 15, 2025
14 checks passed
@RafaelKayumov RafaelKayumov deleted the WOOMOB-1266-hide-blaze-and-stock-cards-from-dashboard-for-CIAB branch September 15, 2025 10:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants