- 重构打印机流程,添加“外卖管家”打印

This commit is contained in:
gazebo
2019-04-09 11:35:27 +08:00
parent 358257c70d
commit 8c6b1bc067
14 changed files with 500 additions and 132 deletions

View File

@@ -884,3 +884,11 @@ func RefreshEbaiBadComment(ctx *jxcontext.Context, fromTime, toTime time.Time, i
}
return hint, err
}
func PrintMsg(ctx *jxcontext.Context, vendorID int, id1, id2, msg string) (printerStatus *partner.PrinterStatus, err error) {
handler := partner.GetPrinterPlatformFromVendorID(vendorID)
if handler == nil {
return nil, fmt.Errorf("打印机厂商:%d当前不被支持请检查vendorID", vendorID)
}
return handler.PrintMsg(ctx, id1, id2, msg)
}