Commit a11c41f6 by Tuukka Kivilahti

placeslotbug, this should fix it

1 parent e5dca588
...@@ -305,12 +305,19 @@ public class BillBean implements BillBeanLocal { ...@@ -305,12 +305,19 @@ public class BillBean implements BillBeanLocal {
return; return;
} }
int count = bl.getQuantity().intValue(); int count = bl.getQuantity().intValue();
Date now = new Date(); Date now = new Date();
/*
THIS PLACE IS NOT ON HERE
now it is possibly to create and pay bill, but not receive any placeslots!!
long reserveLimit = eventbean.getPropertyLong(LanEventPropertyKey.RESERVE_UNPAID_SLOT_PERCENT); long reserveLimit = eventbean.getPropertyLong(LanEventPropertyKey.RESERVE_UNPAID_SLOT_PERCENT);
if (count * 100 / prod.getPlaces().size() > reserveLimit) { if (count * 100 / prod.getPlaces().size() > reserveLimit) {
long limitCount = prod.getPlaces().size() * reserveLimit / 100; long limitCount = prod.getPlaces().size() * reserveLimit / 100;
logbean.sendMessage(MoyaEventType.BILL_INFO, bill.getUser(), "User created bill ", bill.getId(), " for product '", prod.getName(), "' for '", count, "' products, which is bigger than reservation limit. '", limitCount, "', (", reserveLimit, "%)"); logbean.sendMessage(MoyaEventType.BILL_INFO, bill.getUser(), "User created bill ", bill.getId(), " for product '", prod.getName(), "' for '", count, "' products, which is bigger than reservation limit. '", limitCount, "', (", reserveLimit, "%)");
} }
*/
for (int i = 0; i < count; ++i) { for (int i = 0; i < count; ++i) {
PlaceSlot ps = new PlaceSlot(); PlaceSlot ps = new PlaceSlot();
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!