'Fetch Eager Prestashop 1.7 Webservice
i'm doing an app using the prestashop webservice. For some ressource it could be really long to get all the details of items; for instance, when i want to get all the product list and detail we have to :
- retrieve all the id for the resource "products"
- foreach prodct ask again the webservice to get the detail of each one
- if we need the combination we have to loop again on each product association to get the combinations and ask again each time the webservice
I found a trick to de less request :
- i get all the combinations
- for each combination i get the details of each combination
- for each combination i get the product details (if i doesn't get it once)
But finally it costs a lot in terms of requests.
Does anyone has a solution to override the webservice in prestashop to add a fetch type eager and get all the data at once for selected resources ?
Thank you !
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
