| | |
| | | } |
| | | |
| | | if (canDelete && handleDelete) { |
| | | operations.push({ key: 'delete', label: t('common.actions.delete'), icon: 'ri:delete-bin-5-line', color: 'var(--art-error)' }) |
| | | operations.push({ |
| | | key: 'delete', |
| | | label: t('common.actions.delete'), |
| | | icon: 'ri:delete-bin-5-line', |
| | | color: 'var(--art-error)' |
| | | }) |
| | | } |
| | | |
| | | return [ |
| | |
| | | label: t('table.index'), |
| | | width: 72, |
| | | align: 'center' |
| | | }, |
| | | { |
| | | prop: 'id', |
| | | label: t('table.id'), |
| | | width: 90, |
| | | align: 'center', |
| | | formatter: (row) => row.id ?? '--' |
| | | }, |
| | | { |
| | | prop: 'stationAreaId', |
| | |
| | | width: 96, |
| | | align: 'center', |
| | | formatter: (row) => { |
| | | const status = getBasStationAreaStatusOptions(t).find((item) => Number(item.value) === Number(row.status)) |
| | | const status = getBasStationAreaStatusOptions(t).find( |
| | | (item) => Number(item.value) === Number(row.status) |
| | | ) |
| | | const text = status?.label || row.statusText || '--' |
| | | const type = Number(row.status) === 1 ? 'success' : Number(row.status) === 0 ? 'danger' : 'info' |
| | | const type = |
| | | Number(row.status) === 1 ? 'success' : Number(row.status) === 0 ? 'danger' : 'info' |
| | | return h(ElTag, { type, effect: 'light' }, () => text) |
| | | } |
| | | }, |
| | | { |
| | | prop: 'updateByText', |
| | | label: t('table.updateBy'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true, |
| | | formatter: (row) => row.updateByText || '--' |
| | | }, |
| | | { |
| | | prop: 'updateTimeText', |
| | |
| | | formatter: (row) => row.updateTimeText || '--' |
| | | }, |
| | | { |
| | | prop: 'createByText', |
| | | label: t('table.createBy'), |
| | | minWidth: 120, |
| | | showOverflowTooltip: true, |
| | | formatter: (row) => row.createByText || '--' |
| | | }, |
| | | { |
| | | prop: 'createTimeText', |
| | | label: t('table.createTime'), |
| | | minWidth: 170, |
| | | showOverflowTooltip: true, |
| | | formatter: (row) => row.createTimeText || '--' |
| | | }, |
| | | { |
| | | prop: 'memo', |
| | | label: t('pages.basicInfo.basStationArea.search.memo'), |
| | | minWidth: 180, |