This commit is contained in:
richboo111
2023-03-28 14:39:34 +08:00
parent da93ae79da
commit 09959ccddb
9 changed files with 592 additions and 21 deletions

View File

@@ -21,7 +21,7 @@ var api = New(UserName, UserKey)
//测试格式化商品列表
func TestFormatPrintOrderItem(t *testing.T) {
str := FormatPrintOrderItem("测试商品名字", 100, 8.78)
str := "鱼不用杀😁【如遇缺货】:缺货时电话与我沟通 收货人隐私号 17882960804_9913手机号 191****1675"
fmt.Println(str)
request := &PrintRequest{
RestRequest: api.GenerateRestRequest(),
@@ -37,7 +37,7 @@ func TestFormatPrintOrderItem(t *testing.T) {
}
func TestPrint(t *testing.T) {
printContent := ""
printContent = printContent + "<IMG></IMG><BR><C>" + "<B>京西菜市</B>" + "<BR></C>"
printContent = printContent + "<IMG></IMG><RH n=\"1\"><C>" + "<B>京西菜市</B>" + "</RH><BR></C>"
printContent += StrRepeat("-", 32)
printContent += "<BR><L>下单时间2023-03-16 15:30:28"
printContent += "<BR><L>预计送达2023-03-16 16:30:28"