From 68ddeb54686ef8d0dd5a7e43f77c2059ccddc843 Mon Sep 17 00:00:00 2001 From: liujiangyong Date: Wed, 2 Aug 2023 22:55:17 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BC=96=E7=A0=81=E9=80=89=E6=8B=A9=E4=BC=98?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- weapp/src/packages/patrol/index.jsx | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/weapp/src/packages/patrol/index.jsx b/weapp/src/packages/patrol/index.jsx index ed1f1350..d4bb46e6 100644 --- a/weapp/src/packages/patrol/index.jsx +++ b/weapp/src/packages/patrol/index.jsx @@ -559,7 +559,13 @@ const Index = () => { } setRoadStartSel(roadStart) setRoadEndSel(roadEnd) - if (routeName) setRoad(routeName) + setRoadSectionStart('') + setRoadSectionEnd('') + if (routeName) { + setRoad(routeName) + } else { + setRoad('') + } if (kind === 'conserve' && routeCode) { request.get(getReportList(), { limit: 1, page: 0, codeRoad: routeCode }).then(res => { if (res.statusCode === 200 && res.data.length) { @@ -630,6 +636,11 @@ const Index = () => { if (value.length >= 9) { queryConserveInfo(roadCodeHead, value) } else { + setRoadStartSel([]) + setRoadEndSel([]) + setRoadSectionStart('') + setRoadSectionEnd('') + setRoad('') if (!patrolContentEdit) { setPatrolContentEdit(true) let nextInfo = { ...conserveInfo } @@ -941,6 +952,11 @@ const Index = () => { if (roadCodeEnd.length >= 9) { queryConserveInfo(e.detail.value[0], roadCodeEnd) } else { + setRoadStartSel([]) + setRoadEndSel([]) + setRoadSectionStart('') + setRoadSectionEnd('') + setRoad('') if (!patrolContentEdit) { setPatrolContentEdit(true) let nextInfo = { ...conserveInfo }