diff --git a/business/jxstore/event/event_tcp.go b/business/jxstore/event/event_tcp.go index 19d95d01d..a7fa055a2 100644 --- a/business/jxstore/event/event_tcp.go +++ b/business/jxstore/event/event_tcp.go @@ -64,6 +64,7 @@ func handleConn(c net.Conn) error { } for { printRemoteAddr := c.RemoteAddr().String() + globals.SugarLogger.Debugf("--------printRemoteAddr := %s", printRemoteAddr) buffer, n, err := ConnRead(c) if err != nil { if err == io.EOF { @@ -75,6 +76,7 @@ func handleConn(c net.Conn) error { PrintAddrAndIp.DelPrintAddrAndIp(printRemoteAddr) PrintObject.DelPrintObj(printNo) PrintIpAndAddr.DelPrintIpAndAddr(printRemoteAddr) + dao.ExecuteSQL(dao.GetDB(), `UPDATE printer SET status = -1,is_online = -1 WHERE print_no = ? `, []interface{}{printNo}...) } return err