Collection<ItemsOrdered> items = (Collection<ItemsOrdered>) req.getSession().getAttribute(SESSION_ATTRIBUTE_ORDERED_ITEMS);
try {
order = service.store(order);
l.info("order "+order.getId()+" created");
ItemsOrderedService is = new ItemsOrderedService();
for (ItemsOrdered item : items) {
item.setOrders(order);
is.store(item);
l.info("item "+item.getProduct().getId()+" added to order");
}
submission.setResultMessage("Order Placed!");