Fix error when enable SCIM

Signed-off-by: Bryan Frimin <bryan@getprobo.com>
This commit is contained in:
Bryan Frimin
2026-01-05 21:11:58 +01:00
parent 64610b388a
commit c591759cbb
5 changed files with 162 additions and 208 deletions

View File

@@ -1,5 +1,5 @@
/**
* @generated SignedSource<<5a8bd03c48696bd6ed7bd5ec80a61045>>
* @generated SignedSource<<481d9c3c647c11a95d68ff7e4a489a24>>
* @lightSyntaxTransform
* @nogrep
*/
@@ -18,13 +18,13 @@ export type SCIMConfigurationCreateMutation$variables = {
export type SCIMConfigurationCreateMutation$data = {
readonly createSCIMConfiguration: {
readonly scimConfiguration: {
readonly endpointUrl: string;
readonly id: string;
readonly organization: {
readonly id: string;
readonly scimConfiguration: {
readonly createdAt: string;
readonly endpointUrl: string;
readonly id: string;
readonly updatedAt: string;
} | null | undefined;
} | null | undefined;
};
@@ -44,104 +44,91 @@ var v0 = [
"name": "input"
}
],
v1 = [
{
"kind": "Variable",
"name": "input",
"variableName": "input"
}
],
v2 = {
v1 = {
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "id",
"storageKey": null
},
v3 = {
"alias": null,
"args": null,
"concreteType": "Organization",
"kind": "LinkedField",
"name": "organization",
"plural": false,
"selections": [
(v2/*: any*/),
{
"alias": null,
"args": null,
"concreteType": "SCIMConfiguration",
"kind": "LinkedField",
"name": "scimConfiguration",
"plural": false,
"selections": [
(v2/*: any*/),
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "endpointUrl",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "createdAt",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "updatedAt",
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
},
v4 = {
v2 = {
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "token",
"name": "endpointUrl",
"storageKey": null
};
},
v3 = [
{
"alias": null,
"args": [
{
"kind": "Variable",
"name": "input",
"variableName": "input"
}
],
"concreteType": "CreateSCIMConfigurationPayload",
"kind": "LinkedField",
"name": "createSCIMConfiguration",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "SCIMConfiguration",
"kind": "LinkedField",
"name": "scimConfiguration",
"plural": false,
"selections": [
(v1/*: any*/),
(v2/*: any*/),
{
"alias": null,
"args": null,
"concreteType": "Organization",
"kind": "LinkedField",
"name": "organization",
"plural": false,
"selections": [
(v1/*: any*/),
{
"alias": null,
"args": null,
"concreteType": "SCIMConfiguration",
"kind": "LinkedField",
"name": "scimConfiguration",
"plural": false,
"selections": [
(v1/*: any*/),
(v2/*: any*/)
],
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "token",
"storageKey": null
}
],
"storageKey": null
}
];
return {
"fragment": {
"argumentDefinitions": (v0/*: any*/),
"kind": "Fragment",
"metadata": null,
"name": "SCIMConfigurationCreateMutation",
"selections": [
{
"alias": null,
"args": (v1/*: any*/),
"concreteType": "CreateSCIMConfigurationPayload",
"kind": "LinkedField",
"name": "createSCIMConfiguration",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "SCIMConfiguration",
"kind": "LinkedField",
"name": "scimConfiguration",
"plural": false,
"selections": [
(v3/*: any*/)
],
"storageKey": null
},
(v4/*: any*/)
],
"storageKey": null
}
],
"selections": (v3/*: any*/),
"type": "Mutation",
"abstractKey": null
},
@@ -150,45 +137,19 @@ return {
"argumentDefinitions": (v0/*: any*/),
"kind": "Operation",
"name": "SCIMConfigurationCreateMutation",
"selections": [
{
"alias": null,
"args": (v1/*: any*/),
"concreteType": "CreateSCIMConfigurationPayload",
"kind": "LinkedField",
"name": "createSCIMConfiguration",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "SCIMConfiguration",
"kind": "LinkedField",
"name": "scimConfiguration",
"plural": false,
"selections": [
(v3/*: any*/),
(v2/*: any*/)
],
"storageKey": null
},
(v4/*: any*/)
],
"storageKey": null
}
]
"selections": (v3/*: any*/)
},
"params": {
"cacheID": "24fe7551556768ace60e5c1ee357deda",
"cacheID": "c4a8c2c34586e55c6dca0b5e4a0f4642",
"id": null,
"metadata": {},
"name": "SCIMConfigurationCreateMutation",
"operationKind": "mutation",
"text": "mutation SCIMConfigurationCreateMutation(\n $input: CreateSCIMConfigurationInput!\n) {\n createSCIMConfiguration(input: $input) {\n scimConfiguration {\n organization {\n id\n scimConfiguration {\n id\n endpointUrl\n createdAt\n updatedAt\n }\n }\n id\n }\n token\n }\n}\n"
"text": "mutation SCIMConfigurationCreateMutation(\n $input: CreateSCIMConfigurationInput!\n) {\n createSCIMConfiguration(input: $input) {\n scimConfiguration {\n id\n endpointUrl\n organization {\n id\n scimConfiguration {\n id\n endpointUrl\n }\n }\n }\n token\n }\n}\n"
}
};
})();
(node as any).hash = "3b23015e5a2e1b117317cbfad4e4a64b";
(node as any).hash = "b4534941bf2670d13c78cb5ab9e810b1";
export default node;

View File

@@ -1,5 +1,5 @@
/**
* @generated SignedSource<<24043718fd171f0c9f80df965cbf10eb>>
* @generated SignedSource<<aee411254b8e44cfe7387cf500fe4148>>
* @lightSyntaxTransform
* @nogrep
*/
@@ -18,7 +18,7 @@ export type SCIMEventListFragment$data = {
readonly " $fragmentSpreads": FragmentRefs<"SCIMEventListItemFragment">;
};
}>;
};
} | null | undefined;
readonly id: string;
readonly " $fragmentType": "SCIMEventListFragment";
};
@@ -98,104 +98,96 @@ return {
"name": "SCIMEventListFragment",
"selections": [
{
"kind": "RequiredField",
"field": {
"alias": "events",
"args": null,
"concreteType": "SCIMEventConnection",
"kind": "LinkedField",
"name": "__SCIMEventListFragment_events_connection",
"plural": false,
"selections": [
{
"kind": "RequiredField",
"field": {
"alias": "events",
"args": null,
"concreteType": "SCIMEventConnection",
"kind": "LinkedField",
"name": "__SCIMEventListFragment_events_connection",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "SCIMEventEdge",
"kind": "LinkedField",
"name": "edges",
"plural": true,
"selections": [
{
"alias": null,
"args": null,
"concreteType": "SCIMEventEdge",
"concreteType": "SCIMEvent",
"kind": "LinkedField",
"name": "edges",
"plural": true,
"name": "node",
"plural": false,
"selections": [
(v1/*: any*/),
{
"alias": null,
"args": null,
"concreteType": "SCIMEvent",
"kind": "LinkedField",
"name": "node",
"plural": false,
"selections": [
(v1/*: any*/),
{
"args": null,
"kind": "FragmentSpread",
"name": "SCIMEventListItemFragment"
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "__typename",
"storageKey": null
}
],
"storageKey": null
"kind": "FragmentSpread",
"name": "SCIMEventListItemFragment"
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "cursor",
"name": "__typename",
"storageKey": null
}
],
"storageKey": null
},
"action": "THROW"
},
{
"alias": null,
"args": null,
"concreteType": "PageInfo",
"kind": "LinkedField",
"name": "pageInfo",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "endCursor",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "hasNextPage",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "hasPreviousPage",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "startCursor",
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
},
"action": "THROW"
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "cursor",
"storageKey": null
}
],
"storageKey": null
},
{
"alias": null,
"args": null,
"concreteType": "PageInfo",
"kind": "LinkedField",
"name": "pageInfo",
"plural": false,
"selections": [
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "endCursor",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "hasNextPage",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "hasPreviousPage",
"storageKey": null
},
{
"alias": null,
"args": null,
"kind": "ScalarField",
"name": "startCursor",
"storageKey": null
}
],
"storageKey": null
}
],
"storageKey": null
},
(v1/*: any*/)
],
@@ -204,6 +196,6 @@ return {
};
})();
(node as any).hash = "64df3764ea01f7a7153983fabb6202ad";
(node as any).hash = "ae2f90b93285c48be6ae1c3f458f3a6e";
export default node;

