This commit is contained in:
邹宗楠
2026-05-12 17:54:40 +08:00
parent de1c4d00de
commit 9d19b162cc

View File

@@ -386,11 +386,11 @@ func DoPrintMsg(appID int, msgID, printNo, content string, orderNo string) (err
Status: event.PrintMsgWait, Status: event.PrintMsgWait,
} }
t, ok := event.TcpClientList.Load(printNo) t, ok := event.PrintObject.GetPrintObj(printNo)
if ok { if ok {
t.(*event.TcpClient).Lock() t.Lock()
defer t.(*event.TcpClient).Unlock() defer t.Unlock()
t.(*event.TcpClient).MsgMap[printNo] <- printMsg t.MsgMap[printNo] <- printMsg
printMsg.Status = event.PrintMsgAlreadyLoad printMsg.Status = event.PrintMsgAlreadyLoad
} /*else { } /*else {
t = event.NewTcpClient() t = event.NewTcpClient()