void FinalizeOrder(Object sender, RoutedEventArgs e) { RoundRegister.CashDrawer.OpenDrawer(); for (int i = 0; i < ord.order.Count; i++) { RoundRegister.RecieptPrinter.PrintLine(((i + 1) + ". " + ord.order[i].ToString() + "\t$" + ord.order[i].Price + "\n")); for (int j = 0; j < ord.order[i].SpecialInstructions.Count; j++) { RoundRegister.RecieptPrinter.PrintLine(" - " + (ord.order[i].SpecialInstructions[j] + "\n")); } } RoundRegister.RecieptPrinter.CutTape(); OrderOptions oo = new OrderOptions(b, ord, co, sb); b.Child = oo; oo.NewOrder(sender, e); }
void PaymentCard(Object sender, RoutedEventArgs e) { RoundRegister.CardTransactionResult ctr = RoundRegister.CardReader.RunCard(ord.Total); if (ctr == RoundRegister.CardTransactionResult.Approved) { for (int i = 0; i < ord.order.Count; i++) { RoundRegister.RecieptPrinter.PrintLine(((i + 1) + ". " + ord.order[i].ToString() + "\t$" + ord.order[i].Price + "\n")); for (int j = 0; j < ord.order[i].SpecialInstructions.Count; j++) { RoundRegister.RecieptPrinter.PrintLine(" - " + (ord.order[i].SpecialInstructions[j] + "\n")); } } RoundRegister.RecieptPrinter.CutTape(); OrderOptions oo = new OrderOptions(b, ord, co, sb); b.Child = oo; oo.NewOrder(sender, e); } else { MessageBox.Show("Error with card"); } }