Rmove nav navigation and organize buttons
gitea/salix-front/pipeline/pr-dev There was a failure building this commit Details

This commit is contained in:
William Buezas 2024-06-25 09:19:12 -03:00
parent ba8145eabb
commit 4de347d0e8
2 changed files with 9 additions and 10 deletions

View File

@ -116,12 +116,12 @@ const totalDifference = computed(() => {
return rows.value.reduce((acc, item) => acc + item.component?.difference || 0, 0);
});
const showMovablecolumn = computed(() => (haveDifferences.value > 0 ? ['movable'] : []));
const haveDifferences = computed(() => _ticketData.value.sale.haveDifferences);
const haveDifferences = computed(() => _ticketData.value.sale?.haveDifferences);
const ticketHaveNegatives = () => {
let _haveNegatives = false;
let haveNotNegatives = false;
_ticketData.value.withoutNegatives = false;
_ticketData.value.sale.items.forEach((item) => {
_ticketData.value?.sale?.items.forEach((item) => {
if (item.quantity > item.movable) _haveNegatives = true;
else haveNotNegatives = true;
});

View File

@ -156,7 +156,6 @@ onBeforeMount(async () => await getTicketData());
v-model="step"
ref="stepperRef"
color="primary"
header-nav
animated
keep-alive
style="max-width: 800px; margin: auto"
@ -176,19 +175,19 @@ onBeforeMount(async () => await getTicketData());
/>
</QStep>
<template #navigation>
<QStepperNavigation>
<QStepperNavigation class="flex justify-between">
<QBtn
@click="onNextStep()"
color="primary"
:label="step === 2 ? t('basicData.finalize') : t('basicData.next')"
/>
<QBtn
v-if="step > 1"
flat
color="primary"
@click="stepperRef.previous()"
:label="t('basicData.back')"
class="q-ml-sm"
:class="{ invisible: step === 1 }"
/>
<QBtn
@click="onNextStep()"
color="primary"
:label="step === 2 ? t('basicData.finalize') : t('basicData.next')"
/>
</QStepperNavigation>
</template>