[pricelist] dont show 'add ingredients' if cost_per_volume exists

This commit is contained in:
Tim Gröger 2021-04-14 19:13:47 +02:00
parent 851c5a0588
commit 43397fe3a7
3 changed files with 6 additions and 3 deletions

View File

@ -31,8 +31,7 @@ export default defineComponent({
name: 'BuildManual',
props: {
steps: {
type: (Array as PropType<Array<string>>) || undefined,
required: true,
type: Array as PropType<Array<string>>,
},
editable: {
type: Boolean,

View File

@ -95,7 +95,7 @@
</div>
<div class="q-pa-sm">
<ingredients
v-if="!public"
v-if="!public && !cost_per_volume"
v-model="volume.ingredients"
:editable="editable"
@update="updateVolume(volume)"
@ -130,6 +130,9 @@ export default defineComponent({
type: Array as PropType<Array<DrinkPriceVolume>>,
required: true,
},
cost_per_volume: {
type: undefined
},
editable: {
type: Boolean,
default: false,

View File

@ -125,6 +125,7 @@
<q-card-section :key="key">
<drink-price-volumes
v-model="edit_volumes"
:cost_per_volume='cost_per_volume'
editable
@update="updateVolume"
@delete-volume="deleteVolume"