1
This commit is contained in:
@@ -2,6 +2,7 @@ package xpyun
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"git.rosy.net.cn/baseapi/utils"
|
"git.rosy.net.cn/baseapi/utils"
|
||||||
@@ -78,6 +79,9 @@ func (c *PrinterHandler) RegisterPrinter(ctx *jxcontext.Context, sn, id2, printe
|
|||||||
if globals.EnableStoreWrite {
|
if globals.EnableStoreWrite {
|
||||||
err = api.XpyunAPI.AddPrinters(sn, printerName)
|
err = api.XpyunAPI.AddPrinters(sn, printerName)
|
||||||
}
|
}
|
||||||
|
if strings.Contains(err.Error(), "打印机已存在") {
|
||||||
|
return "", "", nil
|
||||||
|
}
|
||||||
return "", "", err
|
return "", "", err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user