Convert NewBudget and TransactionRow

This commit is contained in:
2022-02-15 08:04:25 +00:00
parent 1a79177422
commit d28c894d21
2 changed files with 20 additions and 29 deletions

View File

@ -1,26 +1,17 @@
<script lang="ts">
<script lang="ts" setup>
import Card from '../components/Card.vue';
import { defineComponent } from "vue";
import { ref } from "vue";
import { useBudgetsStore } from '../stores/budget';
export default defineComponent({
data() {
return {
dialog: false,
budgetName: ""
}
},
components: { Card },
methods: {
saveBudget() {
useBudgetsStore().NewBudget(this.$data.budgetName);
this.$data.dialog = false;
},
newBudget() {
this.$data.dialog = true;
}
}
})
const dialog = ref(false);
const budgetName = ref("");
function saveBudget() {
useBudgetsStore().NewBudget(budgetName.value);
dialog.value = false;
};
function newBudget() {
dialog.value = true;
};
</script>
<template>