fixup! Update basics of order package to salespoint

This commit is contained in:
Mathis Kral 2023-11-19 14:58:38 +01:00
parent bd0df0c9b4
commit 60644a74b3

View file

@ -132,7 +132,9 @@ public class OrderController {
return userAccount.map(account -> { return userAccount.map(account -> {
CustomOrder myOrder = new CustomOrder(account.getId(), cart); CustomOrder myOrder = new CustomOrder(account.getId(), cart);
cart.addItemsTo(myOrder);
orderManagement.payOrder(myOrder); // TODO: change this later orderManagement.payOrder(myOrder); // TODO: change this later
orderManagement.completeOrder(myOrder);
cart.clear(); cart.clear();
List<CustomOrder> myOrders = orderManagement.findBy(account).stream().collect(Collectors.toList()); List<CustomOrder> myOrders = orderManagement.findBy(account).stream().collect(Collectors.toList());