| | |
| | | import { $t } from '@/locales' |
| | | import ArtButtonMore from '@/components/core/forms/art-button-more/index.vue' |
| | | import { getWaveActionList } from './wavePage.helpers' |
| | | import WaveOrderRelaPanel from './modules/wave-order-rela-panel.vue' |
| | | |
| | | export function createWaveTableColumns({ handleActionClick, t }) { |
| | | const translate = typeof t === 'function' ? t : $t |
| | | return [ |
| | | { |
| | | type: 'expand', |
| | | width: 56, |
| | | formatter: (row) => ({ |
| | | render() { |
| | | return h(WaveOrderRelaPanel, { |
| | | waveId: row.id |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | { type: 'selection', width: 48, align: 'center' }, |
| | | { type: 'globalIndex', label: translate('table.index'), width: 72, align: 'center' }, |
| | | { |
| | | prop: 'id', |
| | | label: translate('table.id'), |
| | | width: 90, |
| | | align: 'center' |
| | | }, |
| | | { |
| | | prop: 'code', |
| | | label: translate('pages.orders.wave.table.code'), |
| | |
| | | { |
| | | prop: 'anfme', |
| | | label: translate('pages.orders.wave.table.anfme'), |
| | | width: 110, |
| | | align: 'right' |
| | | }, |
| | | { |
| | | prop: 'groupQty', |
| | | label: translate('pages.orders.wave.table.groupQty'), |
| | | width: 110, |
| | | align: 'right' |
| | | }, |
| | |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'updateByText', |
| | | label: translate('table.updateBy'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'createByText', |
| | | label: translate('table.createBy'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'statusLabel', |
| | | label: translate('pages.orders.wave.table.status'), |
| | | width: 100, |
| | |
| | | { type: Number(row.status) === 1 ? 'success' : 'danger', effect: 'light' }, |
| | | () => row.statusLabel |
| | | ) |
| | | }, |
| | | { |
| | | prop: 'memo', |
| | | label: translate('table.memo'), |
| | | minWidth: 150, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'operation', |
| | |
| | | export function createWaveDetailItemColumns(t) { |
| | | return createWavePreviewItemColumns(t) |
| | | } |
| | | |
| | | export function createWaveOrderRelaColumns(t) { |
| | | const translate = typeof t === 'function' ? t : $t |
| | | return [ |
| | | { type: 'globalIndex', label: translate('table.index'), width: 72, align: 'center' }, |
| | | { |
| | | prop: 'asnCode', |
| | | label: translate('pages.orders.wave.rela.asnCode'), |
| | | minWidth: 160, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'matnrCode', |
| | | label: translate('table.materialCode'), |
| | | minWidth: 140, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'maktx', |
| | | label: translate('table.materialName'), |
| | | minWidth: 220, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'splrBatch', |
| | | label: translate('table.supplierBatch'), |
| | | minWidth: 140, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'platOrderCode', |
| | | label: translate('pages.orders.wave.rela.platOrderCode'), |
| | | minWidth: 140, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'spec', |
| | | label: translate('pages.orders.wave.rela.spec'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { |
| | | prop: 'model', |
| | | label: translate('pages.orders.wave.rela.model'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true |
| | | }, |
| | | { prop: 'anfme', label: translate('table.quantity'), width: 100, align: 'right' }, |
| | | { prop: 'stockUnit', label: translate('table.unit'), width: 90, align: 'center' }, |
| | | { |
| | | prop: 'splrName', |
| | | label: translate('table.supplier'), |
| | | minWidth: 150, |
| | | showOverflowTooltip: true |
| | | } |
| | | ] |
| | | } |