diff --git a/me/detail/detailIOS.nvue b/me/detail/detailIOS.nvue index ee9b169..37efa87 100644 --- a/me/detail/detailIOS.nvue +++ b/me/detail/detailIOS.nvue @@ -473,12 +473,14 @@ this.getDataList(this.courseId, this.courseDetailsId); } - console.log(11111) - httpsRequest.getT('/app/course/getRedEnvelopeTips').then(res => { - if (res.code === 0) { - this.getRedEnvelopeTips = res.data - } - }) + if(uni.getStorageSync('token')){ + this.$Request.getT('/app/course/getRedEnvelopeTips').then((res) => { + if (res.code == 0) { + this.getRedEnvelopeTips = res.data; + } + }); + } + this.getScale() const sysInfo = uni.getSystemInfoSync() @@ -863,11 +865,21 @@ }, // 获取收藏状态 getMyLoveStatus() { - let data = { + let data = { + id: this.courseId, + token: uni.getStorageSync('token') + }; + let obj ={} + if (uni.getStorageSync('token')) { + obj = data + } else { + obj = { id: this.courseId, - token: uni.getStorageSync('token') - } - httpsRequest.getT('/app/course/selectCourseDetailsById', data).then(res => { + token:'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiJ9.eyJzdWIiOiIxNDI5NSIsImlhdCI6MTczNjMwNDUzMCwiZXhwIjoxNzM2OTA5MzMwfQ.kCnqu3S23kOog8OBA2GUwRWhC-dmBsYmPz5mHdaCIvaoJstm0KmYnZFxssHjx562ziFOfENXDg_OQWyzBIC5xg' + } + } + + httpsRequest.getT('/app/course/selectCourseDetailsById', obj).then(res => { if (res.code == 0) { if (res.data && res.data.isCollect && res.data.isCollect > 0) { this.isCollect = true