woocommerce / woocommerce-android

WooCommerce Android app
https://www.woocommerce.com/mobile
GNU General Public License v2.0
277 stars 135 forks source link

[WooPos][Non Simple Product types] Retry UI for pagination errors on variations screens #12972

Open AnirudhBhat opened 11 hours ago

AnirudhBhat commented 11 hours ago

Closes: #12967

Description

This PR adds a new UI for retrying errors during paginating variations.

Along with this, this PR also does a small change in totals screen after payment is success. It navigates the screen back to items list screen so that when we click on "new order" button from the payment success screen, we end up on the items list screen instead of variations screen if we had proceeded to totals screen from variations screen.

Design

Screenshot 2024-11-19 at 7 19 03 AM

Implementation

Screenshot 2024-11-21 at 1 42 06 PM

Testing information

Retry pagination UI

  1. Navigate to POS mode (more menu -> POS)
  2. Click on any variable products that has more than 10 variations
  3. Ensure you navigate to the variations screen
  4. Turn on airplane mode
  5. Scroll down
  6. Ensure you see the pagination error UI
  7. Click on retry and ensure nothing happens as we are still in airplane mode
  8. Turn off airplane mode
  9. Now, click on retry button again
  10. Ensure the variations gets loaded

Navigate to items list after payment success

  1. Navigate to POS mode (more menu -> POS)
  2. Add products to cart
  3. Navigate to variations screen before checking out
  4. Ensure payment is success
  5. Click on "New Order" button
  6. Ensure you navigate to items list screen.

The tests that have been performed

Tested on both light and dark modes

Images/gif

https://github.com/user-attachments/assets/20818862-21db-4ee2-b69f-5d25d5923162

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:

dangermattic commented 11 hours ago
1 Message
:book: This PR is still a Draft: some checks will be skipped.

Generated by :no_entry_sign: Danger

wpmobilebot commented 10 hours ago
📲 You can test the changes from this Pull Request in WooCommerce-Wear Android by scanning the QR code below to install the corresponding build.
App Name WooCommerce-Wear Android
Platform⌚️ Wear OS
FlavorJalapeno
Build TypeDebug
Commit8ceaa5fcafbeb30e7c78215273c790430a005d47
Direct Downloadwoocommerce-wear-prototype-build-pr12972-8ceaa5f.apk
wpmobilebot commented 10 hours ago

📲 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
Platform📱 Mobile
FlavorJalapeno
Build TypeDebug
Commit8ceaa5fcafbeb30e7c78215273c790430a005d47
Direct Downloadwoocommerce-prototype-build-pr12972-8ceaa5f.apk
codecov-commenter commented 10 hours ago

Codecov Report

Attention: Patch coverage is 66.66667% with 4 lines in your changes missing coverage. Please review.

Project coverage is 39.63%. Comparing base (3be8fe3) to head (8ceaa5f).

Files with missing lines Patch % Lines
...ce/android/ui/woopos/home/items/WooPosItemsList.kt 0.00% 4 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## issue/12846-analytics-for-variations #12972 +/- ## ========================================================================== - Coverage 39.63% 39.63% -0.01% Complexity 5973 5973 ========================================================================== Files 1268 1268 Lines 73276 73279 +3 Branches 10057 10058 +1 ========================================================================== + Hits 29041 29042 +1 - Misses 41656 41659 +3 + Partials 2579 2578 -1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


🚨 Try these New Features:

kidinov commented 9 hours ago

@AnirudhBhat 👋

Where does this design come from? IMO, it doesn't match expectations from this kind of UX in a mobile app.

I believe this should have:

Something like that maybe?

image

@malinajirka @samiuelson wdyt?