aimeos / ai-client-jsonapi

Aimeos frontend JSON API
GNU Lesser General Public License v3.0
28 stars 6 forks source link

Order Included Relationships dont match #16

Closed exemplari closed 2 years ago

exemplari commented 2 years ago

I have been using a function with the Basket and Customer to match the "included" to their "data.relationships". Since each type and id are unique in the included , those become the index to finding the related data. Basket

Finally got around to the Order history and this function does not work because the mapping ID are different. Order

Since the id used in the Order Relationships section depend on attributes like ''order.base.product.id", it is nearly impossible to map these without an intimate knowledge of all the fields in the API.

Either the included order/base/product id should be the product id, Or the relationships id should be the position index.

aimeos commented 2 years ago

You are right, that's not how it should be. The problem is fixed in dev-master and will be fixed in 2021.10 LTS but we don't dare to add that to 2021.07.x because it's somewhat breaking.

exemplari commented 2 years ago

thanks for the info. I found the needed relationship data exist in the attributes.