From 467bb42e1341a5d069b724de68a9a388cc72302c Mon Sep 17 00:00:00 2001 From: gazebo Date: Tue, 20 Aug 2019 11:43:09 +0800 Subject: [PATCH] =?UTF-8?q?-=20UpdatStore=E6=97=B6=EF=BC=8C=E5=A6=82?= =?UTF-8?q?=E6=9E=9C=E6=98=AF=E5=A4=96=E5=8D=96=E7=AE=A1=E7=90=86=EF=BC=8C?= =?UTF-8?q?=E5=BF=BD=E7=95=A5printerKey?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/jxstore/cms/store.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index 20c0f1938..e9c4183ae 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -570,6 +570,13 @@ func UpdateStore(ctx *jxcontext.Context, storeID int, payload map[string]interfa syncStatus |= model.SyncFlagStoreName } globals.SugarLogger.Debug(utils.Format4Output(valid, false)) + printerVendorID := int(utils.Interface2Int64WithDefault(valid["printerVendorID"], 0)) + if printerVendorID == 0 { + printerVendorID = store.PrinterVendorID + } + if printerVendorID == model.VendorIDXiaoWM { + delete(valid, "printerKey") + } // 网络打印机处理 if valid["printerVendorID"] != nil || valid["printerSN"] != nil || valid["printerKey"] != nil { if valid["printerVendorID"] == nil {