fix: limit dispatch vehicle choices
This commit is contained in:
@@ -136,6 +136,7 @@ describe('DispatchesView', () => {
|
||||
expect(source).toContain('removeDispatchItem')
|
||||
expect(source).not.toContain('托盘箱唛确认')
|
||||
expect(source).not.toContain('palletCartonMarks')
|
||||
expect(source).toContain('dispatchVehicleSizeOptions')
|
||||
expect(source).not.toContain('departDispatch')
|
||||
|
||||
canPermission.mockReturnValue(false)
|
||||
|
||||
@@ -19,6 +19,7 @@ import AppDialog from '@/shared/components/AppDialog.vue'
|
||||
import type { DispatchListItem } from '../types'
|
||||
import { formatOverseasDateTime } from '../lastMilePresentation'
|
||||
import { overseasWarehousePermissions as permission } from '../permissions'
|
||||
import { dispatchVehicleSizeOptions } from '../dispatchVehicleSpecs'
|
||||
|
||||
const router = useRouter()
|
||||
const access = useAccessPreviewStore()
|
||||
@@ -100,7 +101,7 @@ const loadingTypeOptions = [
|
||||
{ label: '混装', value: 'MIXED' },
|
||||
]
|
||||
const vehicleTypeOptions = ['厢式货车', '平板车', '冷藏车', '集装箱卡车', '尾板车'].map((label) => ({ label, value: label }))
|
||||
const vehicleSizeOptions = ['53尺大车(30托)', '26尺中车(14托)', '16尺小车(8托)', 'Cargo Van(4托)'].map((label) => ({ label, value: label }))
|
||||
const vehicleSizeOptions = dispatchVehicleSizeOptions
|
||||
const appointmentAccountOptions = [
|
||||
{ label: '4号账号(美西)', value: '4' },
|
||||
{ label: '8号账号(美东)', value: '8' },
|
||||
|
||||
@@ -284,6 +284,12 @@ describe('overseas warehouse first-batch prototype contract', () => {
|
||||
expect(dialog).not.toContain('`normal-${mark}`')
|
||||
expect(dialog).not.toContain('暂无箱唛')
|
||||
expect(dialog).toContain('class="warehouse-tabs density-tabs"')
|
||||
expect(dialog).toContain('dispatchVehicleSpecs')
|
||||
const vehicleSpecs = source('../dispatchVehicleSpecs.ts')
|
||||
expect(vehicleSpecs).toContain("label: '大车(30托)'")
|
||||
expect(vehicleSpecs).toContain("label: '小车(15托)'")
|
||||
expect(vehicleSpecs).not.toContain('14托')
|
||||
expect(vehicleSpecs).not.toContain('12托')
|
||||
expect(dialog).not.toContain('排车路线(选填)')
|
||||
expect(dialog).not.toContain('v-model="route"')
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user