I have a unique item that looks like this
Object {SD00002:1,SD00011:3,SD00002:6}
The values of the properties are set automatically. Currently, I have an array of similar objects as shown in the image below: https://i.sstatic.net/pSkvf.jpg
My goal is to loop through these two objects and calculate the total by multiplying the "price" property (found within the objects in the array) with the corresponding value of the properties in the first object. The property of the first object matches the "product code" in the array of objects. I need to multiply all the values with "price" and return the sum of all totals. So far, none of the existing questions on Stack Overflow have addressed my specific issue.