Changes
This commit is contained in:
@@ -38,13 +38,13 @@ const itemInfo = ref({
|
|||||||
dateOfPerformance: null,
|
dateOfPerformance: null,
|
||||||
paymentDays: auth.activeTenantData.standardPaymentDays,
|
paymentDays: auth.activeTenantData.standardPaymentDays,
|
||||||
customSurchargePercentage: 0,
|
customSurchargePercentage: 0,
|
||||||
createdBy: profileStore.activeProfile.id,
|
createdBy: auth.user.id,
|
||||||
title: null,
|
title: null,
|
||||||
description: null,
|
description: null,
|
||||||
startText: null,
|
startText: null,
|
||||||
endText: null,
|
endText: null,
|
||||||
rows: [],
|
rows: [],
|
||||||
contactPerson: profileStore.activeProfile.id,
|
contactPerson: auth.user.id,
|
||||||
contactPersonName: null,
|
contactPersonName: null,
|
||||||
contactTel: null,
|
contactTel: null,
|
||||||
contactEMail: null,
|
contactEMail: null,
|
||||||
@@ -1370,8 +1370,14 @@ const saveDocument = async (state, resetup = false) => {
|
|||||||
if (resetup) await setupPage()
|
if (resetup) await setupPage()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const selectedTab = ref(0)
|
||||||
|
|
||||||
const closeDocument = async () => {
|
const closeDocument = async () => {
|
||||||
|
|
||||||
|
if(selectedTab.value === 0) {
|
||||||
|
await generateDocument()
|
||||||
|
selectedTab.value = 1
|
||||||
|
} else {
|
||||||
loaded.value = false
|
loaded.value = false
|
||||||
|
|
||||||
await saveDocument("Gebucht")
|
await saveDocument("Gebucht")
|
||||||
@@ -1413,6 +1419,10 @@ const closeDocument = async () => {
|
|||||||
await useFiles().uploadFiles(fileData, [file])
|
await useFiles().uploadFiles(fileData, [file])
|
||||||
|
|
||||||
await router.push(`/createDocument/show/${itemInfo.value.id}`)
|
await router.push(`/createDocument/show/${itemInfo.value.id}`)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1538,7 +1548,7 @@ const setRowData = async (row, service = {sellingPriceComposed: {}}, product = {
|
|||||||
@click="closeDocument"
|
@click="closeDocument"
|
||||||
v-if="itemInfo.id && itemInfo.type !== 'serialInvoices'"
|
v-if="itemInfo.id && itemInfo.type !== 'serialInvoices'"
|
||||||
>
|
>
|
||||||
Fertigstellen
|
{{selectedTab === 0 ? "Vorschau zeigen" : "Fertigstellen"}}
|
||||||
</UButton>
|
</UButton>
|
||||||
<UButton
|
<UButton
|
||||||
icon="i-mdi-content-save"
|
icon="i-mdi-content-save"
|
||||||
@@ -1550,7 +1560,7 @@ const setRowData = async (row, service = {sellingPriceComposed: {}}, product = {
|
|||||||
</template>
|
</template>
|
||||||
</UDashboardNavbar>
|
</UDashboardNavbar>
|
||||||
<UDashboardPanelContent>
|
<UDashboardPanelContent>
|
||||||
<UTabs class="p-5" :items="tabItems" @change="onChangeTab" v-if="loaded">
|
<UTabs class="p-5" :items="tabItems" @change="onChangeTab" v-if="loaded" v-model="selectedTab">
|
||||||
<template #item="{item}">
|
<template #item="{item}">
|
||||||
<div v-if="item.label === 'Editor'">
|
<div v-if="item.label === 'Editor'">
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user