feat: Add cameras[].media.severities to filter review media by severity
Review queries were issued without a severity filter, so the thumbnail
bar, gallery and timeline showed every Frigate review item -- alerts and
detections alike -- regardless of what a camera is configured to alert
on. Severity could only be narrowed interactively, in the media filter
drawer, and that choice did not persist.
`media.severities` resolves into the default query the same way
`media.reviewed` does, and is overridden by an explicit severity filter
so the media filter drawer keeps working. Unset means all severities, so
existing behaviour is unchanged.
cameras:
- camera_entity: camera.office
media:
severities:
- high
This commit is contained in:
@@ -223,6 +223,10 @@ const cameraMediaConfigSchema = z.object({
|
||||
reviewed: z
|
||||
.enum(CAMERA_MEDIA_REVIEWED_FILTERS)
|
||||
.default(cameraMediaConfigDefault.reviewed),
|
||||
|
||||
// Restrict review media to these severities (e.g. `[high]` for Frigate
|
||||
// alerts only). Unset means all severities.
|
||||
severities: severitySchema.array().min(1).optional(),
|
||||
});
|
||||
|
||||
export const cameraConfigSchema = z
|
||||
|
||||
Reference in New Issue
Block a user