From 60644a74b361542ad63c7b9fcc447cc6e9d30f2e Mon Sep 17 00:00:00 2001 From: Mathis Kral Date: Sun, 19 Nov 2023 14:58:38 +0100 Subject: [PATCH] fixup! Update basics of order package to salespoint --- src/main/java/catering/order/OrderController.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/catering/order/OrderController.java b/src/main/java/catering/order/OrderController.java index 4a8445c..247517a 100644 --- a/src/main/java/catering/order/OrderController.java +++ b/src/main/java/catering/order/OrderController.java @@ -132,7 +132,9 @@ public class OrderController { return userAccount.map(account -> { CustomOrder myOrder = new CustomOrder(account.getId(), cart); + cart.addItemsTo(myOrder); orderManagement.payOrder(myOrder); // TODO: change this later + orderManagement.completeOrder(myOrder); cart.clear(); List myOrders = orderManagement.findBy(account).stream().collect(Collectors.toList());