diff --git a/src/components/pages/DetailAnggaran.vue b/src/components/pages/DetailAnggaran.vue index a600b746af3a84b2170ec8a9479578500947a02f..4f1929c7812033088396d60c9eadd331061c4f2c 100644 --- a/src/components/pages/DetailAnggaran.vue +++ b/src/components/pages/DetailAnggaran.vue @@ -150,23 +150,6 @@ export default { } }) }, - getDataFromTop() { - let fetchData = { - method: 'POST', - body: JSON.stringify({ year: 2019 }), - headers: { "Content-Type": "application/json" } - } - - fetch(`${this.$store.state.baseUrl}/api/page/get-top`, fetchData) - .then(response => response.json()) - .then(response => { - if(response.status === 200) { - this.data = response.subdata - this.currentData = response.data - this.breadcrumbHandler() - } - }) - }, toggleHandler() { this.toggleData = !this.toggleData this.getData(this.currentData._id.$oid, false) @@ -178,8 +161,7 @@ export default { }, watch: { $route(to, from) { - if (!this.$route.params.id) this.getDataFromTop() - else this.getData(this.$route.params.id, true) + this.getData(this.$route.params.id, true) this.$refs.viz.clear() }, }