From 18525d7f450f2ed54bcfe0c97e8d123848b61b5d Mon Sep 17 00:00:00 2001 From: shijingjing <1789544664@qq.com> Date: Mon, 10 Oct 2022 15:28:59 +0800 Subject: [PATCH] =?UTF-8?q?=E5=81=A5=E5=BA=B7=E4=B8=8A=E6=8A=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pingchang/AppHealthReport/AddReport.vue | 9 +-- .../pingchang/AppHealthReport/AddUser.vue | 3 +- .../AppHealthReport/AppHealthReport.vue | 6 +- .../pingchang/AppHealthReport/Detail.vue | 56 +++++++++---------- .../pingchang/AppHealthReport/RecordList.vue | 22 ++------ .../pingchang/AppHealthReport/Result.vue | 8 ++- 6 files changed, 46 insertions(+), 58 deletions(-) diff --git a/src/project/pingchang/AppHealthReport/AddReport.vue b/src/project/pingchang/AppHealthReport/AddReport.vue index ffad4bf..07d484f 100644 --- a/src/project/pingchang/AppHealthReport/AddReport.vue +++ b/src/project/pingchang/AppHealthReport/AddReport.vue @@ -186,10 +186,6 @@ export default { ...mapState(['user']) }, - // onShow() { - // this.$dict.load(['epidemicTouchInFourteen','EP_healthType','EP_nucleicAcidResult','EP_jkmType','epidemicVaccineTime']).then(()=> {}) - // }, - onLoad(query) { this.$dict.load(['epidemicTouchInFourteen','EP_healthType','EP_nucleicAcidResult','EP_jkmType','EP_vaccinationCount']).then(()=> { this.form.reportUserId = query.id @@ -247,9 +243,8 @@ export default { this.$loading() this.$instance.post(`/app/appepidemicpreventionhealthreportinfo/addReportInfo`, { ...this.form, - // openid: this.user.openid, - jkmUrl: this.form.jkmUrlArr.toString(), - nucleicAcidUrl: this.form.nucleicAcidUrlArr.toString(), + jkmUrl: this.form.jkmUrlArr[0].url, + nucleicAcidUrl: this.form.nucleicAcidUrlArr[0].url, nucleicAcidDate: this.form.nucleicAcidDate + ' 00:00:00' }).then(res => { if (res.code == 0) { diff --git a/src/project/pingchang/AppHealthReport/AddUser.vue b/src/project/pingchang/AppHealthReport/AddUser.vue index 0c31964..aca6cde 100644 --- a/src/project/pingchang/AppHealthReport/AddUser.vue +++ b/src/project/pingchang/AppHealthReport/AddUser.vue @@ -138,9 +138,8 @@ export default { this.$toast('提交成功') uni.$emit('update') setTimeout(() => { - // ?id=${res.data.id} uni.redirectTo({ - url: `./Result` + url: `./Result?id=${res.data.id}&name=${res.data.name}&idNumber=${res.data.idNumber}` }) }, 400) } diff --git a/src/project/pingchang/AppHealthReport/AppHealthReport.vue b/src/project/pingchang/AppHealthReport/AppHealthReport.vue index a12474f..30d7df8 100644 --- a/src/project/pingchang/AppHealthReport/AppHealthReport.vue +++ b/src/project/pingchang/AppHealthReport/AppHealthReport.vue @@ -13,14 +13,14 @@

{{ item.name }}

-

查看个人信息>

