From 5cb65919c2b01c5931583bc07ab23eb9cb2dfe66 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com>
Date: Tue, 2 Mar 2021 11:37:07 +0800
Subject: [PATCH] aa
---
business/partner/printer/feie/feie.go | 28 +++++++++-------
.../partner/printer/yilianyun/yilianyun.go | 32 +++++++++++--------
business/partner/printer/zhongwu/zhongwu.go | 15 +++++----
3 files changed, 43 insertions(+), 32 deletions(-)
diff --git a/business/partner/printer/feie/feie.go b/business/partner/printer/feie/feie.go
index 57757624f..c940f9b23 100644
--- a/business/partner/printer/feie/feie.go
+++ b/business/partner/printer/feie/feie.go
@@ -40,14 +40,16 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
getCode = fmt.Sprintf("饿百取货码:%s
\n", jxutils.GetEbaiOrderGetCode(order))
}
orderFmt := ``
- if storeDetail.BrandIsPrint == model.NO {
- orderFmt += `
+ if storeDetail != nil {
+ if storeDetail.BrandIsPrint == model.NO {
+ orderFmt += `
%s
`
- if order.VendorOrgCode == "34665" {
- orderParams = append(orderParams, globals.StoreNameEbai2)
- } else {
- orderParams = append(orderParams, storeDetail.BrandName)
+ if order.VendorOrgCode == "34665" {
+ orderParams = append(orderParams, globals.StoreNameEbai2)
+ } else {
+ orderParams = append(orderParams, storeDetail.BrandName)
+ }
}
}
orderFmt += `
@@ -124,14 +126,16 @@ func (c *PrinterHandler) getOrderContentBig(order *model.GoodsOrder, storeTel st
}
orderParams := []interface{}{}
orderFmt := ``
- if storeDetail.BrandIsPrint == model.NO {
- orderFmt += `
+ if storeDetail != nil {
+ if storeDetail.BrandIsPrint == model.NO {
+ orderFmt += `
%s
`
- if order.VendorOrgCode == "34665" {
- orderParams = append(orderParams, globals.StoreNameEbai2)
- } else {
- orderParams = append(orderParams, storeDetail.BrandName)
+ if order.VendorOrgCode == "34665" {
+ orderParams = append(orderParams, globals.StoreNameEbai2)
+ } else {
+ orderParams = append(orderParams, storeDetail.BrandName)
+ }
}
}
orderFmt += `
diff --git a/business/partner/printer/yilianyun/yilianyun.go b/business/partner/printer/yilianyun/yilianyun.go
index 26bb599da..1241812aa 100644
--- a/business/partner/printer/yilianyun/yilianyun.go
+++ b/business/partner/printer/yilianyun/yilianyun.go
@@ -39,14 +39,16 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
}
orderParams := []interface{}{}
orderFmt := ``
- if storeDetail.BrandIsPrint == model.NO {
- orderFmt += `
- %s\n\n
- `
- if order.VendorOrgCode == "34665" {
- orderParams = append(orderParams, globals.StoreNameEbai2)
- } else {
- orderParams = append(orderParams, storeDetail.BrandName)
+ if storeDetail != nil {
+ if storeDetail.BrandIsPrint == model.NO {
+ orderFmt += `
+ %s\n\n
+ `
+ if order.VendorOrgCode == "34665" {
+ orderParams = append(orderParams, globals.StoreNameEbai2)
+ } else {
+ orderParams = append(orderParams, storeDetail.BrandName)
+ }
}
}
orderFmt += `
@@ -117,14 +119,16 @@ func (c *PrinterHandler) getOrderContentBig(order *model.GoodsOrder, storeTel st
}
orderParams := []interface{}{}
orderFmt := ``
- if storeDetail.BrandIsPrint == model.NO {
- orderFmt += `
+ if storeDetail != nil {
+ if storeDetail.BrandIsPrint == model.NO {
+ orderFmt += `
%s\n\n
`
- if order.VendorOrgCode == "34665" {
- orderParams = append(orderParams, globals.StoreNameEbai2)
- } else {
- orderParams = append(orderParams, storeDetail.BrandName)
+ if order.VendorOrgCode == "34665" {
+ orderParams = append(orderParams, globals.StoreNameEbai2)
+ } else {
+ orderParams = append(orderParams, storeDetail.BrandName)
+ }
}
}
orderFmt += `
diff --git a/business/partner/printer/zhongwu/zhongwu.go b/business/partner/printer/zhongwu/zhongwu.go
index f9a453bb8..2ebce40b6 100644
--- a/business/partner/printer/zhongwu/zhongwu.go
+++ b/business/partner/printer/zhongwu/zhongwu.go
@@ -40,14 +40,17 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
}
orderParams := []interface{}{}
orderFmt := ``
- if storeDetail.BrandIsPrint == model.NO {
- orderFmt += `
+ if storeDetail != nil {
+
+ if storeDetail.BrandIsPrint == model.NO {
+ orderFmt += `
%s
`
- if order.VendorOrgCode == "34665" {
- orderParams = append(orderParams, globals.StoreNameEbai2)
- } else {
- orderParams = append(orderParams, storeDetail.BrandName)
+ if order.VendorOrgCode == "34665" {
+ orderParams = append(orderParams, globals.StoreNameEbai2)
+ } else {
+ orderParams = append(orderParams, storeDetail.BrandName)
+ }
}
}
orderFmt += `