feat: refs #6896 add dashIfEmpty filter for medical center name in WorkerMedical component
gitea/salix-front/pipeline/pr-test This commit looks good Details

This commit is contained in:
Pablo Natek 2025-02-21 07:24:11 +01:00
parent 484ceb709a
commit ea6874c0db
1 changed files with 5 additions and 1 deletions

View File

@ -3,6 +3,7 @@ import { ref, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRoute } from 'vue-router';
import VnTable from 'components/VnTable/VnTable.vue';
import { dashIfEmpty } from 'src/filters';
const tableRef = ref();
const { t } = useI18n();
const route = useRoute();
@ -44,9 +45,12 @@ const columns = [
create: true,
component: 'select',
attrs: {
url: 'centers',
url: 'medicalCenters',
fields: ['id', 'name'],
},
format: (row, dashIfEmpty) => {
return dashIfEmpty(row.center?.name);
},
},
{
align: 'left',