优化
This commit is contained in:
@@ -9,7 +9,8 @@ const escapeHtml = (value: string) => value.replace(/[&<>"']/g, char => ({ '&':
|
||||
|
||||
/** Generate labels in memory only. The later order request carries these same identities. */
|
||||
export function prepareTransferCartonLabels(rows: PrintableCargoRow[], newMark: () => string = () => {
|
||||
const bytes = crypto.getRandomValues(new Uint8Array(16))
|
||||
// 采用短箱码,业务前缀保留 BX,SKU/品名等业务信息继续单独打印,避免把业务字段拼进唯一箱码。
|
||||
const bytes = crypto.getRandomValues(new Uint8Array(6))
|
||||
return `BX-${Array.from(bytes, byte => byte.toString(16).padStart(2, '0')).join('').toUpperCase()}`
|
||||
}) {
|
||||
const total = rows.reduce((sum, row) => sum + Number(row.expectedPackageCount || 0), 0)
|
||||
|
||||
Reference in New Issue
Block a user