forked from verdnatura/salix-front
refactor: refs #7361 ticket/summary like salix
This commit is contained in:
parent
e3a36c0ab1
commit
071e6a7296
|
@ -13,6 +13,7 @@ import VnLinkPhone from 'src/components/ui/VnLinkPhone.vue';
|
|||
import { getUrl } from 'src/composables/getUrl';
|
||||
import VnUserLink from 'src/components/ui/VnUserLink.vue';
|
||||
import VnTitle from 'src/components/common/VnTitle.vue';
|
||||
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
||||
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
|
@ -262,15 +263,19 @@ async function changeState(value) {
|
|||
:url="ticketUrl + 'sale'"
|
||||
:text="t('ticket.summary.saleLines')"
|
||||
/>
|
||||
<QTable :rows="ticket.sales">
|
||||
<QTable :rows="ticket.sales" style="text-align: center">
|
||||
<template #body-cell="{ value }">
|
||||
<QTd>{{ value }}</QTd>
|
||||
</template>
|
||||
<template #header="props">
|
||||
<QTr :props="props">
|
||||
<QTr class="tr-header" :props="props">
|
||||
<QTh auto-width></QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.item') }}</QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.visible') }}</QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.available') }}</QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.quantity') }}</QTh>
|
||||
<QTh auto-width>{{ t('globals.description') }}</QTh>
|
||||
<QTh auto-width></QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.price') }}</QTh>
|
||||
<QTh auto-width>{{ t('ticket.summary.discount') }}</QTh>
|
||||
<QTh auto-width>{{ t('globals.amount') }}</QTh>
|
||||
|
@ -360,23 +365,31 @@ async function changeState(value) {
|
|||
</QTooltip>
|
||||
</QIcon>
|
||||
</QTd>
|
||||
<QTd class="link">{{ props.row.itemFk }}</QTd>
|
||||
<QTd>
|
||||
<QBtn class="link" flat>
|
||||
{{ props.row.itemFk }}
|
||||
<ItemDescriptorProxy :id="props.row.itemFk" />
|
||||
</QBtn>
|
||||
</QTd>
|
||||
<QTd>{{ props.row.visible }}</QTd>
|
||||
<QTd>{{ props.row.available }}</QTd>
|
||||
<QTd>{{ props.row.quantity }}</QTd>
|
||||
<QTd>
|
||||
<div class="fetched-tags">
|
||||
<span>{{ props.row.item.name }}</span>
|
||||
<span v-if="props.row.item.subName" class="subName">{{
|
||||
props.row.item.subName
|
||||
}}</span>
|
||||
</div>
|
||||
<span>
|
||||
{{ props.row.item.name }}
|
||||
</span>
|
||||
<fetched-tags
|
||||
class="fetched-tags"
|
||||
:item="props.row.item"
|
||||
:max-length="5"
|
||||
></fetched-tags>
|
||||
</QTd>
|
||||
<QTd>{{ props.row.price }}</QTd>
|
||||
<QTd>
|
||||
<span v-if="props.row.item.subName" class="subName">
|
||||
{{ props.row.item.subName.toUpperCase() }}
|
||||
</span>
|
||||
</QTd>
|
||||
<QTd>{{ props.row.price }} €</QTd>
|
||||
<QTd>{{ props.row.discount }} %</QTd>
|
||||
<QTd
|
||||
>{{
|
||||
|
@ -453,4 +466,26 @@ async function changeState(value) {
|
|||
padding: 1%;
|
||||
}
|
||||
}
|
||||
|
||||
.q-table {
|
||||
tr,
|
||||
th,
|
||||
.q-td {
|
||||
border-bottom: 1px solid black;
|
||||
}
|
||||
}
|
||||
|
||||
.tr-header {
|
||||
color: var(--vn-label-color);
|
||||
}
|
||||
|
||||
.subName {
|
||||
color: var(--vn-label-color);
|
||||
margin-left: -40%;
|
||||
}
|
||||
|
||||
.fetched-tags {
|
||||
width: 70%;
|
||||
margin-left: 19%;
|
||||
}
|
||||
</style>
|
||||
|
|
Loading…
Reference in New Issue