第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問(wèn)題,去搜搜看,總會(huì)有你想問(wèn)的

axios 異步請(qǐng)求后.then()后再接.then()要怎么寫

axios 異步請(qǐng)求后.then()后再接.then()要怎么寫

森林海 2019-03-08 18:15:50
doctorComments(this.$route.params.hid, this.$route.params.fid, this.doctorHisId, this.createdon, this.pageno, 5)  //1.axios請(qǐng)求數(shù)據(jù).then(d => {//2.處理數(shù)據(jù)  let dc = new Array()  for(let i=0;i<d.list.length;i++){    dc[i] = {doctorComments:d.list[i],isZhanshiComment:false}  }  this.doctorComments = this.doctorComments.concat(dc);  this.$refs.scroller.donePullup();  }).then(()=>{//3.調(diào)用方法    this.$options.methods.compareHeightComment();})3.里面調(diào)用的方法需要doctorcommts這個(gè)數(shù)組的信息。想要用js promise的相關(guān)方法去鏈?zhǔn)秸{(diào)用,但是我這么寫3里面的方法仍然取不到2里面設(shè)置的數(shù)據(jù)。取2里面的數(shù)組長(zhǎng)度length是undfined。vue.js.各位大神,3里面的方法怎么才能取到2設(shè)置好后的值。
查看完整描述

2 回答

  • 2 回答
  • 0 關(guān)注
  • 6618 瀏覽
慕課專欄
更多

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)