+
- 健康数据异常 + 健康数据异常
健康上报第 - {{ item.searchCount || 0 }} + {{ item.reportCount || 0 }}
14天内是否接触新冠确诊或疑似患者
- {{ $dict.getLabel('epidemicTouchInFourteen', info.touchInFourteen) }} + {{ $dict.getLabel('epidemicTouchInFourteen', info.contactPatients) }}
@@ -23,7 +23,7 @@
- {{ info.healthName }} + {{ $dict.getLabel('EP_healthType', info.health) }}
@@ -34,7 +34,7 @@
- {{ info.checkTime.split(' ')[0] }} + {{ info.nucleicAcidDate && info.nucleicAcidDate.substr(0, info.nucleicAcidDate.length - 8 ) }}
@@ -42,7 +42,7 @@
- {{ $dict.getLabel('epidemicRecentTestResult', info.checkResult) }} + {{ $dict.getLabel('EP_nucleicAcidResult', info.nucleicAcidResult) }}
@@ -50,7 +50,7 @@
- {{ $dict.getLabel('epidemicHealthCode', info.healthCode) }} + {{ $dict.getLabel('EP_jkmType', info.jkmType) }}
@@ -58,15 +58,23 @@
- {{ $dict.getLabel('epidemicVaccineTime', info.vaccine) }} + {{ $dict.getLabel('EP_vaccinationCount', info.vaccinationCount) }}
-
+
- + +
+
+
+
+ +
+
+
@@ -79,13 +87,15 @@ data () { return { info: {}, - pageShow: false + pageShow: false, + jkmUrlArr: [], + nucleicAcidUrlArr: [], } }, onLoad (query) { this.$loading() - this.$dict.load(['epidemicTouchInFourteen', 'epidemicRecentHealth', 'epidemicRecentTestResult', 'epidemicHealthCode', 'epidemicVaccineTime']).then(() => { + this.$dict.load(['epidemicTouchInFourteen', 'EP_healthType', 'EP_nucleicAcidResult', 'EP_jkmType', 'EP_vaccinationCount']).then(() => { this.getInfo(query.id) }) }, @@ -93,32 +103,22 @@ methods: { preview (url) { uni.previewImage({ - urls: this.info.checkPhoto.map(v => v.url), + urls: [url], current: url }) }, getInfo (id) { - this.$instance.post(`/app/appepidemichealthreport/queryDetailById?id=${id}`).then(res => { + this.$instance.post(`/app/appepidemicpreventionhealthreportinfo/queryDetailById?id=${id}`).then(res => { if (res.code === 0) { this.info = res.data - this.info.checkPhoto = JSON.parse(res.data.checkPhoto) - let healthName = '' - this.info.isHealth = false - res.data.health.split(',').forEach(v => { - if (v > 0) { - this.info.isHealth = true - } - healthName = healthName + this.$dict.getLabel('epidemicRecentHealth', v) - }) - this.info.healthName = healthName - - this.$nextTick(() => { - this.pageShow = true - }) + this.jkmUrlArr.push({url: res.data.jkmUrl}) + this.nucleicAcidUrlArr = [res.data.nucleicAcidUrl] + this.pageShow = true + this.$hideLoading() + } else { + this.$loading() } - - this.$hideLoading() }) }, diff --git a/src/project/pingchang/AppHealthReport/RecordList.vue b/src/project/pingchang/AppHealthReport/RecordList.vue index e5bc507..b3bd3ad 100644 --- a/src/project/pingchang/AppHealthReport/RecordList.vue +++ b/src/project/pingchang/AppHealthReport/RecordList.vue @@ -4,7 +4,7 @@ hover-class="bg-hover">
{{ item.createTime.split(' ')[0] }}的健康上报
- 健康数据异常 + 健康数据异常
@@ -33,29 +33,18 @@ export default { methods: { getList(query) { if (this.isMore) return - - this.$instance.post(`/app/appepidemichealthreport/list?memberId=${query.id}`, null, { + this.$instance.post(`/app/appepidemicpreventionhealthreportinfo/list?reportUserId=${query.id}`, null, { params: { current: this.current, - size: 15 + size: 10 } }).then(res => { if (res.code == 0) { this.total = res.data.total - if (this.current > 1) { - this.list = [...this.list, ...res.data.records] - } else { - this.list = res.data.records - } + this.list = this.current == 1? res.data.records:[...this.list, ...res.data.records] uni.hideLoading() this.pageShow = true - if (res.data.records.length < 15) { - this.isMore = true - - return false - } - - this.current = this.current + 1 + this.isMore = true } else { uni.hideLoading() } @@ -66,6 +55,7 @@ export default { }, onReachBottom() { + this.current ++ this.getList() } } diff --git a/src/project/pingchang/AppHealthReport/Result.vue b/src/project/pingchang/AppHealthReport/Result.vue index 61a002e..034c8f7 100644 --- a/src/project/pingchang/AppHealthReport/Result.vue +++ b/src/project/pingchang/AppHealthReport/Result.vue @@ -11,12 +11,16 @@ export default { data () { return { - id: '' + id: '', + name: '', + idNumber: '', } }, onLoad (query) { this.id = query.id + this.name = query.name + this.idNumber = query.idNumber }, methods: { @@ -28,7 +32,7 @@ toReport () { uni.redirectTo({ - url: `./AddReport?id=${this.id}` + url: `./AddReport?id=${this.id}&name=${this.name}&idNumber=${this.idNumber}` }) } }