Show a warning if the logs are disabled to reduce confusion

This commit is contained in:
Owen
2026-08-19 16:16:05 -04:00
parent ef051c2f8c
commit 114592add8
13 changed files with 143 additions and 16 deletions
+11
View File
@@ -3,9 +3,11 @@ import { ColumnFilterButton } from "@app/components/ColumnFilterButton";
import { DateTimeValue } from "@app/components/DateTimePicker";
import { LogDataTable } from "@app/components/LogDataTable";
import { AiSessionChatView } from "@app/components/AiSessionChatView";
import LogRetentionWarning from "@app/components/LogRetentionWarning";
import SettingsSectionTitle from "@app/components/SettingsSectionTitle";
import { Button } from "@app/components/ui/button";
import { useEnvContext } from "@app/hooks/useEnvContext";
import { useOrgContext } from "@app/hooks/useOrgContext";
import { toast } from "@app/hooks/useToast";
import { createApiClient } from "@app/lib/api";
import { useTranslations } from "next-intl";
@@ -41,6 +43,8 @@ export default function AiSessionLogsPage() {
const { orgId } = useParams();
const searchParams = useSearchParams();
const { org } = useOrgContext();
const [isExporting, startTransition] = useTransition();
const [currentPage, setCurrentPage] = useState<number>(0);
@@ -641,6 +645,13 @@ export default function AiSessionLogsPage() {
description={t("aiSessionLogsDescription")}
/>
{org.org.settingsLogRetentionDaysAISessions === 0 && (
<LogRetentionWarning
orgId={orgId as string}
logTypeLabel={t("aiSessionLogs")}
/>
)}
<LogDataTable
columns={columns}
data={rows}