mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-07-07 12:31:15 +03:00
sort preview cameras in history by ui order
This commit is contained in:
parent
4ee12e6237
commit
105d1e8885
@ -75,11 +75,13 @@ export default function Events() {
|
|||||||
return [] as string[];
|
return [] as string[];
|
||||||
}
|
}
|
||||||
|
|
||||||
return Object.keys(config.cameras).filter(
|
return Object.values(config.cameras)
|
||||||
(cam) =>
|
.filter(
|
||||||
allowedCameras.includes(cam) &&
|
(conf) =>
|
||||||
config.cameras[cam]?.ui?.review !== false,
|
allowedCameras.includes(conf.name) && conf.ui?.review !== false,
|
||||||
);
|
)
|
||||||
|
.sort((aConf, bConf) => aConf.ui.order - bConf.ui.order)
|
||||||
|
.map((conf) => conf.name);
|
||||||
}, [allowedCameras, config?.cameras]);
|
}, [allowedCameras, config?.cameras]);
|
||||||
|
|
||||||
const selectedMotionSearchCamera = useMemo(() => {
|
const selectedMotionSearchCamera = useMemo(() => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user