View File

@@ -1,5 +1,5 @@
/**
* @generated SignedSource<<0f5b99c931df8d47706342b7715260ef>>
* @generated SignedSource<<b32ec8d0912fecc61b56c7b4473e8938>>
* @lightSyntaxTransform
* @nogrep
*/
@@ -337,6 +337,6 @@ return {
};
})();
(node as any).hash = "64df3764ea01f7a7153983fabb6202ad";
(node as any).hash = "ae2f90b93285c48be6ae1c3f458f3a6e";
export default node;

View File

@@ -29,13 +29,14 @@ const createSCIMConfigurationMutation = graphql`
) {
createSCIMConfiguration(input: $input) {
scimConfiguration {
id
endpointUrl
organization {
id
scimConfiguration {
id
endpointUrl
createdAt
updatedAt
}
}
}

View File

@@ -16,9 +16,8 @@ const SCIMEventListFragment = graphql`
last: { type: "Int", defaultValue: null }
) {
events(first: $first, after: $after, last: $last, before: $before)
@connection(key: "SCIMEventListFragment_events")
@required(action: THROW) {
edges @required(action: THROW) {
@connection(key: "SCIMEventListFragment_events") {
edges {
node {
id
...SCIMEventListItemFragment
@@ -54,7 +53,8 @@ export function SCIMEventList(props: { fKey: SCIMEventListFragment$key }) {
</Tr>
</Thead>
<Tbody>
{eventsPagination.data.events.edges.length === 0 ? (
{!eventsPagination.data.events?.edges ||
eventsPagination.data.events.edges.length === 0 ? (
<Tr>
<Td colSpan={4} className="text-center text-txt-secondary">
{__("No SCIM events recorded yet.")}