You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Sharing a scenario - Empty productData array

Accepted answer
52
Views
1
Comments

Summary:

Sharing an issue that occurred using widget.cart()

Content (required):

Due to business rules some items in the product catalog are marked not to allow home delivery.

Then a brand was inserted in a field of the product catalog. However, I noticed that when capturing this information using: js: [ var allItems = widget.cart().alliTems() ] sometimes the data is not returned, but

using: js: [ var allItems = widget.cart().items() ; ]

the data exists and is visible in the console.log but non-existent in the js if (allItems2[index].productData())....

Version (include the version you are using, if applicable):

22.4.2


Code Snippet (add any code snippets that support your topic, if applicable):

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!