diff --git a/README.md b/README.md index fb71320..64a699d 100644 --- a/README.md +++ b/README.md @@ -755,3 +755,11 @@ fix fix - 话费查询 - 修复 token过期时导致获取openId失败的问题 + + + +## v1.0.95 +`2023.10.30` +fix +- 话费查询 + - 修复 异步问题导致首次进入页面白屏的问题 \ No newline at end of file diff --git a/public/index.html b/public/index.html index 4ec6181..b23ae0b 100644 --- a/public/index.html +++ b/public/index.html @@ -1,7 +1,7 @@ @@ -10,7 +10,7 @@ - + diff --git a/src/config/models.js b/src/config/models.js index df192ec..c5bb08a 100644 --- a/src/config/models.js +++ b/src/config/models.js @@ -5,7 +5,7 @@ * @FilePath: \TelpoH5FrontendWeb\src\config\models.js * @description: */ -export const VERSION_MODEL = '1.0.94F'; //版本号 +export const VERSION_MODEL = '1.0.95F'; //版本号 export const IMAGE_URL = { production: 'http://zfb.ssjlai.com/web/', test: 'http://zfb.ssjlai.com/web/', diff --git a/src/router/index.js b/src/router/index.js index 2540538..c31845c 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -1,7 +1,7 @@ /* * @Date: 2023-09-21 09:54:53 * @LastEditors: JinxChen - * @LastEditTime: 2023-10-13 11:30:23 + * @LastEditTime: 2023-10-30 11:31:37 * @FilePath: \TelpoH5FrontendWeb\src\router\index.js * @description: */ @@ -61,6 +61,8 @@ const routes = [ { path: '/psychological', name: 'psychological', component: resolve => require(['@/views/health/psychological'], resolve) }, // 健康-抑郁,压力和疲劳汇总入口 { path: '/psychologicalMain', name: 'psychologicalMain', component: resolve => require(['@/views/health/psychological-main'], resolve) }, + // 周报/月报 + { path: '/psychologicalReport', name: 'psychologicalReport', component: resolve => require(['@/views/health/psychological/report'], resolve) }, // 告警详情-中间页 { path: '/aiCallAlarm', name: 'aiCallAlarm', component: resolve => require(['@/views/ai-call-alarm'], resolve) }, diff --git a/src/views/card-info/index.vue b/src/views/card-info/index.vue index 3fe6e41..a56ba84 100644 --- a/src/views/card-info/index.vue +++ b/src/views/card-info/index.vue @@ -1,7 +1,7 @@ @@ -171,13 +171,13 @@ export default { // 根据code获取openId getOpenId(code) { let openId = this.$store.getters.openId; - APIPay.getOpenId(code).then(res => { + APIPay.getOpenId(code).then( async res => { let data= res.data; if(data.code === 20000) { this.$store.commit("openId", data.data.openId); }else if (data.state === false) { console.log("token过期"); - let hasToken = this.getToken(); + let hasToken = await this.getToken(); if(hasToken) { this.getOpenId(this.code); } else { diff --git a/src/views/health/psychological/report.vue b/src/views/health/psychological/report.vue new file mode 100644 index 0000000..e4a5e25 --- /dev/null +++ b/src/views/health/psychological/report.vue @@ -0,0 +1,36 @@ + + + + + + diff --git a/src/views/package-home/index.vue b/src/views/package-home/index.vue index 466aabc..fce4ae0 100644 --- a/src/views/package-home/index.vue +++ b/src/views/package-home/index.vue @@ -1,7 +1,7 @@ @@ -41,8 +41,7 @@ export default { // 3.如果有基础套餐并且已充值,跳转费查询页面 // 4.如果有基础套餐但未充值,跳转套餐充值页面 getDevicePayPackage() { - return new Promise((resolve, reject) => { - APICore.devicePayPackage(this.params.imei) + APICore.devicePayPackage(this.params.imei) .then(res => { let data = res.data; if (data.code === 106 || data.code === 104) { @@ -52,15 +51,11 @@ export default { }, 1500); } else { // 筛选是否存在基础套餐, producModelId = 1 是基础套餐, 2 是加油包 - const isHasBasePackage = data.data.packagesList.some(res => { + this.isHasBasePackage = data.data.packagesList.some(res => { return res.producModelId === 1; }); - resolve(isHasBasePackage); } - }).catch(e => { - reject(false); - }) - }) + }).catch(() => {}) }, checkImei() { let reqBody = { @@ -182,7 +177,7 @@ export default { }, // 获取url传过来的参数 - async getParams() { + getParams() { let params = this.$route.query; if (params) { this.params = {...params}; @@ -191,7 +186,7 @@ export default { const reqUrl = encodeURI(params.reqUrl); window.location.href = reqUrl; } else { - this.isHasBasePackage = await this.getDevicePayPackage(); + this.getDevicePayPackage(); this.checkImei(); } }