refactor time slots

This commit is contained in:
Danel Kungla
2025-09-26 17:20:50 +03:00
parent c99beea46a
commit b674640bd8
5 changed files with 173 additions and 119 deletions

View File

@@ -32,7 +32,16 @@ const BookingContainer = ({
<BookingProvider category={{ products }} service={cartItem?.product}>
<div className="xs:flex-row flex max-h-full flex-col gap-6">
<div className="flex flex-col">
<ServiceSelector products={products} />
<ServiceSelector
products={products.filter((product) => {
if (product.metadata?.serviceIds) {
return Array.isArray(
JSON.parse(product.metadata.serviceIds as string),
);
}
return false;
})}
/>
<BookingCalendar />
<LocationSelector />
</div>