import request from '../../../util/http' import apiUrl from '../../../util/apiUrl' var app = getApp(); Page({ data: { isservantsettinged: true, servantName: '',//保姆姓名 weekday: '',//日前 servantTypeValue: '',//保姆工种, servantDescribleList: [], noServantList:false, noServantPic:false }, onLoad() { this.setData({ servantName: app.globalData.servantInfo.employerName, weekday: app.globalData.servantInfo.servantTaskPeriod.workDay, servantTypeValue: app.globalData.servantInfo.servantType }), console.log("employRelationNo=" + app.globalData.employRelationNo) this.initServantDescribleInfo() }, initServantDescribleInfo() { let params = { "employRelationNo": app.globalData.employRelationNo, "subjectType": "SN000001", "userType": "2" } request.httpServicePost(apiUrl.customerDescribleInfo, params).then(data => { console.log("保姆描述信息=" + data.length); if (data.length == 0) { this.setData({ noServantPic: true, noServantList:false, servantDescribleList:[] }); } else { console.log("aaa" + data[0]) for(let i=0;i { console.log(e); }) } });