diff --git a/src/components/overlays/AddAppUserRoles/index.tsx b/src/components/overlays/AddAppUserRoles/index.tsx index c56777b9d0..5d0a77a4a8 100644 --- a/src/components/overlays/AddAppUserRoles/index.tsx +++ b/src/components/overlays/AddAppUserRoles/index.tsx @@ -49,7 +49,11 @@ import { import { Box } from '@mui/material' import { useState } from 'react' -export default function AddAppUserRoles() { +export default function AddAppUserRoles({ + subscriptionId, +}: { + subscriptionId: string +}) { const { t } = useTranslation() const dispatch = useDispatch() const { appId } = useParams() @@ -66,6 +70,7 @@ export default function AddAppUserRoles() { const data: UserRoleRequest = { appId, companyUserId: user, + subscriptionId, body: roles, } dispatch(setRolesToAdd([])) diff --git a/src/components/overlays/CompanyCertificateDetails/index.tsx b/src/components/overlays/CompanyCertificateDetails/index.tsx index 7391f37df1..9ca34d9ab7 100644 --- a/src/components/overlays/CompanyCertificateDetails/index.tsx +++ b/src/components/overlays/CompanyCertificateDetails/index.tsx @@ -220,6 +220,7 @@ export default function CompanyCertificateDetails({ show( OVERLAYS.COMPANY_CERTIFICATE_CONFIRM_DELETE, id, + '', selected.companyCertificateType ) ) diff --git a/src/components/pages/AppOverview/index.tsx b/src/components/pages/AppOverview/index.tsx index d23131d031..bd9672d31a 100644 --- a/src/components/pages/AppOverview/index.tsx +++ b/src/components/pages/AppOverview/index.tsx @@ -237,9 +237,9 @@ export default function AppOverview() { const showOverlay = (item: AppInfo) => { if (item.status === 'created') { - dispatch(show(OVERLAYS.APP_OVERVIEW_CONFIRM, item.id, item.name)) + dispatch(show(OVERLAYS.APP_OVERVIEW_CONFIRM, item.id, '', item.name)) } else if (item.status === 'in_review') { - dispatch(show(OVERLAYS.APP_DETAILS_OVERLAY, item.id, item.name)) + dispatch(show(OVERLAYS.APP_DETAILS_OVERLAY, item.id, '', item.name)) } } diff --git a/src/components/pages/AppUserManagement/AppUserDetailsTable/index.tsx b/src/components/pages/AppUserManagement/AppUserDetailsTable/index.tsx index 50cf75f151..914abfd03c 100644 --- a/src/components/pages/AppUserManagement/AppUserDetailsTable/index.tsx +++ b/src/components/pages/AppUserManagement/AppUserDetailsTable/index.tsx @@ -50,7 +50,9 @@ export const AppUserDetailsTable = ({ dispatch(show(OVERLAYS.ADD_APP_USER_ROLES, appId))} + addButtonClick={() => + dispatch(show(OVERLAYS.ADD_APP_USER_ROLES, appId, subscriptionId)) + } addButtonDisabled={ !roles || roles.length === 0 || diff --git a/src/components/pages/MyAccount/index.tsx b/src/components/pages/MyAccount/index.tsx index b2f2031e3a..63eae4ff56 100644 --- a/src/components/pages/MyAccount/index.tsx +++ b/src/components/pages/MyAccount/index.tsx @@ -46,7 +46,9 @@ export default function MyAccount() { const dispatch = useDispatch() const handleDeleteUser = () => - dispatch(show(OVERLAYS.CONFIRM_USER_ACTION, data?.companyUserId, 'ownUser')) + dispatch( + show(OVERLAYS.CONFIRM_USER_ACTION, data?.companyUserId, '', 'ownUser') + ) return (
diff --git a/src/components/pages/UserDetail/index.tsx b/src/components/pages/UserDetail/index.tsx index c75e811c36..d79eab2f2c 100644 --- a/src/components/pages/UserDetail/index.tsx +++ b/src/components/pages/UserDetail/index.tsx @@ -44,10 +44,10 @@ export default function UserDetail() { const { data } = useFetchUserDetailsQuery(userId ?? '') const handleSuspendUser = () => - dispatch(show(OVERLAYS.CONFIRM_USER_ACTION, userId, 'suspend')) + dispatch(show(OVERLAYS.CONFIRM_USER_ACTION, userId, '', 'suspend')) const handleDeleteUser = () => - dispatch(show(OVERLAYS.CONFIRM_USER_ACTION, userId, 'user')) + dispatch(show(OVERLAYS.CONFIRM_USER_ACTION, userId, '', 'user')) const handleResetPasswordForUser = () => data && diff --git a/src/services/AccessService.tsx b/src/services/AccessService.tsx index 9aacc13baa..d05b086e28 100644 --- a/src/services/AccessService.tsx +++ b/src/services/AccessService.tsx @@ -179,7 +179,7 @@ export const getOverlay = (overlay: OverlayState) => { case OVERLAYS.DELETE_TECH_USER: return case OVERLAYS.ADD_APP_USER_ROLES: - return + return case OVERLAYS.EDIT_APP_USER_ROLES: return (