Bugfix Edit Pricelist

Gastro kann nur noch unter /gastro/pricelist und nicht unter /pricelist die preise ändern.
This commit is contained in:
Tim Gröger 2020-07-27 09:31:07 +02:00
parent 05a486a6d3
commit cc39796243
1 changed files with 7 additions and 3 deletions

View File

@ -20,7 +20,7 @@
<v-icon>{{ searchIcon }}</v-icon>
</template>
</v-text-field>
<v-dialog v-model="dialog" v-if="isGastro">
<v-dialog v-model="dialog" v-if="isGastro && isGastroPage">
<template v-slot:activator="{ on }">
<v-btn
fab
@ -190,7 +190,7 @@
</v-icon>
</template>
</v-data-table>
<v-card tile v-if="isGastro" :loading="typesLoading">
<v-card tile v-if="isGastro && isGastroPage" :loading="typesLoading">
<v-card-title>
Kategorien
<v-spacer />
@ -442,6 +442,9 @@ export default {
typesLoading: 'priceList/typesLoading',
isGastro: 'isGastro'
}),
isGastroPage() {
return this.$route.name === 'gastroPricelist'
},
formTitle() {
return this.editedIndex === -1 ? 'Neues Getränk' : 'Bearbeite Getränk'
},
@ -473,7 +476,7 @@ export default {
created() {
this.getPriceList()
this.getTypes()
if (this.isGastro) {
if (this.isGastro && this.isGastroPage) {
this.headers.push({
text: 'Aktion',
value: 'action',
@ -481,6 +484,7 @@ export default {
filterable: false
})
}
console.log(this.$route)
},
watch: {
dialog(val) {