Merge pull request '#7566 fixed summary cards and table' (!444) from 7566-FixCustomerSummary into dev
gitea/salix-front/pipeline/head This commit looks good
Details
gitea/salix-front/pipeline/head This commit looks good
Details
Reviewed-on: #444 Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
This commit is contained in:
commit
97c4130b05
|
@ -159,9 +159,9 @@ function existSummary(routes) {
|
||||||
margin-top: 2px;
|
margin-top: 2px;
|
||||||
.label {
|
.label {
|
||||||
color: var(--vn-label-color);
|
color: var(--vn-label-color);
|
||||||
width: 8em;
|
width: 9em;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
white-space: nowrap;
|
white-space: wrap;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
flex-grow: 0;
|
flex-grow: 0;
|
||||||
|
|
|
@ -306,10 +306,8 @@ const creditWarning = computed(() => {
|
||||||
:value="entity.recommendedCredit"
|
:value="entity.recommendedCredit"
|
||||||
/>
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard>
|
<QCard class="vn-one">
|
||||||
<div class="header">
|
<VnTitle :text="t('Latest tickets')" />
|
||||||
{{ t('Latest tickets') }}
|
|
||||||
</div>
|
|
||||||
<CustomerSummaryTable />
|
<CustomerSummaryTable />
|
||||||
</QCard>
|
</QCard>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -162,6 +162,7 @@ const navigateToticketSummary = (id) => {
|
||||||
params: { id },
|
params: { id },
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
const commonColumns = (col) => ['date', 'state', 'total'].includes(col);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -171,13 +172,13 @@ const navigateToticketSummary = (id) => {
|
||||||
auto-load
|
auto-load
|
||||||
url="Tickets"
|
url="Tickets"
|
||||||
/>
|
/>
|
||||||
|
<QCard class="vn-one q-py-sm flex justify-between">
|
||||||
<QTable
|
<QTable
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:pagination="{ rowsPerPage: 12 }"
|
:pagination="{ rowsPerPage: 12 }"
|
||||||
:rows="rows"
|
:rows="rows"
|
||||||
class="full-width q-mt-md"
|
class="full-width"
|
||||||
row-key="id"
|
row-key="id"
|
||||||
v-if="rows?.length"
|
|
||||||
>
|
>
|
||||||
<template #body-cell="props">
|
<template #body-cell="props">
|
||||||
<QTd :props="props" @click="navigateToticketSummary(props.row.id)">
|
<QTd :props="props" @click="navigateToticketSummary(props.row.id)">
|
||||||
|
@ -185,19 +186,19 @@ const navigateToticketSummary = (id) => {
|
||||||
<component
|
<component
|
||||||
:is="tableColumnComponents[props.col.name].component"
|
:is="tableColumnComponents[props.col.name].component"
|
||||||
@click="tableColumnComponents[props.col.name].event(props)"
|
@click="tableColumnComponents[props.col.name].event(props)"
|
||||||
class="rounded-borders q-pa-sm"
|
class="rounded-borders"
|
||||||
v-bind="tableColumnComponents[props.col.name].props(props)"
|
v-bind="tableColumnComponents[props.col.name].props(props)"
|
||||||
>
|
>
|
||||||
<template
|
<template v-if="!commonColumns(props.col.name)">
|
||||||
v-if="
|
<span
|
||||||
props.col.name === 'id' ||
|
:class="{
|
||||||
props.col.name === 'nickname' ||
|
link:
|
||||||
props.col.name === 'agency' ||
|
|
||||||
props.col.name === 'route' ||
|
props.col.name === 'route' ||
|
||||||
props.col.name === 'packages'
|
props.col.name === 'nickname',
|
||||||
"
|
}"
|
||||||
>
|
>
|
||||||
{{ props.value }}
|
{{ props.value }}
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="props.col.name === 'date'">
|
<template v-if="props.col.name === 'date'">
|
||||||
<QBadge class="q-pa-sm" color="warning">
|
<QBadge class="q-pa-sm" color="warning">
|
||||||
|
@ -232,6 +233,7 @@ const navigateToticketSummary = (id) => {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
</QTable>
|
</QTable>
|
||||||
|
</QCard>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<i18n>
|
<i18n>
|
||||||
|
|
Loading…
Reference in New Issue