refactor: refs #7566 fix customer summary

This commit is contained in:
Jon Elias 2024-06-18 13:29:17 +02:00
parent fa55e33b54
commit 546b43ffcf
1 changed files with 7 additions and 17 deletions

View File

@ -162,6 +162,7 @@ const navigateToticketSummary = (id) => {
params: { id },
});
};
const commonColumns = (col) => ['date', 'state', 'total'].includes(col);
</script>
<template>
@ -189,27 +190,16 @@ const navigateToticketSummary = (id) => {
class="rounded-borders"
v-bind="tableColumnComponents[props.col.name].props(props)"
>
<template
v-if="
props.col.name === 'id' ||
props.col.name === 'nickname' ||
props.col.name === 'agency' ||
props.col.name === 'route' ||
props.col.name === 'packages'
"
>
<template v-if="!commonColumns(props.col.name)">
<span
v-if="
props.col.name === 'nickname' ||
props.col.name === 'route'
"
class="link"
:class="{
link:
props.col.name === 'route' ||
props.col.name === 'nickname',
}"
>
{{ props.value }}
</span>
<span v-else>
{{ props.value }}
</span>
</template>
<template v-if="props.col.name === 'date'">
<QBadge class="q-pa-sm" color="warning">