function Checkout(Payment_Type, Tip_Amt){
var Cust_Order = [];
readRecords(Order_Data,{},function(Rec){
for (var i = 0; i < Rec.length; i++) {
appendItem(Cust_Order, Rec[i].Table);
appendItem(Cust_Order, Rec[i].Type);
appendItem(Cust_Order, Rec[i].Item);
appendItem(Cust_Order, Rec[i].Price);
}
console.log(Cust_Order);
});
}
This is part of a restaurant ordering app I have to build for uni. I've saved the customers order in a data set and now I wish to read from that dataset and get the order to be able to calculate the bill and produce an itemised bill
WARNING: Line: 176: readRecords() table parameter value ([object Object]) is not a string.ERROR: Line: 176: TypeError: e.replace is not a function. (In 'e.replace(m,"-")', 'e.replace' is undefined)