Simplify GEO API - use new list endpoints and routes in nearestOffers
All checks were successful
Build Docker Image / build (push) Successful in 4m11s
All checks were successful
Build Docker Image / build (push) Successful in 4m11s
- Replace GetNodesDocument with HubsListDocument in useCatalogHubs.ts - Replace GetSupplierProfilesDocument with SuppliersListDocument in useCatalogSuppliers.ts - Replace manual grouping with ProductsListDocument in useCatalogProducts.ts - Update nearestOffers to pass hubUuid for server-side route calculation - Remove RouteToCoordinate calls - routes now included in nearestOffers response - Delete 15 obsolete GraphQL files - Add 3 new list endpoints: HubsList, SuppliersList, ProductsList - Fix TypeScript errors in CalcResultContent, LocationsContent, hubs page, location store
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import {
|
||||
GetProductsDocument,
|
||||
ProductsListDocument,
|
||||
GetNodeDocument,
|
||||
NearestOffersDocument
|
||||
} from '~/composables/graphql/public/geo-generated'
|
||||
@@ -114,14 +114,14 @@ export function useCatalogProducts() {
|
||||
items.value = Array.from(productsMap.values())
|
||||
}
|
||||
} else {
|
||||
// All products
|
||||
// All products from graph
|
||||
data = await execute(
|
||||
GetProductsDocument,
|
||||
{},
|
||||
ProductsListDocument,
|
||||
{ limit: 500 },
|
||||
'public',
|
||||
'geo'
|
||||
)
|
||||
items.value = data?.products || []
|
||||
items.value = data?.productsList || []
|
||||
}
|
||||
|
||||
isInitialized.value = true
|
||||
|
||||
Reference in New Issue
Block a user