Skip to content

Shipping lines m2 analytics #11574

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

Conversation

atorresveiga
Copy link
Contributor

@atorresveiga atorresveiga commented May 24, 2024

Closes: #11397

Description

This PR adds the tracking events for M2

Testing instructions

  1. Open the app
  2. Go to the orders screen
  3. Tap on add new order (+)
  4. Add a product to enable the shipping section
  5. Add a new shipping line to the order
  6. Check that the event order_shipping_method_add is triggered and that it contains a custom property shipping_lines_count with the number of shipping lines
  7. Optionally add another shipping line to the order
  8. Tap on create
  9. Check that the event order_creation_success is triggered and that it contains a custom property shipping_lines_count with the number of shipping lines
  10. Check that the app navigates to the order details screen
  11. Check that the event order_details_shipping_methods_shown is triggered and that it contains a custom property shipping_lines_count with the number of shipping lines

Images/gif

🔵 Tracked: order_shipping_method_add, Properties: {"flow":"creation","shipping_method":"local_pickup","shipping_lines_count":1,"blog_id":222408976,"is_wpcom_store":true,"was_ecommerce_trial":true,"plan_product_slug":"wooexpress-small-bundle-yearly","store_id":"b6468f83-4986-44f1-b4ce-6021649dbf29","is_debug":true,"site_url":"https:\/\/woo-practically-automatic-witch.wpcomstaging.com","cached_woo_core_version":"8.9.1"}

🔵 Tracked: order_creation_success, Properties: {"milliseconds_since_order_add_new":"264904","coupons_count":0,"use_gift_card":false,"shipping_lines_count":2,"blog_id":222408976,"is_wpcom_store":true,"was_ecommerce_trial":true,"plan_product_slug":"wooexpress-small-bundle-yearly","store_id":"b6468f83-4986-44f1-b4ce-6021649dbf29","is_debug":true,"site_url":"https:\/\/woo-practically-automatic-witch.wpcomstaging.com","cached_woo_core_version":"8.9.1"}


🔵 Tracked: order_details_shipping_methods_shown, Properties: {"shipping_lines_count":2,"blog_id":222408976,"is_wpcom_store":true,"was_ecommerce_trial":true,"plan_product_slug":"wooexpress-small-bundle-yearly","store_id":"b6468f83-4986-44f1-b4ce-6021649dbf29","is_debug":true,"site_url":"https:\/\/woo-practically-automatic-witch.wpcomstaging.com","cached_woo_core_version":"8.9.1"}

  • I have considered if this change warrants release notes and have added them to RELEASE-NOTES.txt if necessary. Use the "[Internal]" label for non-user-facing changes.

@atorresveiga atorresveiga added feature: order details Related to order details. category: tracks Related to analytics, including Tracks Events. feature: order creation Related to the Order Creation feature labels May 24, 2024
@atorresveiga atorresveiga added this to the 18.9 milestone May 24, 2024
@dangermattic
Copy link
Collaborator

1 Message
📖

This PR contains changes to Tracks-related logic. Please ensure (author and reviewer) the following are completed:

  • The tracks events must be validated in the Tracks system.
  • Verify the internal Tracks spreadsheet has also been updated.
  • Please consider registering any new events.
  • The PR must be assigned the category: tracks label.

Generated by 🚫 Danger

@wpmobilebot
Copy link
Collaborator

wpmobilebot commented May 24, 2024

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

App Name WooCommerce Android
FlavorJalapeno
Build TypeDebug
Commitfa78ec2
Direct Downloadwoocommerce-prototype-build-pr11574-fa78ec2.apk

@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 87.50000% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 40.36%. Comparing base (753dfdb) to head (fa78ec2).
Report is 32 commits behind head on issue/multiple-shipping-lines-support.

Files Patch % Lines
...oid/ui/orders/creation/OrderCreateEditViewModel.kt 87.50% 0 Missing and 1 partial ⚠️
.../android/ui/orders/details/OrderDetailViewModel.kt 85.71% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                             Coverage Diff                             @@
##             issue/multiple-shipping-lines-support   #11574      +/-   ##
===========================================================================
+ Coverage                                    40.35%   40.36%   +0.01%     
  Complexity                                    5202     5202              
===========================================================================
  Files                                         1085     1085              
  Lines                                        63201    63211      +10     
  Branches                                      8664     8666       +2     
===========================================================================
+ Hits                                         25504    25516      +12     
+ Misses                                       35397    35391       -6     
- Partials                                      2300     2304       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@atorresveiga atorresveiga merged commit 0ad68a4 into issue/multiple-shipping-lines-support May 24, 2024
17 checks passed
@atorresveiga atorresveiga deleted the issue/11397-shipping-lines-m2-analytics branch May 24, 2024 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: tracks Related to analytics, including Tracks Events. feature: order creation Related to the Order Creation feature feature: order details Related to order details.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants