Skip to content

Commit

Permalink
Merge pull request #218 from rsksmart/new-search-rns-integration
Browse files Browse the repository at this point in the history
fix: reload data
  • Loading branch information
ezequiel-rodriguez authored Jun 7, 2024
2 parents 0642f47 + 8d55930 commit 93d59a2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/DataPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ export default {
return {
storedTitle: '',
storedRouteName: null,
storedUrlParam: null,
PAGE_COLORS
}
},
Expand Down Expand Up @@ -301,10 +302,12 @@ export default {
const key = this.reqKey
if (!module || !action) return
const routeName = this.$route.name
const urlParam = this.$route.params.address
// If the parameters are the same when the router changes, we do not request the address information.
if (this.storedRouteName !== routeName) {
if (this.storedRouteName !== routeName || !urlParam) {
// use Date for a random info
this.storedRouteName = routeName || new Date()
this.storedUrlParam = urlParam
return this.fetchRouteData({ action, params, module, key })
}
},
Expand Down

0 comments on commit 93d59a2

Please sign in to comment.