David,
Below is all the code. Hopefully you can find an issue!
let completePrice = Number(0);
$w.onReady( function () {
$w(“#orderlist”).onItemReady(($w, itemData, index) => {
let quantity = Number(itemData.quantity)
//other items gathered from the item list are pulled here
let iD = 0;
if (title === ‘Medium’) { iD = 1;}
else if (title === ‘Intermediate’) { iD = 2;}
else {iD = 3;}
// More code that gives the iD is written here
const getPrice = (iD) => {
if (iD === 11111) { return 111.11;}
else if (iD === 11112) { return 111.12;}
//There's a bunch of code to pricing lines here that I removed
else if (iD === 25433) { return 111.12;}
}
$w('#price').text = String(getPrice(iD))
$w("#totalPrice").text = String(getPrice(iD)*quantity)
let completePrice = completePrice + getPrice(iD)*quantity;
$w(“#completePrice”).text = String(completePrice + getPrice(iD)*quantity)
})}
)