Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import {
import type { ServiceUser } from '@raystack/proton/frontier';
import type { Timestamp } from '@bufbuild/protobuf/wkt';
import { timestampToDayjs } from '~/utils/timestamp';
import { ProjectsCell } from './projects-cell';
import styles from './service-account-columns.module.css';

export interface ServiceAccountMenuPayload {
Expand All @@ -26,14 +25,12 @@ interface GetColumnsOptions {
dateFormat: string;
menuHandle: MenuHandle;
canUpdateWorkspace: boolean;
orgId: string;
}

export const getColumns = ({
dateFormat,
menuHandle,
canUpdateWorkspace,
orgId
canUpdateWorkspace
}: GetColumnsOptions): DataTableColumnDef<ServiceUser, unknown>[] => [
{
header: 'Name',
Expand All @@ -43,20 +40,6 @@ export const getColumns = ({
return <Text size="regular">{value}</Text>;
}
},
{
header: 'Projects',
id: 'projects',
accessorKey: 'id',
enableSorting: false,
styles: {
cell: { maxWidth: '600px' },
header: { maxWidth: '600px' }
},
cell: ({ getValue }) => {
const serviceUserId = getValue() as string;
return <ProjectsCell serviceUserId={serviceUserId} orgId={orgId} />;
}
},
{
header: 'Created On',
accessorKey: 'createdAt',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,9 @@ export function ServiceAccountsView({
getColumns({
dateFormat,
menuHandle: serviceAccountMenuHandle,
canUpdateWorkspace,
orgId
canUpdateWorkspace
}),
[dateFormat, canUpdateWorkspace, orgId]
[dateFormat, canUpdateWorkspace]
);

const handleCreated = (serviceUserId: string) => {
Expand Down
Loading