From: konrad Date: Mon, 12 Jul 2010 19:17:01 +0000 (+0000) Subject: make sure cancelled orders are not shown as open X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=331cea97f32d460eee20c4db41e9082be540ae7a;p=web%2Fkonrad%2Fsmoke.git make sure cancelled orders are not shown as open git-svn-id: https://silmor.de/svn/softmagic/smoke/trunk@559 6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33 --- diff --git a/src/mwin/orderstab.cpp b/src/mwin/orderstab.cpp index b275390..43e46ca 100644 --- a/src/mwin/orderstab.cpp +++ b/src/mwin/orderstab.cpp @@ -118,11 +118,16 @@ qint64 MOrdersTab::oldestOrderStamp(int age) //helper: finds out whether an order should be printed. static inline bool candoUpdateOrders(int omode,const MOOrderInfo&ord) { + //show all? if(omode==ORDERALL)return true; + //do not show cancelled ones per default + if(ord.isCancelled())return false; + //select by mask if((omode&ORDERPAY)!=0 && ord.needsPayment())return true; if((omode&ORDERREFUND)!=0 && ord.needsRefund())return true; if((omode&ORDERUNSENT)!=0 && !ord.isSent())return true; if((omode&ORDERRESERVE)!=0 && ord.isReservation())return true; + //no match: ignore the entry return false; }