Skip to content

Commit

Permalink
feat(OY2-26203): Add OS Action Column
Browse files Browse the repository at this point in the history
  • Loading branch information
pkim-gswell committed Dec 13, 2023
1 parent 506957f commit ed156d5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/services/ui/src/pages/dashboard/Lists/spas/consts.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { format } from "date-fns";
import { removeUnderscoresAndCapitalize } from "@/utils";
import { OsTableColumn } from "@/components/Opensearch/Table/types";
import { UserRoles } from "shared-types";
import { CMS_READ_ONLY_ROLES, UserRoles } from "shared-types";
import { useGetUser } from "@/api/useGetUser";
import {
renderCellActions,
Expand Down Expand Up @@ -84,7 +84,7 @@ export const useSpaTableColumns = (): OsTableColumn[] => {
cell: (data) => data.submitterName,
},
// hide actions column for: readonly,help desk
...(![UserRoles.HELPDESK, UserRoles.CMS_READ_ONLY].some((UR) =>
...(!CMS_READ_ONLY_ROLES.some((UR) =>
props.user?.["custom:cms-roles"].includes(UR)
)
? [
Expand Down
4 changes: 2 additions & 2 deletions src/services/ui/src/pages/dashboard/Lists/waivers/consts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { removeUnderscoresAndCapitalize } from "@/utils";
import { OsTableColumn } from "@/components/Opensearch/Table/types";
import { LABELS } from "@/lib";
import { BLANK_VALUE } from "@/consts";
import { UserRoles } from "shared-types";
import { CMS_READ_ONLY_ROLES, UserRoles } from "shared-types";
import { useGetUser } from "@/api/useGetUser";
import {
renderCellActions,
Expand Down Expand Up @@ -90,7 +90,7 @@ export const useWaiverTableColumns = (): OsTableColumn[] => {
cell: (data) => data.submitterName,
},
// hide actions column for: readonly,help desk
...(![UserRoles.HELPDESK, UserRoles.CMS_READ_ONLY].some((UR) =>
...(!CMS_READ_ONLY_ROLES.some((UR) =>
props.user?.["custom:cms-roles"].includes(UR)
)
? [
Expand Down

0 comments on commit ed156d5

Please sign in to comment.