diff options
author | Anton Tananaev <anton@traccar.org> | 2023-02-15 07:54:35 -0800 |
---|---|---|
committer | Anton Tananaev <anton@traccar.org> | 2023-02-15 07:54:35 -0800 |
commit | 4029ec907beb45cefe7d194aac6c983c9dea7d50 (patch) | |
tree | e6cb2c7964d6a7d22a30a2eb7db5b2a520268438 /modern/src/reports/components | |
parent | a0d1387ce7055757abd731581cc0cce632608849 (diff) | |
download | trackermap-web-4029ec907beb45cefe7d194aac6c983c9dea7d50.tar.gz trackermap-web-4029ec907beb45cefe7d194aac6c983c9dea7d50.tar.bz2 trackermap-web-4029ec907beb45cefe7d194aac6c983c9dea7d50.zip |
Fix reports button
Diffstat (limited to 'modern/src/reports/components')
-rw-r--r-- | modern/src/reports/components/ReportFilter.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modern/src/reports/components/ReportFilter.js b/modern/src/reports/components/ReportFilter.js index de692613..ff0dc146 100644 --- a/modern/src/reports/components/ReportFilter.js +++ b/modern/src/reports/components/ReportFilter.js @@ -27,7 +27,7 @@ const ReportFilter = ({ children, handleSubmit, handleSchedule, showOnly, ignore const period = useSelector((state) => state.reports.period); const from = useSelector((state) => state.reports.from); const to = useSelector((state) => state.reports.to); - const button = useSelector((state) => state.reports.button); + const [button, setButton] = useState('json'); const [description, setDescription] = useState(); const [calendarId, setCalendarId] = useState(); @@ -204,7 +204,7 @@ const ReportFilter = ({ children, handleSubmit, handleSchedule, showOnly, ignore disabled={disabled} onClick={handleClick} selected={button} - setSelected={(value) => dispatch(reportsActions.updateButton(value))} + setSelected={(value) => setButton(value)} options={readonly ? { json: t('reportShow'), export: t('reportExport'), |