diff --git a/src/components/AccountListTable/const.js b/src/components/AccountListTable/const.js index 48f869856..7f491c815 100644 --- a/src/components/AccountListTable/const.js +++ b/src/components/AccountListTable/const.js @@ -1,24 +1,25 @@ -import ChoicesFormatter from '@/components/TableFormatters/ChoicesFormatter' import i18n from '@/i18n/i18n' +import { ChoicesFormatter } from '@/components/TableFormatters' export const connectivityMeta = { - label: i18n.t('assets.Reachable'), + label: i18n.t('assets.Connectivity'), formatter: ChoicesFormatter, formatterArgs: { faChoices: { + '-': '', ok: 'fa-check-circle', - failed: 'fa-times-circle', - unknown: 'fa fa-question-circle' + err: 'fa-times-circle' }, classChoices: { ok: 'text-primary', - failed: 'text-danger', - unknown: 'fa fa-question-circle' + err: 'text-danger' }, - textChoices: { - ok: 'Avail', - failed: 'Failed', - unknown: '-' + getText({ cellValue }) { + if (cellValue.value === '-') { + return '-' + } else { + return cellValue.label + } } }, width: '100px', diff --git a/src/components/TableFormatters/ChoicesFormatter.vue b/src/components/TableFormatters/ChoicesFormatter.vue index 518859591..752f7e72b 100644 --- a/src/components/TableFormatters/ChoicesFormatter.vue +++ b/src/components/TableFormatters/ChoicesFormatter.vue @@ -1,6 +1,6 @@