// pages/xunjianmore/xunjianmore.js import http from '../../base/httputil' const app = getApp() Page({ /** * 页面的初始数据 */ data: { host: app.globalData.host, buslogid: null, mapdata: null, pictureBasePath: null, hiddenName: true, isHave_xqzgtzs: false, isHave_fcyjtzs: false, isRefresh: false, }, onLoad(e) { this.initData(e) }, onShow() { console.log("!!!!", this.data.buslogid) let pages = getCurrentPages(); let currPage = pages[pages.length - 1]; this.data.isRefresh = currPage.data.isRefresh; console.log("!@!@!@", this.data.isRefresh) if (this.data.isRefresh) { this.setData({ mapdata: null, pictureBasePath: null, hiddenName: true, isHave_xqzgtzs: false, isHave_fcyjtzs: false, isRefresh: false, }) let obj = new Object() obj.busLogId = this.data.buslogid http.post("/system/AppXunjianimgController/getXunjianimgList", obj, this.getXunjianMoreListSuccess) } }, initData(e) { let buslogid = e.buslogid this.data.buslogid = buslogid console.log("####", this.data.buslogid) let obj = new Object() obj.busLogId = this.data.buslogid http.post("/system/AppXunjianimgController/getXunjianimgList", obj, this.getXunjianMoreListSuccess) }, getXunjianMoreListSuccess(res) { console.log("@@@@@", res) this.setData({ pictureBasePath: res.data.pictureBasePath + "/", mapdata: res.data.xunjianimgMap, isHave_xqzgtzs: res.data.isHave_xqzgtzs, isHave_fcyjtzs: res.data.isHave_fcyjtzs, }) }, bindViewZhengGaiJinDu(e) { let businspectionid = e.currentTarget.dataset.businspectionid console.log("more:", businspectionid) console.log("more:", this.data.buslogid) wx.navigateTo({ url: '../zhenggaijindu/zhenggaijindu?busInspectionId=' + businspectionid + "&buslogId=" + this.data.buslogid, }) }, // 按钮显示隐藏 shghnn: function () { this.setData({ hiddenName: !this.data.hiddenName }) }, // 跳转整改进度 bindViewXqZgGzS() { wx.navigateTo({ url: '../xqzggzs/xqzggzs?logId=' + this.data.buslogid, }) }, })