mirror of
https://github.com/umami-software/umami.git
synced 2026-02-15 10:05:36 +01:00
Updated website, team and user save.
This commit is contained in:
parent
2fa50892d8
commit
fec81695e8
15 changed files with 128 additions and 117 deletions
|
|
@ -2,16 +2,7 @@
|
|||
import { ReactNode } from 'react';
|
||||
import WebsitesTable from 'app/(main)/settings/websites/WebsitesTable';
|
||||
import DataTable from 'components/common/DataTable';
|
||||
import useWebsites from 'components/hooks/queries/useWebsites';
|
||||
|
||||
export interface WebsitesDataTableProps {
|
||||
userId?: string;
|
||||
teamId?: string;
|
||||
allowEdit?: boolean;
|
||||
allowView?: boolean;
|
||||
showActions?: boolean;
|
||||
children?: ReactNode;
|
||||
}
|
||||
import { useWebsites } from 'components/hooks';
|
||||
|
||||
export function WebsitesDataTable({
|
||||
userId,
|
||||
|
|
@ -20,13 +11,21 @@ export function WebsitesDataTable({
|
|||
allowView = true,
|
||||
showActions = true,
|
||||
children,
|
||||
}: WebsitesDataTableProps) {
|
||||
}: {
|
||||
userId?: string;
|
||||
teamId?: string;
|
||||
allowEdit?: boolean;
|
||||
allowView?: boolean;
|
||||
showActions?: boolean;
|
||||
children?: ReactNode;
|
||||
}) {
|
||||
const queryResult = useWebsites({ userId, teamId });
|
||||
|
||||
return (
|
||||
<DataTable queryResult={queryResult}>
|
||||
{({ data }) => (
|
||||
<WebsitesTable
|
||||
teamId={teamId}
|
||||
data={data}
|
||||
showActions={showActions}
|
||||
allowEdit={allowEdit}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue