mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-04 19:50:55 +00:00
Fix store references
This commit is contained in:
@@ -133,7 +133,7 @@
|
||||
<script>
|
||||
import Post from "../../api/webhooks/post";
|
||||
// import {mapGetters} from "vuex";
|
||||
import {getCacheKey} from "../../store/fireflyiii/getters";
|
||||
// import {getCacheKey} from "../../store/fireflyiii/getters";
|
||||
|
||||
export default {
|
||||
name: 'Create',
|
||||
|
@@ -130,6 +130,7 @@
|
||||
<script>
|
||||
import Get from "../../api/webhooks/get";
|
||||
import Put from "../../api/webhooks/put";
|
||||
import {useFireflyIIIStore} from "../../stores/fireflyiii";
|
||||
|
||||
export default {
|
||||
name: "Edit",
|
||||
@@ -165,6 +166,7 @@ export default {
|
||||
response: '',
|
||||
delivery: '',
|
||||
trigger: '',
|
||||
store: null,
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -174,6 +176,7 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.id = parseInt(this.$route.params.id);
|
||||
this.store = useFireflyIIIStore();
|
||||
this.collectWebhook();
|
||||
},
|
||||
methods: {
|
||||
@@ -233,7 +236,7 @@ export default {
|
||||
this.errorMessage = '';
|
||||
},
|
||||
processSuccess: function (response) {
|
||||
this.$store.dispatch('fireflyiii/refreshCacheKey');
|
||||
this.store.refreshCacheKey();
|
||||
if (!response) {
|
||||
return;
|
||||
}
|
||||
|
@@ -88,6 +88,7 @@
|
||||
// import {mapGetters} from "vuex";
|
||||
import Destroy from "../../api/generic/destroy";
|
||||
import List from "../../api/webhooks/list";
|
||||
import {useFireflyIIIStore} from "../../stores/fireflyiii";
|
||||
|
||||
export default {
|
||||
name: 'Index',
|
||||
@@ -116,6 +117,7 @@ export default {
|
||||
{name: 'title', label: 'Title', field: 'title', align: 'left'},
|
||||
{name: 'menu', label: ' ', field: 'menu', align: 'right'},
|
||||
],
|
||||
store: null,
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -123,6 +125,7 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.pagination.rowsPerPage = this.getListPageSize;
|
||||
this.store = useFireflyIIIStore();
|
||||
},
|
||||
mounted() {
|
||||
this.triggerUpdate();
|
||||
@@ -140,7 +143,7 @@ export default {
|
||||
},
|
||||
destroyWebhook: function (id) {
|
||||
(new Destroy('webhooks')).destroy(id).then(() => {
|
||||
this.$store.dispatch('fireflyiii/refreshCacheKey');
|
||||
this.store.refreshCacheKey();
|
||||
this.triggerUpdate();
|
||||
});
|
||||
},
|
||||
|
Reference in New Issue
Block a user