This commit is contained in:
邹宗楠
2026-03-06 16:07:37 +08:00
parent 31e92ff4f0
commit c075f733a3
2 changed files with 12 additions and 8 deletions

View File

@@ -1729,6 +1729,9 @@ func GetMatterStoreOrderCount(ctx *jxcontext.Context, storeID int) (result *Orde
flag = false
}
orderTime = *orderPay.PayFinishedAt
if time.Now().Sub(orderTime) > 30*24*time.Hour {
orderTime = time.Now().AddDate(0, -1, 0)
}
} else {
orderTime = time.Now().AddDate(0, -1, 0)
flag = true

View File

@@ -29,6 +29,7 @@ func init() {
partner.RegisterPrinterPlatform(CurPrinterHandler)
}
// getOrderContent 添加了BOLD 标签
func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel string, storeDetail *dao.StoreDetail) (content string) {
expectedDeliveryTime := order.ExpectedDeliveredTime
if utils.IsTimeZero(expectedDeliveryTime) {
@@ -54,9 +55,9 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
<CB>%s#%d</CB><BR>
<C><BOLD>%s:%s</BOLD></C><BR>
--------------------------------<BR>
下单时间: %s<BR>
预计送达: %s<BR>
订单编号: %s<BR>
<BOLD>下单时间: %s</BOLD><BR>
<BOLD>预计送达: %s</BOLD><BR>
<BOLD>订单编号: %s</BOLD><BR>
`
if order.BusinessType == model.BusinessTypeDingshida {
orderFmt += `
@@ -71,8 +72,8 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
<QR>%s</QR><BR>
` + getCode +
`客户: %s<BR>
电话: %s<BR>
地址: %s<BR>
<BOLD>电话: %s</BOLD><BR>
<BOLD>地址: %s</BOLD><BR>
<BR>
客户备注: <BR>
<BOLD>%s</BOLD><BR>
@@ -98,7 +99,7 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
order.BuyerComment,
// jxutils.IntPrice2StandardCurrencyString(order.ActualPayPrice),
)
//switch order.EarningType {
//switch order.EarningType { z
//case model.EarningTypePoints: // 扣点
// orderFmt += pricePoints
//case model.EarningTypeQuote: // 报价
@@ -107,9 +108,9 @@ func (c *PrinterHandler) getOrderContent(order *model.GoodsOrder, storeTel strin
for _, sku := range order.Skus {
if sku.Count > 1 {
orderFmt += `%s <RIGHT><BOLD>%s</BOLD></RIGHT><BR>`
orderFmt += `<BOLD>%s <RIGHT>%s</RIGHT></BOLD><BR>`
} else {
orderFmt += `%s <RIGHT>%s</RIGHT><BR>`
orderFmt += `<BOLD>%s <RIGHT>%s</RIGHT></BOLD><BR>`
}
orderParams = append(orderParams, sku.SkuName, "x"+utils.Int2Str(sku.Count))
//switch order.EarningType {