From 2b7ab08d8c0604771b178cd725d083f5707c7f1d Mon Sep 17 00:00:00 2001 From: "gao.zhiyuan" Date: Wed, 28 Jun 2023 16:04:17 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A8=E6=80=81=E4=BF=AE=E6=94=B9=E4=B8=8A?= =?UTF-8?q?=E6=8A=A5=E9=A1=B5=E7=9A=84=E6=A0=87=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- weapp/src/packages/patrol/index.jsx | 49 +++++++++++++++++++++---- weapp/src/packages/patrolView/index.jsx | 8 ++++ 2 files changed, 50 insertions(+), 7 deletions(-) diff --git a/weapp/src/packages/patrol/index.jsx b/weapp/src/packages/patrol/index.jsx index 2e134da7..3fd0ba20 100644 --- a/weapp/src/packages/patrol/index.jsx +++ b/weapp/src/packages/patrol/index.jsx @@ -1,6 +1,6 @@ import React, { useState, useEffect } from 'react'; import Taro, { useRouter } from '@tarojs/taro'; -import { View, RadioGroup, Radio, Image, Input, Picker } from '@tarojs/components'; +import { View, RadioGroup, Radio, Image, Input, Picker, Video } from '@tarojs/components'; import { AtButton, AtTextarea, AtImagePicker } from 'taro-ui'; import InputPicker from '../components/inputPicker'; import VideoUpload from '../../components/uploads' @@ -75,6 +75,12 @@ const Index = () => { ]) useEffect(() => { + if (isRoad) { + Taro.setNavigationBarTitle({ title: '在建道路' }) + } if (isAnomaly) { + Taro.setNavigationBarTitle({ title: '异常反馈' }) + } + if (isView) { // 查看 Taro.showLoading({ title: '加载中' }) request.get(getReportDetail(router.params.id)).then(res => { @@ -558,17 +564,46 @@ const Index = () => { onImageClick={handleImgClick} /> } - {/* - { - Taro.chooseVideo({ - sourceType: ['album', 'camera'], - maxDuration: 60, + + {/* */} : 养护图片: diff --git a/weapp/src/packages/patrolView/index.jsx b/weapp/src/packages/patrolView/index.jsx index b317dfa1..e508a139 100644 --- a/weapp/src/packages/patrolView/index.jsx +++ b/weapp/src/packages/patrolView/index.jsx @@ -33,6 +33,14 @@ function Index () { const limit = 10 + useEffect(() => { + if (isRoad) { + Taro.setNavigationBarTitle({ title: '在建道路' }) + } if (isAnomaly) { + Taro.setNavigationBarTitle({ title: '异常反馈' }) + } + }, []) + useEffect(() => { setPage(0) setNum(Math.random())