Added Error Blocking in Invoice Creation

This commit is contained in:
2024-09-25 19:38:00 +02:00
parent b0f186dc4e
commit eee6060e58

View File

@@ -46,17 +46,7 @@ const itemInfo = ref({
contactEMail: null, contactEMail: null,
}) })
const tabItems = computed(() => {
return [
{
label: "Editor"
},
{
label: "Vorschau",
disabled: !itemInfo.value.customer || !itemInfo.value.letterhead
}
]
})
const letterheads = ref([]) const letterheads = ref([])
@@ -284,6 +274,18 @@ const findDocumentErrors = computed(() => {
return errors return errors
}) })
const tabItems = computed(() => {
return [
{
label: "Editor"
},
{
label: "Vorschau",
disabled: findDocumentErrors.value.filter(i => i.type === 'breaking').length > 0
}
]
})
const documentTotal = computed(() => { const documentTotal = computed(() => {
let totalNet = 0 let totalNet = 0
let total19 = 0 let total19 = 0