Skip to content

Conversation

@JorgeMucientes
Copy link
Contributor

@JorgeMucientes JorgeMucientes commented Dec 17, 2025

Closes WOOMOB-1745

Description

These changes ensure that we load all available bookable-service products when opening the Booking > filters > Service screen.
Additionally it updates the Service / Event product item to Service only, given event type bookings won't supported for now.

Test Steps

  1. Log into a CIAB site with a few bookable-service products
  2. Open bookings tab
  3. Navigate to all tab
  4. Tap on filters
  5. Tap on Service filters
  6. Check bookable-services are displayed correctly
  7. Navigate back to booking filters
  8. From wc-admin add a couple more bookable services
  9. Open Service filter again and check the new bookable services are displayed

Images/gif

Screen_recording_20251217_163322.mp4

Ensure we display all available bookable products from filter screen. This will make search functionality faster and avoid unnecessary network requests
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Dec 17, 2025

📲 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 NameWooCommerce-Wear Android
Platform⌚️ Wear OS
FlavorJalapeno
Build TypeDebug
Commit2b8f590
Direct Downloadwoocommerce-wear-prototype-build-pr15120-2b8f590.apk

@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Dec 17, 2025

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

App NameWooCommerce Android
Platform📱 Mobile
FlavorJalapeno
Build TypeDebug
Commit2b8f590
Direct Downloadwoocommerce-prototype-build-pr15120-2b8f590.apk

Bookable products of type Event won't be supported for now.
@JorgeMucientes JorgeMucientes marked this pull request as ready for review December 17, 2025 15:40
@codecov-commenter
Copy link

codecov-commenter commented Dec 17, 2025

Codecov Report

❌ Patch coverage is 25.00000% with 33 lines in your changes missing coverage. Please review.
✅ Project coverage is 38.53%. Comparing base (b251959) to head (2b8f590).
⚠️ Report is 147 commits behind head on trunk.

Files with missing lines Patch % Lines
...ilter/productname/BookingServiceEventFilterPage.kt 0.00% 21 Missing ⚠️
.../productname/BookingServiceEventFilterViewModel.kt 41.17% 7 Missing and 3 partials ⚠️
.../android/ui/products/list/ProductListRepository.kt 50.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##              trunk   #15120      +/-   ##
============================================
- Coverage     38.53%   38.53%   -0.01%     
- Complexity    10397    10401       +4     
============================================
  Files          2173     2173              
  Lines        123725   123763      +38     
  Branches      17050    17059       +9     
============================================
+ Hits          47676    47689      +13     
- Misses        71238    71262      +24     
- Partials       4811     4812       +1     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements pagination to fetch all available bookable-service products and updates the UI strings to reflect that only service bookings (not events) are currently supported.

Key changes:

  • Adds pagination logic to load all bookable products in batches using a larger page size (100) to minimize network requests
  • Updates UI text from "Service / Event" to just "Service" across filters and search fields
  • Introduces a loading state with skeleton UI while fetching products

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
BookingServiceEventFilterViewModel.kt Adds loadAllBookingProducts() method with pagination logic to fetch all bookable services, updates initial state to show loading
BookingServiceEventFilterUiState.kt Adds isLoading boolean property to track product loading state
BookingServiceEventFilterPage.kt Adds skeleton loading UI that displays when loading products and before any data is available
ProductListRepository.kt Makes pageSize parameter configurable in fetchProductList() to support larger page sizes for specific use cases
strings.xml Updates string resources from "Service / Event" to "Service" only for filter titles and search hints
BookingFilterListUiState.kt Updates title resource reference to use the new "Service" string
ObserveBookingsTabVisibilityTest.kt Updates test to include the new pageSize parameter in mock verification
BookingServiceEventFilterViewModelTest.kt Adds test to verify loading state is true when ViewModel initializes

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…s/filter/productname/BookingServiceEventFilterViewModel.kt

Co-authored-by: Copilot <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants