From b440605225cfa5d2feb1581b1018ca48e82ccefd Mon Sep 17 00:00:00 2001 From: zhaobing Date: Fri, 4 Aug 2023 08:38:43 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E6=8A=BD=E6=9F=A5=E7=9A=84=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sections/fillion/containers/maintenanceSpotCheck.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/web/client/src/sections/fillion/containers/maintenanceSpotCheck.js b/web/client/src/sections/fillion/containers/maintenanceSpotCheck.js index 918b945a..4fcbd1aa 100644 --- a/web/client/src/sections/fillion/containers/maintenanceSpotCheck.js +++ b/web/client/src/sections/fillion/containers/maintenanceSpotCheck.js @@ -80,7 +80,7 @@ const DetailForm = (props) => { ]; const renderContent = (data) => { if (data) { - if ( moment(data.time).isAfter(moment('2023-08-03 00:00:00'))) { + if (moment(data.time).isAfter(moment('2023-08-03 00:00:00'))) { return keyList.map(obj => { return
{obj.key} @@ -282,7 +282,7 @@ const MaintenanceSpotCheck = (props) => { const [previewId, setPreviewId] = useState(0) const [reportData, setReportData] = useState([]) const [detailVisible, setDetailVisible] = useState(false) - const [dateRange, setDateRange] = useState(); + const [dateRange, setDateRange] = useState(['1970-1-1', '2099-12-31']); const { RangePicker } = DatePicker //console.log('reportData', reportData) @@ -424,7 +424,7 @@ const MaintenanceSpotCheck = (props) => { } const lookhandler = () => { if ((dateRange && dateRange instanceof Array && dateRange[0] != '')) { - queryData({ startTime: moment(dateRange[0]).startOf('day').format('YYYY-MM-DD HH:mm:ss'), endTime: moment(dateRange[1]).startOf('day').format('YYYY-MM-DD HH:mm:ss') }) + queryData({ startTime: moment(dateRange[0]).startOf('day').format('YYYY-MM-DD HH:mm:ss'), endTime: moment(dateRange[1]).endOf('day').format('YYYY-MM-DD HH:mm:ss') }) } } return ( @@ -499,7 +499,7 @@ const MaintenanceSpotCheck = (props) => {
) } -function mapStateToProps (state) { +function mapStateToProps(state) { const { auth, spotCheckDetail, reportDetail } = state //('state1', state) return {