diff --git a/static/images/share_bg.png b/static/images/share_bg.jpg similarity index 100% rename from static/images/share_bg.png rename to static/images/share_bg.jpg diff --git a/store/user.js b/store/user.js index 45680cd..90f5171 100755 --- a/store/user.js +++ b/store/user.js @@ -59,6 +59,9 @@ export default { if (!state.address.provinceName) return '' return state.address.provinceName + state.address.cityName + state.address.countyName + state.address.detailInfo - } + }, + getToken(){ + return uni.getStorageSync('token'); + } } } diff --git a/subpkg/complete/complete.vue b/subpkg/complete/complete.vue index 061be2c..ea122d7 100644 --- a/subpkg/complete/complete.vue +++ b/subpkg/complete/complete.vue @@ -184,6 +184,7 @@ if (!res.success) return uni.$showMsg() this.questionList = res.data if (this.questionList.length != 0) { + this.questionList = res.data.reverse(); this.ask = this.questionList[0].ask; this.answer = this.questionList[0].answer; this.correctAnswer = this.questionList[0].correctAnswer; @@ -221,7 +222,7 @@ guid: this.userId }) if (!res.success) return uni.$showMsg() - this.achieveMedalImg = "http://146.56.223.227:9527/profile//2024/03/15/52ce69e2db8e362f225d3c00e10d6fdd.png" + this.achieveMedalImg = res.data if (res.data == null || res.data == "") { this.showMedal = false this.showLayer = false @@ -309,7 +310,7 @@ const width = res[0].width const height = res[0].height // 初始化画布大小 - const dpr = wx.getWindowInfo().pixelRatio + const dpr = wx.getSystemInfoSync().pixelRatio canvas.width = width * dpr canvas.height = height * dpr context.scale(dpr, dpr) @@ -327,7 +328,7 @@ context.stroke(); // 图片对象 const image = canvas.createImage() - image.src = '/static/images/share_bg.png' + image.src = '/static/images/share_bg.jpg' // 图片对象 const imageQR = canvas.createImage() console.log(this.imageQR)