Minor Changes in Invoice Creation

This commit is contained in:
2024-09-19 19:34:41 +02:00
parent c546e2cf3c
commit 93a2d96c21
2 changed files with 25 additions and 13 deletions

View File

@@ -207,7 +207,8 @@ const addPosition = (mode) => {
quantity: 1,
price: 0,
taxPercent: 19,
discountPercent: 0
discountPercent: 0,
unit: 1
})
} else if(mode === 'service'){
itemInfo.value.rows.push({
@@ -216,7 +217,8 @@ const addPosition = (mode) => {
quantity: 1,
price: 0,
taxPercent: 19,
discountPercent: 0
discountPercent: 0,
unit: 1
})
} else if(mode === "pagebreak") {
itemInfo.value.rows.push({
@@ -515,7 +517,7 @@ setupPage()
<div v-if="item.label === 'Editor'">
<InputGroup>
<div class="flex-auto mr-5">
<div class="w-1/3 mr-5">
<UFormGroup
label="Dokumenttyp:"
>
@@ -708,7 +710,7 @@ setupPage()
</InputGroup>
</UFormGroup>
</div>
<div class="flex-auto">
<div class="w-2/3">
<UFormGroup
:label="itemInfo.documentNumberTitle + ':'"
>
@@ -977,7 +979,6 @@ setupPage()
>
<UInput
v-model="row.text"
maxlength="40"
placeholder="Name"
/>
</td>
@@ -986,7 +987,9 @@ setupPage()
v-else-if="row.mode === 'normal'"
>
<USelectMenu
class="w-40"
:options="dataStore.products"
:color="row.product ? 'primary' : 'rose'"
option-attribute="name"
value-attribute="id"
searchable
@@ -994,7 +997,7 @@ setupPage()
:search-attributes="['name']"
v-model="row.product"
@change="row.unit = dataStore.getProductById(row.product).unit,
row.price = dataStore.getProductById(row.product).sellingPrice || 0,
row.price = (dataStore.getProductById(row.product).sellingPrice || 0),
row.description = dataStore.getProductById(row.product).description"
>
<template #label>
@@ -1010,7 +1013,9 @@ setupPage()
v-else-if="row.mode === 'service'"
>
<USelectMenu
class="w-40"
:options="dataStore.services"
:color="row.service ? 'primary' : 'rose'"
option-attribute="name"
value-attribute="id"
searchable
@@ -1022,7 +1027,7 @@ setupPage()
row.description = dataStore.getServiceById(row.service).description"
>
<template #label>
{{dataStore.getServiceById(row.service) ? dataStore.getServiceById(row.service).name : "Keine Leistung ausgewählt" }}
<span class="truncate">{{dataStore.getServiceById(row.service) ? dataStore.getServiceById(row.service).name : "Keine Leistung ausgewählt" }}</span>
</template>
</USelectMenu>
</td>