feat(client): surface Excel draft import in order creation
This commit is contained in:
@@ -324,7 +324,8 @@ test('collects the backend-required first-leg fields', () => {
|
||||
}
|
||||
assert.match(source, /form\.channelName = channel\?\.channelName/)
|
||||
assert.match(source, /v-model="item\.woodenProduct"/)
|
||||
assert.match(source, /货物包含木制品,提交前必须选择“是”/)
|
||||
assert.match(source, /第 \{\{ woodenCargoLines\.join\('、'\) \}\} 条货物已勾选木制品/)
|
||||
assert.match(source, /第 \{\{ index \+ 1 \}\} 条须商检/)
|
||||
})
|
||||
|
||||
test('distills order creation into the confirmed prototype sections with server pricing', () => {
|
||||
@@ -337,14 +338,21 @@ test('distills order creation into the confirmed prototype sections with server
|
||||
assert.match(source, /class="segmented-options"/)
|
||||
assert.match(source, /class="prototype-form-row prototype-form-row--tabs"/)
|
||||
assert.match(source, /<table class="cargo-edit-table">/)
|
||||
assert.match(source, /批量导入订单/)
|
||||
assert.match(source, /isCreatePage && !routeDraftId && canCreateOrder[\s\S]*Excel 批量导入/)
|
||||
assert.match(source, /导入成功的数据只创建草稿,不会直接提交审核/)
|
||||
assert.match(source, /下载正式模板[\s\S]*选择 Excel/)
|
||||
assert.match(source, /仅支持 \.xlsx,文件不超过 5MB、最多 50 行/)
|
||||
assert.match(source, /cargo\.woodenProduct(true\/false)[\s\S]*customsInspection 必须填写 true/)
|
||||
assert.match(source, /下载 Excel 错误报告/)
|
||||
assert.match(source, /batchImportError[\s\S]*requestId[\s\S]*traceId/)
|
||||
assert.match(source, /添加行[\s\S]*删除所选行/)
|
||||
assert.doesNotMatch(source, /货物明细导入模板\.xls/)
|
||||
for (const heading of ['SKU NO.', '中文品名', '箱规长 cm', '总毛重', '报关 HS CODE', '货件编号', '跟踪编号', 'UPC NO.']) {
|
||||
assert.ok(cargoTableSource.includes(heading))
|
||||
}
|
||||
assert.ok(cargoTableSource.indexOf('包装类型') < cargoTableSource.indexOf('危险品'))
|
||||
assert.ok(cargoTableSource.indexOf('危险品') < cargoTableSource.indexOf('货件编号'))
|
||||
assert.ok(cargoTableSource.indexOf('木制品') < cargoTableSource.indexOf('货件编号'))
|
||||
assert.match(source, /参考运费/)
|
||||
assert.match(source, /仅供参考,最终以实际结算为准/)
|
||||
assert.doesNotMatch(source, /v-model="form\.(?:businessType|origin|destination|priority|tradeTerm)"/)
|
||||
|
||||
Reference in New Issue
Block a user