Procházet zdrojové kódy

打印这里,还是有问题,还要再调一下才行

张洋 před 5 roky
rodič
revize
62b172ec5c

+ 2 - 0
lewaimai_pos_windows/network/CMessagePush.cpp

@@ -530,6 +530,8 @@ void CMessagePush::HandleShouyinPrinter()
 
         CPosPrinter printer;
         printer.PrintWaimaiOrderShouyin(order);
+
+		int a = 1;
     }
 
 	AddStopNum();

+ 2 - 5
lewaimai_pos_windows/tool/CPosPrinter.cpp

@@ -1346,9 +1346,8 @@ int CPosPrinter::WriteBuf(const unsigned char* buf, int len)
                 {
                     if(GetLastError() == ERROR_IO_PENDING)
                     {
-                        WaitForSingleObject(hPort, 10000);
+                        /*WaitForSingleObject(hPort, 10000);
 
-                        //计算写入了多少字节的数据
                         DWORD numread;
                         rc = GetOverlappedResult(
                                  hPort,
@@ -1357,10 +1356,8 @@ int CPosPrinter::WriteBuf(const unsigned char* buf, int len)
                                  FALSE
                              );
 
-                        //LOG_INFO("Write success " << numread << " bytes");
+                        LOG_INFO("Write success " << numread << " bytes");*/
                     }
-
-					int a = 1;
                 }
             }
         }