Merge branch 'jdshop' of https://e.coding.net/rosydev/jx-callback into jdshop
This commit is contained in:
@@ -26,7 +26,7 @@ func TestPrintMsg(t *testing.T) {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
context := CurPrinterHandler.getOrderContent(order, "13412345678",nil)
|
||||
context := CurPrinterHandler.getOrderContent(order, "13412345678", nil)
|
||||
//context := CurPrinterHandler.getOrderContentBig(order, "13412345678")
|
||||
status, err := CurPrinterHandler.PrintMsg(jxcontext.AdminCtx, "218510310", "ztdpveyg", "test", context)
|
||||
t.Log(utils.Format4Output(status, false))
|
||||
@@ -36,7 +36,7 @@ func TestPrintMsg(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestRegisterPrinter(t *testing.T) {
|
||||
newID1, newID2, err := CurPrinterHandler.RegisterPrinter(jxcontext.AdminCtx, "218510310", "ztdpveyg", "title")
|
||||
newID1, newID2, err := CurPrinterHandler.RegisterPrinter(jxcontext.AdminCtx, "218510310", "ztdpveyg", "title", 1)
|
||||
t.Log(newID1 + "," + newID2)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
|
||||
23
business/partner/printer/jxprint/jxPrint_test.go
Normal file
23
business/partner/printer/jxprint/jxPrint_test.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package jxprint
|
||||
|
||||
import (
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils/jxcontext"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestPrintMsg(t *testing.T) {
|
||||
status, err := CurPrinterHandler.PrintMsg(jxcontext.AdminCtx, "20220818000001", "1", "test", "11")
|
||||
t.Log(utils.Format4Output(status, false))
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
func TestGetPrintStatus(t *testing.T) {
|
||||
status, err := CurPrinterHandler.GetPrinterStatus(jxcontext.AdminCtx, "20220818000001", "1")
|
||||
t.Log(utils.Format4Output(status, false))
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
@@ -97,7 +97,7 @@ func ManagerOrderPrint(order *model.GoodsOrder, storeTel string, storeDetail *da
|
||||
skuList = append(skuList, &SkuListPrintOrder{
|
||||
SkuName: sku.SkuName,
|
||||
SkuCount: "X" + utils.Int2Str(sku.Count),
|
||||
SalePrice: utils.Int64ToStr(sku.SalePrice),
|
||||
SalePrice: jxutils.IntPrice2StandardCurrencyString(sku.SalePrice),
|
||||
TotalCountPrice: jxutils.IntPrice2StandardCurrencyString(sku.SalePrice * int64(sku.Count)),
|
||||
Upc: sku.Upc,
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user