小程式迴圈發起請求方案
阿新 • • 發佈:2019-02-17
var projectList = wx.getStorageSync('projectList'); var e = projectList; for (var n = 0; n < e.length; n++) { wxb.Post('/api/automatic.index/insertProduct', { title: e[n].title, value: e[n].value, imgUrl: projectList[n]['img_url'] }, function (data) { if(data.code){} });