Skip to content

Commit

Permalink
chore: notice will only shown in the first time
Browse files Browse the repository at this point in the history
  • Loading branch information
lzw5399 committed Apr 26, 2020
1 parent b937616 commit 3633178
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions dl-vue-admin/src/views/dashboard/dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ export default {
methods: {
fetchData() {
this.listLoading = true
const alreadyShowedNotice = localStorage.getItem('showedNotice')
if (alreadyShowedNotice) {
return
}
const self = this
getList(self.listQuery).then(response => {
for (var i = 0; i < response.data.length; i++) {
Expand All @@ -185,6 +189,7 @@ export default {
})
}
self.listLoading = false
localStorage.setItem('showedNotice', true)
})
}
}
Expand Down

0 comments on commit 3633178

Please sign in to comment.