Fixed properties queries.

This commit is contained in:
Mike Cao
2025-07-15 01:31:08 -07:00
parent 465a03f987
commit 5e6799a715
38 changed files with 139 additions and 499 deletions

View File

@@ -1,21 +1,15 @@
'use client';
import { Column } from '@umami/react-zen';
import { useLoginQuery, useMessages } from '@/components/hooks';
import { useMessages } from '@/components/hooks';
import { WebsitesDataTable } from './WebsitesDataTable';
import { ROLES } from '@/lib/constants';
import { SectionHeader } from '@/components/common/SectionHeader';
import { WebsiteAddButton } from './WebsiteAddButton';
export function WebsitesSettingsPage({ teamId }: { teamId: string }) {
const { user } = useLoginQuery();
const canCreate = user.role !== ROLES.viewOnly;
const { formatMessage, labels } = useMessages();
return (
<Column gap>
<SectionHeader title={formatMessage(labels.websites)}>
{canCreate && <WebsiteAddButton teamId={teamId} />}
</SectionHeader>
<SectionHeader title={formatMessage(labels.websites)} />
<WebsitesDataTable teamId={teamId} />
</Column>
);