"big merge" - do not put canceled tickets into bills
authorkonrad <konrad@6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33>
Fri, 14 May 2010 17:43:14 +0000 (17:43 +0000)
committerkonrad <konrad@6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33>
Fri, 14 May 2010 17:43:14 +0000 (17:43 +0000)
git-svn-id: https://silmor.de/svn/softmagic/smoke/trunk@449 6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33

src/dialogs/orderwin.cpp

index aa995bc..3721f97 100644 (file)
@@ -629,10 +629,10 @@ void MOrderWindow::initPrintBuffer()
 {
        //clear
        donePrintBuffer();
-       //get tickets (only valid ones)
+       //get tickets (only valid ones, only those that are to be paid)
        QList<MOTicket>tlst=m_order.tickets();
        for(int i=0;i<tlst.size();i++)
-               if(!tlst[i].ticketid().isNull())
+               if(!tlst[i].ticketid().isNull() && (tlst[i].status()&MOTicket::MaskPay)!=0)
                        printBuffer.tickets.append(tlst[i]);
        //accumulated view on tickets
        for(int i=0;i<printBuffer.tickets.size();i++){