add confirm button for move

This commit is contained in:
2021-06-04 21:24:11 +02:00
parent 48e5809008
commit e5905902cc
6 changed files with 268 additions and 10 deletions

View File

@@ -0,0 +1,32 @@
<template>
<ul>
<li v-for="(msg, index) in warnings">
{{ $t(msg.m, msg.a) }}
</li>
</ul>
<div v-if="hasNoWarnings">
<button class="sc-button bt-green" @click="confirm">{{ $t('household_member_editor.confirmation') }}</button>
</div>
</template>
<script>
import { mapState } from 'vuex';
export default {
name: 'Confirmation',
computed: {
...mapState({
warnings: (state) => state.warnings,
hasNoWarnings: (state) => state.warnings.length === 0,
}),
},
methods: {
confirm() {
this.$store.dispatch('confirm');
}
}
}
</script>