import common from '../../utils/util'; import main from '../../utils/main'; const app = getApp(); Page({ data: { Menu:0, List:[], TestList:[], ImagePath: app.globalData.uploadImageUrl, }, onLoad: function (options) { var that = this; that.setData({ Containnerheight: main.getWindowHeight(), }); }, onShow:function(){ var that = this; wx.showLoading({ title: '请稍候', mask: true, }); main.getData('GetMiaoguoTestIndex?UserID='+app.globalData.userInfo.UserID, function (data) { wx.hideLoading(); if (data) { that.setData({ List:data.List1, TestList:data.List2, }); } }); }, setMenu:function(e){ var that=this; var index=e.currentTarget.dataset.index; that.setData({ Menu:index, }); }, goto: function (e) { var url = e.currentTarget.dataset.url; wx.navigateTo({ url: url, }); }, onShareAppMessage: function () { return { title: app.globalData.ShareTitle, path: app.globalData.SharePath + '?UserID=' + app.globalData.userInfo.UserID, imageUrl: app.globalData.ShareImage, } }, })