-
Notifications
You must be signed in to change notification settings - Fork 137
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
[Woo POS][Non-Simple Products] Add variation to cart #12926
Conversation
…45-add-variation-to-cart # Conflicts: # WooCommerce/src/test/kotlin/com/woocommerce/android/ui/woopos/home/items/WooPosItemsViewModelTest.kt
📲 You can test the changes from this Pull Request in WooCommerce-Wear Android by scanning the QR code below to install the corresponding build.
|
📲 You can test the changes from this Pull Request in WooCommerce Android by scanning the QR code below to install the corresponding build.
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## trunk #12926 +/- ##
============================================
+ Coverage 39.59% 39.61% +0.02%
- Complexity 5956 5965 +9
============================================
Files 1267 1268 +1
Lines 73179 73214 +35
Branches 10048 10052 +4
============================================
+ Hits 28976 29006 +30
- Misses 41629 41633 +4
- Partials 2574 2575 +1 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
…45-add-variation-to-cart # Conflicts: # WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/items/variations/WooPosVariationsViewModel.kt # WooCommerce/src/test/kotlin/com/woocommerce/android/ui/woopos/home/variations/WooPosVariationsViewModelTest.kt
…45-add-variation-to-cart # Conflicts: # WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/items/WooPosItem.kt # WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/items/WooPosItemsViewModel.kt # WooCommerce/src/test/kotlin/com/woocommerce/android/ui/woopos/home/items/LeftPaneNavigatorTest.kt # WooCommerce/src/test/kotlin/com/woocommerce/android/ui/woopos/home/items/WooPosItemsViewModelTest.kt
…45-add-variation-to-cart
…45-add-variation-to-cart # Conflicts: # WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/items/variations/WooPosVariationsScreen.kt
…45-add-variation-to-cart # Conflicts: # WooCommerce/src/main/kotlin/com/woocommerce/android/ui/woopos/home/items/variations/WooPosVariationsViewModel.kt # WooCommerce/src/test/kotlin/com/woocommerce/android/ui/products/ProductTestUtils.kt
…45-add-variation-to-cart
Version |
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.
LGTM
is ParentToChildrenEvent.BackFromCheckoutToCartClicked -> handleBackFromCheckoutToCartClicked() | ||
is ParentToChildrenEvent.ItemClickedInProductSelector -> handleItemClickedInProductSelector(event) | ||
is ParentToChildrenEvent.OrderSuccessfullyPaid -> handleOrderSuccessfullyPaid() | ||
is ParentToChildrenEvent.CheckoutClicked -> handleCheckoutClicked() |
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.
💡 np.: It's a bit confusing to redirect to an empty function (handleCheckoutClicked()). How about this?
is ParentToChildrenEvent.CheckoutClicked -> handleCheckoutClicked() | |
is ParentToChildrenEvent.CheckoutClicked -> Unit |
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.
Done: 1daccc8
Closes: #12845
Description
This PR adds variation to the cart when clicked from the variations list screen.
Testing information
Try adding different variations of a variable product to the cart and ensure they all get added to the cart with correct name and variation attribute.
The tests that have been performed
Adding different variations to the cart in both dark and light mode.
Images/gif
add_variation_to_cart_demo.mp4
RELEASE-NOTES.txt
if necessary. Use the "[Internal]" label for non-user-facing changes.Reviewer (or Author, in the case of optional code reviews):
Please make sure these conditions are met before approving the PR, or request changes if the PR needs improvement: