release v2.0.0 #4

Merged
crimsen merged 481 commits from develop into master 2024-01-18 15:15:08 +00:00
5 changed files with 39 additions and 28 deletions
Showing only changes of commit 0d044b505a - Show all commits

View File

@ -120,27 +120,6 @@
/>
</q-popup-edit>
</q-td>
<q-td key="drink_type" :props="drinks_props">
{{ drinks_props.row.type.name }}
<q-popup-edit
v-slot="scope"
v-model="drinks_props.row.type"
buttons
label-cancel="Abbrechen"
label-set="Speichern"
@update:modelValue="updateDrink(drinks_props.row)"
>
<q-select
v-model="scope.value"
:options="drinkTypes"
option-label="name"
filled
dense
autofocus
@keyup.enter="scope.set"
/>
</q-popup-edit>
</q-td>
<q-td key="article_id" :props="drinks_props">
{{ drinks_props.row.article_id || 'o.A.' }}
<q-popup-edit
@ -161,6 +140,28 @@
/>
</q-popup-edit>
</q-td>
<q-td key="drink_type" :props="drinks_props">
{{ drinks_props.row.type.name }}
<q-popup-edit
v-slot="scope"
v-model="drinks_props.row.type"
buttons
label-cancel="Abbrechen"
label-set="Speichern"
@update:modelValue="updateDrink(drinks_props.row)"
>
<q-select
v-model="scope.value"
:options="drinkTypes"
option-label="name"
option-value='id'
filled
dense
autofocus
@keyup.enter="scope.set"
/>
</q-popup-edit>
</q-td>
<q-td key="volume_package" :props="drinks_props">
{{ drinks_props.row.volume ? `${drinks_props.row.volume} L` : 'o.A.' }}
<q-popup-edit
@ -305,8 +306,8 @@
@update:modelValue="updateDrink(drinks_props.row)"
>
<q-input
type="textarea"
v-model="scope.value"
type="textarea"
autofocus
counter
@keyup.enter.stop
@ -341,6 +342,9 @@ export default defineComponent({
const store = usePricelistStore();
onBeforeMount(() => {
void store.getDrinkTypes()
void store.getExtraIngredients()
void store.get_min_prices()
store.getPriceCalcColumn(user);
});

View File

@ -1,6 +1,5 @@
<template>
<q-btn
v-if="pricePerVolume"
color="positive"
icon-right="add"
label="Abgabe hinzufügen"

View File

@ -9,16 +9,16 @@
<div v-if="ingredient.drink_ingredient" class="col">
<div class="full-width row justify-evenly q-py-xs">
<div class="col">
{{ get_drink_ingredient_name(ingredient.drink_ingredient.drink_ingredient_id) }}
{{ get_drink_ingredient_name(ingredient.drink_ingredient.ingredient_id) }}
<q-popup-edit
v-model="ingredient.drink_ingredient.drink_ingredient_id"
v-model="ingredient.drink_ingredient.ingredient_id"
buttons
label-cancel="Abbrechen"
label-set="Speichern"
@save="updateDrink"
>
<q-select
v-model="ingredient.drink_ingredient.drink_ingredient_id"
v-model="ingredient.drink_ingredient.ingredient_id"
class="col q-px-sm"
label="Getränk"
filled

View File

@ -32,6 +32,8 @@
filled
label="Inhalt in L/Gebinde"
type="number"
step='0.01'
min='0'
/>
<q-input
v-model.number="newDrink.package_size"
@ -46,6 +48,8 @@
filled
label="Preis Netto/Gebinde"
type="number"
step='0.01'
min='0'
/>
<q-input
v-model.number="cost_per_volume"
@ -53,6 +57,9 @@
filled
label="Preis mit 19%/Liter"
:disable="calc_price_pro_volume"
type='number'
step='0.01'
min='0'
/>
<div class="row justify-between">
<q-btn v-close-popup label="Abbrechen" type="reset" />

View File

@ -15,10 +15,10 @@
<div class="text-h6">Zutaten</div>
<div v-for="ingredient in drink.volumes[0].ingredients" :key="ingredient.id">
{{
name(ingredient.drink_ingredient?.drink_ingredient_id) ||
name(ingredient.drink_ingredient?.ingredient_id) ||
ingredient.extra_ingredient?.name
}}
{{ ingredient.drink_ingredient?.volume }}
{{ ingredient.drink_ingredient?.volume ? `${ingredient.drink_ingredient?.volume * 100} cl` : '' }}
</div>
</q-card-section>
<q-card-section>
@ -55,6 +55,7 @@ export default defineComponent({
return drink.volumes.some((volume) => volume.ingredients.length > 0);
})
);
return { drinks, name };
},
});