59e51671
“wangming”
1
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
import testTemplateJson from './test.json'
import { adaptSystemLabelTemplate } from '../systemTemplateAdapter'
import type { LabelTemplateData, StructuredLabelTemplate, SystemLabelTemplate } from '../types/printer'
export const TEST_PRINT_SYSTEM_TEMPLATE = testTemplateJson as SystemLabelTemplate
export const TEST_PRINT_TEMPLATE_DATA: LabelTemplateData = {}
export function createTestPrintTemplate (
dpi = 203,
printQty = 1,
data: LabelTemplateData = TEST_PRINT_TEMPLATE_DATA
): StructuredLabelTemplate {
return adaptSystemLabelTemplate(TEST_PRINT_SYSTEM_TEMPLATE, data, {
dpi,
printQty,
})
}
|