From ce5d5feb3852bce82d2523d55c41ede527bbc4f4 Mon Sep 17 00:00:00 2001 From: sa0ChunLuyu Date: Mon, 2 Dec 2024 22:48:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20=E4=BD=93=E6=A3=80?= =?UTF-8?q?=E5=BC=95=E5=AF=BC=20=E5=88=B7=E6=96=B0=E9=80=BB=E8=BE=91=20?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- h5/pages/user/fenzhen/fenzhen.vue | 53 +++++++++++++++++++------------ 1 file changed, 33 insertions(+), 20 deletions(-) diff --git a/h5/pages/user/fenzhen/fenzhen.vue b/h5/pages/user/fenzhen/fenzhen.vue index 4af8623..89f7e3a 100644 --- a/h5/pages/user/fenzhen/fenzhen.vue +++ b/h5/pages/user/fenzhen/fenzhen.vue @@ -6,7 +6,8 @@ * date:2024年9月11日 19:24:50 */ import { - ref + ref, + nextTick } from "vue"; import { $api, @@ -25,8 +26,12 @@ type: String, default: "0", }, + test: { + type: String, + default: "0", + }, }); - let erweima_popup=ref(null) + let erweima_popup = ref(null) const fenzhen_list = ref(false); const check_tip_show = ref(false); const checkTipShow = (show) => { @@ -45,7 +50,7 @@ } const getFenzhenList = async (loading = true) => { if (!!loading) { - // uni.showLoading(); + // uni.showLoading(); } const response = await $api("FenzhenList", { id: $props.id, @@ -57,16 +62,21 @@ checkTipShow(response.data.check_tip) } if (fenzhen_active.value !== -1) { - fenzhen_info.value = false getFenzhenInfo(fenzhen_active.value) } setTimeout(() => { - if (!!window.location.href.includes('/pages/user/fenzhen/fenzhen') && - !window.location.href.includes('192.168.31.84:5173')) { - if(erweimaText.value==''){ + if (!!window.location.href.includes('/pages/user/fenzhen/fenzhen')) { + if (!window.location.href.includes('192.168.31.84:5173')) { + if (erweimaText.value == '') { getFenzhenList(false) } - + } else { + if (Number($props.test) === 1) { + if (erweimaText.value == '') { + getFenzhenList(false) + } + } + } } }, 1000 * 10) }); @@ -144,20 +154,23 @@ }); uni.hideLoading(); $response(response, () => { - fenzhen_info.value = response.data; + fenzhen_info.value = false + nextTick(() => { + fenzhen_info.value = response.data; + }) }); }; const useTimeShow = (time) => { return Math.ceil(Number(time)) } - let erweimaText=ref(''); - const erweima_click=(text)=>{ - erweimaText.value=text + let erweimaText = ref(''); + const erweima_click = (text) => { + erweimaText.value = text erweima_popup.value.open() } - const MaskClickFunc=()=>{ - erweimaText.value='' + const MaskClickFunc = () => { + erweimaText.value = '' console.log(erweimaText.value) } @@ -193,8 +206,8 @@ - {{ item.name }} - - {{ item.time }} - 已弃检 - + + {{ item.time }} + 已弃检 + {{ item.desc }}