File tree 5 files changed +12
-8
lines changed
5 files changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,11 @@ export function fetchPermissions(
76
76
77
77
const url = `/permissions?${ queryParam } &select=${ selectFields . join ( "," ) } &limit=${ pageSize } &offset=${ pageIndex * pageSize } ` ;
78
78
return resolvePostGrestRequestWithPagination (
79
- IncidentCommander . get < PermissionAPIResponse [ ] > ( url )
79
+ IncidentCommander . get < PermissionAPIResponse [ ] > ( url , {
80
+ headers : {
81
+ Prefer : "count=exact"
82
+ }
83
+ } )
80
84
) ;
81
85
}
82
86
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ export default function DeletePermission({
53
53
{ isConfirmDialogOpen && (
54
54
< ConfirmationPromptDialog
55
55
title = "Delete Permission"
56
- description = "Are you sure you want to permission?"
56
+ description = "Are you sure you want to delete the permission?"
57
57
onConfirm = { onDeleteResource }
58
58
isOpen = { isConfirmDialogOpen }
59
59
onClose = { ( ) => setIsConfirmDialogOpen ( false ) }
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ export default function FormikPermissionSelectResourceFields() {
29
29
const { setFieldValue } = useFormikContext < Record < string , any > > ( ) ;
30
30
31
31
const [ switchOption , setSwitchOption ] = useState <
32
- "Component" | "Catalog" | "Canary" | "Playbook" | "Connection" | "Object "
32
+ "Component" | "Catalog" | "Canary" | "Playbook" | "Connection" | "Global "
33
33
> ( "Catalog" ) ;
34
34
35
35
return (
@@ -43,7 +43,7 @@ export default function FormikPermissionSelectResourceFields() {
43
43
"Component" ,
44
44
"Connection" ,
45
45
"Playbook" ,
46
- "Object "
46
+ "Global "
47
47
] }
48
48
className = "w-auto"
49
49
itemsClassName = ""
@@ -89,7 +89,7 @@ export default function FormikPermissionSelectResourceFields() {
89
89
< FormikConnectionField required name = "connection_id" />
90
90
) }
91
91
92
- { switchOption === "Object " && (
92
+ { switchOption === "Global " && (
93
93
< FormikSelectDropdown
94
94
required
95
95
name = "object"
Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ export default function PermissionForm({
101
101
onClose = { onClose }
102
102
open = { isOpen }
103
103
bodyClass = "flex flex-col w-full flex-1 h-full overflow-y-auto"
104
- helpLink = "/installation/saas/agent "
104
+ helpLink = "/reference/permissions "
105
105
>
106
106
< div className = "flex flex-1 flex-col gap-2" >
107
107
< Formik < Partial < PermissionTable > >
@@ -153,7 +153,7 @@ export default function PermissionForm({
153
153
name = "action"
154
154
label = "Action"
155
155
/>
156
- < FormikCheckbox name = "deny" label = "Is deny action " />
156
+ < FormikCheckbox name = "deny" label = "Deny " />
157
157
< FormikTextArea name = "description" label = "Description" />
158
158
</ div >
159
159
< CanEditResource
Original file line number Diff line number Diff line change @@ -67,7 +67,7 @@ export default function PermissionsView({
67
67
} , [ isLoading , setIsLoading ] ) ;
68
68
69
69
const totalEntries = data ?. totalEntries || 0 ;
70
- const pageCount = totalEntries ? Math . ceil ( totalEntries / pageSize ) : - 1 ;
70
+ const pageCount = totalEntries ? Math . ceil ( totalEntries / pageSize ) : 1 ;
71
71
const permissions = data ?. data || [ ] ;
72
72
73
73
return (
You can’t perform that action at this time.
0 commit comments