optimize loading status
This commit is contained in:
parent
8d0de6eea8
commit
b680699a0c
@ -115,8 +115,9 @@ export default {
|
|||||||
AppFooter,
|
AppFooter,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
const chains = this.$store.state.chains.config
|
||||||
return {
|
return {
|
||||||
chains: [],
|
chains,
|
||||||
downImg: require('@/assets/images/pages/under-maintenance.svg'),
|
downImg: require('@/assets/images/pages/under-maintenance.svg'),
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -131,7 +132,7 @@ export default {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.chains = JSON.parse(localStorage.getItem('chains'))
|
this.fetch()
|
||||||
this.timer = setInterval(this.fetch, 120000)
|
this.timer = setInterval(this.fetch, 120000)
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
@ -139,6 +140,7 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
fetch() {
|
fetch() {
|
||||||
|
console.log('fetch')
|
||||||
Object.keys(this.chains).forEach(k => {
|
Object.keys(this.chains).forEach(k => {
|
||||||
const chain = this.chains[k]
|
const chain = this.chains[k]
|
||||||
if (chain.api) {
|
if (chain.api) {
|
||||||
|
Loading…
Reference in New Issue
Block a user