mirror of
https://github.com/umami-software/umami.git
synced 2026-02-23 22:15:35 +01:00
Refactored teams components.
This commit is contained in:
parent
0e144269ee
commit
be5592446a
25 changed files with 122 additions and 81 deletions
|
|
@ -0,0 +1,22 @@
|
|||
'use client';
|
||||
import DataTable from 'components/common/DataTable';
|
||||
import TeamMembersTable from './TeamMembersTable';
|
||||
import { useTeamMembers } from 'components/hooks';
|
||||
|
||||
export function TeamMembersDataTable({
|
||||
teamId,
|
||||
allowEdit = false,
|
||||
}: {
|
||||
teamId: string;
|
||||
allowEdit?: boolean;
|
||||
}) {
|
||||
const queryResult = useTeamMembers(teamId);
|
||||
|
||||
return (
|
||||
<DataTable queryResult={queryResult}>
|
||||
{({ data }) => <TeamMembersTable data={data} teamId={teamId} allowEdit={allowEdit} />}
|
||||
</DataTable>
|
||||
);
|
||||
}
|
||||
|
||||
export default TeamMembersDataTable;
|
||||
Loading…
Add table
Add a link
Reference in a new issue