Onload in the list of vant list will be triggered twice, resulting in repeated data in the list. The solution is as follows

Time:2021-3-3

1. Sometimes when the network request is very slow, the data may still be on the road and the request is not finished. As a result, if you re-enter and request again, the list data will be repeated (in fact, the data with page = 1 has been requested twice)

2. Solution: let the back-end little brother return a parameter page, which is the page that I request from his interface every time, and let him tell me what page I am currently requesting
Then judge, if the current request is the first page, and the list has data, then it must be a repeated request

`

getList () { 
      this.curId = localStorage.getItem('curId') ? localStorage.getItem('curId') : ''
      let that = this
      this.$axios(
        this.httpTournamentUrl + this.afterurl.tournamentsCheckTeam,
        {
          id: that.curId,
          page: that.page
        },
        'get'
      ).then(res => {
        that.loading = false;
        if (res.data.code == 200 && res.data.data.data.length != 0) {

          //The key point is to judge whether the request is repeated
          if (that.passList.length > 0 && res.data.data.page == 1) {
            return;
          }
          //-----end
          
          that.passList.push(...res.data.data.data)
          if (res.data.data.data.length == 8) {
            that.page = that.page + 1

            that.finished = false
          } else {
            that.finished = true
          }
        } else {
          that.finished = true
        }
      }).catch((res) => {
        that.finished = true
      })
    },

`