From 6a88d21f103b9078612a71b19cb31adb7e4f5f57 Mon Sep 17 00:00:00 2001 From: ouyangxq <775153912@qq.com> Date: Fri, 4 Sep 2026 15:54:36 +0800 Subject: [PATCH] fix: compact smart loading text --- .../pages/ContainersView.test.ts | 4 ++-- .../pages/ContainersView.vue | 4 ++-- .../pages/GlobalSmartLoadingView.test.ts | 2 +- .../pages/GlobalSmartLoadingView.vue | 2 +- .../pages/SmartLoadingWorkbenchView.test.ts | 4 +++- .../pages/SmartLoadingWorkbenchView.vue | 20 +++++++++++-------- src/modules/container-loading/routes.ts | 4 ++-- 7 files changed, 23 insertions(+), 17 deletions(-) diff --git a/src/modules/container-loading/pages/ContainersView.test.ts b/src/modules/container-loading/pages/ContainersView.test.ts index b0666730..116af506 100644 --- a/src/modules/container-loading/pages/ContainersView.test.ts +++ b/src/modules/container-loading/pages/ContainersView.test.ts @@ -123,11 +123,11 @@ describe('ContainersView', () => { const wrapper = mount(ContainersView, { global: { plugins: [ElementPlus, router] } }) await flushPromises() - expect(wrapper.text()).toContain('排柜') + expect(wrapper.text()).toContain('智能装柜') expect(wrapper.text()).toContain('预装清单') expect(wrapper.text()).toContain('装柜清单') - await wrapper.findAll('button').find((button) => button.text().trim() === '排柜')!.trigger('click') + await wrapper.findAll('button').find((button) => button.text().trim() === '智能装柜')!.trigger('click') await wrapper.findAll('button').find((button) => button.text().includes('预装清单'))!.trigger('click') await wrapper.findAll('button').find((button) => button.text().includes('装柜清单'))!.trigger('click') expect(push).toHaveBeenNthCalledWith(1, { name: 'smart-loading-workbench', params: { containerId: '9001' } }) diff --git a/src/modules/container-loading/pages/ContainersView.vue b/src/modules/container-loading/pages/ContainersView.vue index d363b1ca..bc578e49 100644 --- a/src/modules/container-loading/pages/ContainersView.vue +++ b/src/modules/container-loading/pages/ContainersView.vue @@ -135,7 +135,7 @@ const queryFields = computed(() => [ { key: 'customerId', type: 'select', label: '客户', width: 220, placeholder: '全部客户', options: customers.value.filter((customer) => customer.status === 'ACTIVE').map((customer) => ({ label: customer.tenantName, value: String(customer.id) })), props: { filterable: true, loading: customersLoading.value } }, { key: 'keyword', type: 'input', label: '关键词', width: 220, placeholder: '柜次号、集装箱号或提单号', props: { 'aria-label': '关键词', maxlength: 128 } }, { key: 'containerType', type: 'select', label: '柜型', width: 140, placeholder: '请选择箱型', options: CONTAINER_SPECIFICATIONS.map((item) => ({ label: item.type, value: item.type })), props: { 'aria-label': '柜型' } }, - { key: 'status', type: 'select', label: '排柜状态', width: 150, placeholder: '请选择货柜状态', options: [{ label: '待装柜', value: 'WAIT_LOADING' }, { label: '预装柜中', value: 'EDITING' }, { label: '拣货中', value: 'LOADING' }, { label: '装柜完成', value: 'COMPLETED' }], props: { 'aria-label': '排柜状态' } }, + { key: 'status', type: 'select', label: '装柜状态', width: 150, placeholder: '请选择货柜状态', options: [{ label: '待装柜', value: 'WAIT_LOADING' }, { label: '预装柜中', value: 'EDITING' }, { label: '拣货中', value: 'LOADING' }, { label: '装柜完成', value: 'COMPLETED' }], props: { 'aria-label': '装柜状态' } }, { key: 'sailingRange', type: 'daterange', label: '预计开船', width: 260, props: { 'aria-label': '预计开船日期范围' } }, ]) const columns: DataTableColumn[] = [ @@ -536,7 +536,7 @@ onMounted(async () => {
- + diff --git a/src/modules/container-loading/pages/GlobalSmartLoadingView.test.ts b/src/modules/container-loading/pages/GlobalSmartLoadingView.test.ts index ce48d116..9ddb6211 100644 --- a/src/modules/container-loading/pages/GlobalSmartLoadingView.test.ts +++ b/src/modules/container-loading/pages/GlobalSmartLoadingView.test.ts @@ -525,7 +525,7 @@ describe('GlobalSmartLoadingView', () => { expect(document.body.textContent).toContain('平均单箱体积 待测量') expect(document.body.textContent).not.toContain('平均单箱毛重 0 kg') expect(document.body.textContent).toContain('订单渠道:慢船') - expect(document.body.textContent).toContain('这是人工排柜,确认后仍会加入') + expect(document.body.textContent).toContain('这是人工装柜分配,确认后仍会加入') expect(document.body.textContent).toContain('智能推荐不会跨渠道') ;([...document.body.querySelectorAll('button')] .find((button) => button.textContent?.includes('确认加入')) as HTMLButtonElement).click() diff --git a/src/modules/container-loading/pages/GlobalSmartLoadingView.vue b/src/modules/container-loading/pages/GlobalSmartLoadingView.vue index f0f5be9f..24b468ef 100644 --- a/src/modules/container-loading/pages/GlobalSmartLoadingView.vue +++ b/src/modules/container-loading/pages/GlobalSmartLoadingView.vue @@ -794,7 +794,7 @@ onMounted(() => { void load(); void loadCustomers() })

目标柜次:{{ displayCabinetNo(selectedContainer) }} · 集装箱号:{{ displayActualContainerNo(selectedContainer) }}

发货仓:{{ selectedContainer?.warehouseName || '—' }} · 柜次渠道:{{ selectedContainer?.channelName || '—' }}

订单渠道:{{ selectedCandidate.channelName || '—' }}

- +