mirror of
https://github.com/umami-software/umami.git
synced 2025-12-08 05:12:36 +01:00
Allow getting team websites.
This commit is contained in:
parent
e610de383a
commit
433ce98719
10 changed files with 79 additions and 56 deletions
|
|
@ -1,20 +1,23 @@
|
|||
import Link from 'next/link';
|
||||
import { WebsitesTable } from './WebsitesTable';
|
||||
import { DataGrid } from '@/components/common/DataGrid';
|
||||
import { useNavigation, useUserWebsitesQuery } from '@/components/hooks';
|
||||
import { useLoginQuery, useNavigation, useUserWebsitesQuery } from '@/components/hooks';
|
||||
|
||||
export function WebsitesDataTable({
|
||||
userId,
|
||||
teamId,
|
||||
allowEdit = true,
|
||||
allowView = true,
|
||||
showActions = true,
|
||||
}: {
|
||||
userId?: string;
|
||||
teamId?: string;
|
||||
allowEdit?: boolean;
|
||||
allowView?: boolean;
|
||||
showActions?: boolean;
|
||||
}) {
|
||||
const queryResult = useUserWebsitesQuery({ teamId });
|
||||
const { user } = useLoginQuery();
|
||||
const queryResult = useUserWebsitesQuery({ userId: userId || user?.id, teamId });
|
||||
const { renderUrl } = useNavigation();
|
||||
|
||||
const renderLink = (row: any) => (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue