Fix audio events in explore section (#15286)

* Fix audio events in explore section

Make sure that audio events are listed in the explore section

* Update audio.py

* Hide other submit options

Only allow submits for objects only
This commit is contained in:
tpjanssen
2024-12-01 15:47:37 +01:00
committed by GitHub
parent 71e8f75a01
commit 5802a66469
7 changed files with 13 additions and 5 deletions

View File

@@ -128,6 +128,7 @@ export default function SearchResultActions({
config?.plus?.enabled &&
searchResult.has_snapshot &&
searchResult.end_time &&
searchResult.data.type == "object" &&
!searchResult.plus_id && (
<MenuItem aria-label="Submit to Frigate Plus" onClick={showSnapshot}>
<FrigatePlusIcon className="mr-2 size-4 cursor-pointer text-primary" />
@@ -197,6 +198,7 @@ export default function SearchResultActions({
config?.plus?.enabled &&
searchResult.has_snapshot &&
searchResult.end_time &&
searchResult.data.type == "object" &&
!searchResult.plus_id && (
<Tooltip>
<TooltipTrigger>

View File

@@ -379,6 +379,7 @@ function EventItem({
{event.has_snapshot &&
event.plus_id == undefined &&
event.data.type == "object" &&
config?.plus.enabled && (
<Tooltip>
<TooltipTrigger>

View File

@@ -626,7 +626,7 @@ export function ObjectSnapshotTab({
</div>
)}
</TransformComponent>
{search.plus_id !== "not_enabled" && search.end_time && (
{search.data.type == "object" && search.plus_id !== "not_enabled" && search.end_time && (
<Card className="p-1 text-sm md:p-2">
<CardContent className="flex flex-col items-center justify-between gap-3 p-2 md:flex-row">
<div className={cn("flex flex-col space-y-3")}>