mirror of
https://github.com/umami-software/umami.git
synced 2026-02-17 02:55:38 +01:00
Allow getting team websites.
This commit is contained in:
parent
e610de383a
commit
433ce98719
10 changed files with 79 additions and 56 deletions
|
|
@ -3,6 +3,7 @@ import { Row, Text, Icon, DataTable, DataColumn, MenuItem } from '@umami/react-z
|
|||
import { useMessages, useNavigation } from '@/components/hooks';
|
||||
import { MenuButton } from '@/components/input/MenuButton';
|
||||
import { Eye, SquarePen } from '@/components/icons';
|
||||
import { Empty } from '@/components/common/Empty';
|
||||
|
||||
export function WebsitesTable({
|
||||
data = [],
|
||||
|
|
@ -10,20 +11,18 @@ export function WebsitesTable({
|
|||
allowEdit,
|
||||
allowView,
|
||||
renderLink,
|
||||
children,
|
||||
}: {
|
||||
data: Record<string, any>[];
|
||||
showActions?: boolean;
|
||||
allowEdit?: boolean;
|
||||
allowView?: boolean;
|
||||
renderLink?: (row: any) => ReactNode;
|
||||
children?: ReactNode;
|
||||
}) {
|
||||
const { formatMessage, labels } = useMessages();
|
||||
const { renderUrl } = useNavigation();
|
||||
|
||||
if (!data?.length) {
|
||||
return children;
|
||||
if (data.length === 0) {
|
||||
return <Empty />;
|
||||
}
|
||||
|
||||
return (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue