@constructive-io/react 1.9.2 → 1.9.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/admin/hooks/index.d.ts +1 -1
- package/admin/hooks/index.js +1 -1
- package/admin/hooks/invalidation.d.ts +24 -0
- package/admin/hooks/invalidation.js +64 -0
- package/admin/hooks/mutation-keys.d.ts +48 -0
- package/admin/hooks/mutation-keys.js +32 -1
- package/admin/hooks/mutations/index.d.ts +8 -0
- package/admin/hooks/mutations/index.js +8 -0
- package/admin/hooks/mutations/useCreateOrgChartEdgeGrantMutation.d.ts +34 -0
- package/{api/hooks/mutations/useCreatePlatformApiModuleMutation.js → admin/hooks/mutations/useCreateOrgChartEdgeGrantMutation.js} +6 -6
- package/admin/hooks/mutations/useCreateOrgChartEdgeMutation.d.ts +34 -0
- package/admin/hooks/mutations/useCreateOrgChartEdgeMutation.js +34 -0
- package/admin/hooks/mutations/useCreateOrgGetManagersRecordMutation.d.ts +34 -0
- package/admin/hooks/mutations/useCreateOrgGetManagersRecordMutation.js +34 -0
- package/admin/hooks/mutations/useCreateOrgGetSubordinatesRecordMutation.d.ts +34 -0
- package/admin/hooks/mutations/useCreateOrgGetSubordinatesRecordMutation.js +34 -0
- package/admin/hooks/mutations/useDeleteOrgChartEdgeGrantMutation.d.ts +38 -0
- package/{api/hooks/mutations/useDeletePlatformApiModuleMutation.js → admin/hooks/mutations/useDeleteOrgChartEdgeGrantMutation.js} +7 -7
- package/admin/hooks/mutations/useDeleteOrgChartEdgeMutation.d.ts +38 -0
- package/admin/hooks/mutations/useDeleteOrgChartEdgeMutation.js +39 -0
- package/admin/hooks/mutations/useUpdateOrgChartEdgeGrantMutation.d.ts +40 -0
- package/{api/hooks/mutations/useUpdatePlatformApiModuleMutation.js → admin/hooks/mutations/useUpdateOrgChartEdgeGrantMutation.js} +9 -9
- package/admin/hooks/mutations/useUpdateOrgChartEdgeMutation.d.ts +40 -0
- package/admin/hooks/mutations/useUpdateOrgChartEdgeMutation.js +40 -0
- package/admin/hooks/queries/index.d.ts +7 -0
- package/admin/hooks/queries/index.js +7 -0
- package/admin/hooks/queries/useOrgChartEdgeGrantQuery.d.ts +65 -0
- package/{api/hooks/queries/usePlatformApiModuleQuery.js → admin/hooks/queries/useOrgChartEdgeGrantQuery.js} +14 -14
- package/admin/hooks/queries/useOrgChartEdgeGrantsQuery.d.ts +69 -0
- package/admin/hooks/queries/useOrgChartEdgeGrantsQuery.js +38 -0
- package/admin/hooks/queries/useOrgChartEdgeQuery.d.ts +65 -0
- package/admin/hooks/queries/useOrgChartEdgeQuery.js +53 -0
- package/admin/hooks/queries/useOrgChartEdgesQuery.d.ts +69 -0
- package/admin/hooks/queries/useOrgChartEdgesQuery.js +38 -0
- package/admin/hooks/queries/useOrgGetManagersQuery.d.ts +69 -0
- package/admin/hooks/queries/useOrgGetManagersQuery.js +38 -0
- package/admin/hooks/queries/useOrgGetSubordinatesQuery.d.ts +69 -0
- package/admin/hooks/queries/useOrgGetSubordinatesQuery.js +38 -0
- package/admin/hooks/queries/useOrgIsManagerOfQuery.d.ts +53 -0
- package/admin/hooks/queries/useOrgIsManagerOfQuery.js +53 -0
- package/admin/hooks/query-keys.d.ts +58 -0
- package/admin/hooks/query-keys.js +34 -1
- package/admin/orm/index.d.ts +13 -0
- package/admin/orm/index.js +8 -0
- package/admin/orm/input-types.d.ts +399 -0
- package/admin/orm/models/index.d.ts +4 -0
- package/admin/orm/models/index.js +9 -1
- package/admin/orm/models/orgChartEdge.d.ts +54 -0
- package/admin/orm/models/orgChartEdge.js +104 -0
- package/admin/orm/models/orgChartEdgeGrant.d.ts +54 -0
- package/{api/orm/models/platformApiModule.js → admin/orm/models/orgChartEdgeGrant.js} +27 -27
- package/admin/orm/models/orgGetManagersRecord.d.ts +30 -0
- package/admin/orm/models/orgGetManagersRecord.js +59 -0
- package/admin/orm/models/orgGetSubordinatesRecord.d.ts +30 -0
- package/admin/orm/models/orgGetSubordinatesRecord.js +59 -0
- package/admin/orm/query/index.d.ts +11 -0
- package/admin/orm/query/index.js +24 -0
- package/admin/schema-types.d.ts +247 -1
- package/admin/types.d.ts +29 -0
- package/api/hooks/index.d.ts +1 -1
- package/api/hooks/index.js +1 -1
- package/api/hooks/invalidation.d.ts +6 -12
- package/api/hooks/invalidation.js +16 -32
- package/api/hooks/mutation-keys.d.ts +12 -24
- package/api/hooks/mutation-keys.js +9 -16
- package/api/hooks/mutations/index.d.ts +3 -6
- package/api/hooks/mutations/index.js +3 -6
- package/api/hooks/mutations/useCreateDomainTypeMutation.d.ts +34 -0
- package/api/hooks/mutations/{useCreateApiModuleMutation.js → useCreateDomainTypeMutation.js} +6 -6
- package/api/hooks/mutations/useDeleteDomainTypeMutation.d.ts +38 -0
- package/api/hooks/mutations/{useDeleteApiModuleMutation.js → useDeleteDomainTypeMutation.js} +7 -7
- package/api/hooks/mutations/useUpdateDomainTypeMutation.d.ts +40 -0
- package/api/hooks/mutations/{useUpdateApiModuleMutation.js → useUpdateDomainTypeMutation.js} +9 -9
- package/api/hooks/queries/index.d.ts +2 -4
- package/api/hooks/queries/index.js +2 -4
- package/api/hooks/queries/useDomainTypeQuery.d.ts +65 -0
- package/api/hooks/queries/{useApiModuleQuery.js → useDomainTypeQuery.js} +14 -14
- package/api/hooks/queries/useDomainTypesQuery.d.ts +69 -0
- package/api/hooks/queries/{useApiModulesQuery.js → useDomainTypesQuery.js} +14 -14
- package/api/hooks/query-keys.d.ts +14 -28
- package/api/hooks/query-keys.js +10 -18
- package/api/orm/index.d.ts +2 -4
- package/api/orm/index.js +2 -4
- package/api/orm/input-types.d.ts +378 -468
- package/api/orm/input-types.js +2 -2
- package/api/orm/models/domainType.d.ts +54 -0
- package/api/orm/models/{apiModule.js → domainType.js} +27 -27
- package/api/orm/models/index.d.ts +1 -2
- package/api/orm/models/index.js +4 -6
- package/api/schema-types.d.ts +157 -226
- package/api/types.d.ts +16 -17
- package/compute/orm/input-types.d.ts +42 -3
- package/compute/schema-types.d.ts +25 -3
- package/compute/types.d.ts +5 -0
- package/esm/admin/hooks/index.d.ts +1 -1
- package/esm/admin/hooks/index.js +1 -1
- package/esm/admin/hooks/invalidation.d.ts +24 -0
- package/esm/admin/hooks/invalidation.js +65 -1
- package/esm/admin/hooks/mutation-keys.d.ts +48 -0
- package/esm/admin/hooks/mutation-keys.js +31 -0
- package/esm/admin/hooks/mutations/index.d.ts +8 -0
- package/esm/admin/hooks/mutations/index.js +8 -0
- package/esm/admin/hooks/mutations/useCreateOrgChartEdgeGrantMutation.d.ts +34 -0
- package/esm/admin/hooks/mutations/useCreateOrgChartEdgeGrantMutation.js +31 -0
- package/esm/admin/hooks/mutations/useCreateOrgChartEdgeMutation.d.ts +34 -0
- package/esm/{api/hooks/mutations/useCreatePlatformApiModuleMutation.js → admin/hooks/mutations/useCreateOrgChartEdgeMutation.js} +7 -7
- package/esm/admin/hooks/mutations/useCreateOrgGetManagersRecordMutation.d.ts +34 -0
- package/esm/admin/hooks/mutations/useCreateOrgGetManagersRecordMutation.js +31 -0
- package/esm/admin/hooks/mutations/useCreateOrgGetSubordinatesRecordMutation.d.ts +34 -0
- package/esm/admin/hooks/mutations/useCreateOrgGetSubordinatesRecordMutation.js +31 -0
- package/esm/admin/hooks/mutations/useDeleteOrgChartEdgeGrantMutation.d.ts +38 -0
- package/esm/{api/hooks/mutations/useDeletePlatformApiModuleMutation.js → admin/hooks/mutations/useDeleteOrgChartEdgeGrantMutation.js} +8 -8
- package/esm/admin/hooks/mutations/useDeleteOrgChartEdgeMutation.d.ts +38 -0
- package/esm/admin/hooks/mutations/useDeleteOrgChartEdgeMutation.js +36 -0
- package/esm/admin/hooks/mutations/useUpdateOrgChartEdgeGrantMutation.d.ts +40 -0
- package/esm/{api/hooks/mutations/useUpdatePlatformApiModuleMutation.js → admin/hooks/mutations/useUpdateOrgChartEdgeGrantMutation.js} +10 -10
- package/esm/admin/hooks/mutations/useUpdateOrgChartEdgeMutation.d.ts +40 -0
- package/esm/admin/hooks/mutations/useUpdateOrgChartEdgeMutation.js +37 -0
- package/esm/admin/hooks/queries/index.d.ts +7 -0
- package/esm/admin/hooks/queries/index.js +7 -0
- package/esm/admin/hooks/queries/useOrgChartEdgeGrantQuery.d.ts +65 -0
- package/esm/{api/hooks/queries/usePlatformApiModuleQuery.js → admin/hooks/queries/useOrgChartEdgeGrantQuery.js} +11 -11
- package/esm/admin/hooks/queries/useOrgChartEdgeGrantsQuery.d.ts +69 -0
- package/esm/{api/hooks/queries/usePlatformApiModulesQuery.js → admin/hooks/queries/useOrgChartEdgeGrantsQuery.js} +11 -11
- package/esm/admin/hooks/queries/useOrgChartEdgeQuery.d.ts +65 -0
- package/esm/admin/hooks/queries/useOrgChartEdgeQuery.js +47 -0
- package/esm/admin/hooks/queries/useOrgChartEdgesQuery.d.ts +69 -0
- package/esm/admin/hooks/queries/useOrgChartEdgesQuery.js +32 -0
- package/esm/admin/hooks/queries/useOrgGetManagersQuery.d.ts +69 -0
- package/esm/admin/hooks/queries/useOrgGetManagersQuery.js +32 -0
- package/esm/admin/hooks/queries/useOrgGetSubordinatesQuery.d.ts +69 -0
- package/esm/admin/hooks/queries/useOrgGetSubordinatesQuery.js +32 -0
- package/esm/admin/hooks/queries/useOrgIsManagerOfQuery.d.ts +53 -0
- package/esm/admin/hooks/queries/useOrgIsManagerOfQuery.js +47 -0
- package/esm/admin/hooks/query-keys.d.ts +58 -0
- package/esm/admin/hooks/query-keys.js +33 -0
- package/esm/admin/orm/index.d.ts +13 -0
- package/esm/admin/orm/index.js +8 -0
- package/esm/admin/orm/input-types.d.ts +399 -0
- package/esm/admin/orm/models/index.d.ts +4 -0
- package/esm/admin/orm/models/index.js +4 -0
- package/esm/admin/orm/models/orgChartEdge.d.ts +54 -0
- package/esm/admin/orm/models/orgChartEdge.js +100 -0
- package/esm/admin/orm/models/orgChartEdgeGrant.d.ts +54 -0
- package/esm/{api/orm/models/platformApiModule.js → admin/orm/models/orgChartEdgeGrant.js} +25 -25
- package/esm/admin/orm/models/orgGetManagersRecord.d.ts +30 -0
- package/esm/admin/orm/models/orgGetManagersRecord.js +55 -0
- package/esm/admin/orm/models/orgGetSubordinatesRecord.d.ts +30 -0
- package/esm/admin/orm/models/orgGetSubordinatesRecord.js +55 -0
- package/esm/admin/orm/query/index.d.ts +11 -0
- package/esm/admin/orm/query/index.js +24 -0
- package/esm/admin/schema-types.d.ts +247 -1
- package/esm/admin/types.d.ts +29 -0
- package/esm/api/hooks/index.d.ts +1 -1
- package/esm/api/hooks/index.js +1 -1
- package/esm/api/hooks/invalidation.d.ts +6 -12
- package/esm/api/hooks/invalidation.js +17 -33
- package/esm/api/hooks/mutation-keys.d.ts +12 -24
- package/esm/api/hooks/mutation-keys.js +7 -14
- package/esm/api/hooks/mutations/index.d.ts +3 -6
- package/esm/api/hooks/mutations/index.js +3 -6
- package/esm/api/hooks/mutations/useCreateDomainTypeMutation.d.ts +34 -0
- package/esm/api/hooks/mutations/{useCreateApiModuleMutation.js → useCreateDomainTypeMutation.js} +7 -7
- package/esm/api/hooks/mutations/useDeleteDomainTypeMutation.d.ts +38 -0
- package/esm/api/hooks/mutations/{useDeleteApiModuleMutation.js → useDeleteDomainTypeMutation.js} +8 -8
- package/esm/api/hooks/mutations/useUpdateDomainTypeMutation.d.ts +40 -0
- package/esm/api/hooks/mutations/{useUpdateApiModuleMutation.js → useUpdateDomainTypeMutation.js} +10 -10
- package/esm/api/hooks/queries/index.d.ts +2 -4
- package/esm/api/hooks/queries/index.js +2 -4
- package/esm/api/hooks/queries/useDomainTypeQuery.d.ts +65 -0
- package/esm/api/hooks/queries/{useApiModuleQuery.js → useDomainTypeQuery.js} +11 -11
- package/esm/api/hooks/queries/useDomainTypesQuery.d.ts +69 -0
- package/esm/api/hooks/queries/{useApiModulesQuery.js → useDomainTypesQuery.js} +11 -11
- package/esm/api/hooks/query-keys.d.ts +14 -28
- package/esm/api/hooks/query-keys.js +8 -16
- package/esm/api/orm/index.d.ts +2 -4
- package/esm/api/orm/index.js +2 -4
- package/esm/api/orm/input-types.d.ts +378 -468
- package/esm/api/orm/input-types.js +2 -2
- package/esm/api/orm/models/domainType.d.ts +54 -0
- package/esm/api/orm/models/{apiModule.js → domainType.js} +25 -25
- package/esm/api/orm/models/index.d.ts +1 -2
- package/esm/api/orm/models/index.js +1 -2
- package/esm/api/schema-types.d.ts +157 -226
- package/esm/api/types.d.ts +16 -17
- package/esm/compute/orm/input-types.d.ts +42 -3
- package/esm/compute/schema-types.d.ts +25 -3
- package/esm/compute/types.d.ts +5 -0
- package/esm/modules/orm/input-types.d.ts +9 -16
- package/esm/modules/schema-types.d.ts +6 -10
- package/esm/modules/types.d.ts +1 -2
- package/modules/orm/input-types.d.ts +9 -16
- package/modules/schema-types.d.ts +6 -10
- package/modules/types.d.ts +1 -2
- package/package.json +5 -5
- package/api/hooks/mutations/useCreateApiModuleMutation.d.ts +0 -34
- package/api/hooks/mutations/useCreatePlatformApiModuleMutation.d.ts +0 -34
- package/api/hooks/mutations/useDeleteApiModuleMutation.d.ts +0 -38
- package/api/hooks/mutations/useDeletePlatformApiModuleMutation.d.ts +0 -38
- package/api/hooks/mutations/useUpdateApiModuleMutation.d.ts +0 -40
- package/api/hooks/mutations/useUpdatePlatformApiModuleMutation.d.ts +0 -40
- package/api/hooks/queries/useApiModuleQuery.d.ts +0 -65
- package/api/hooks/queries/useApiModulesQuery.d.ts +0 -69
- package/api/hooks/queries/usePlatformApiModuleQuery.d.ts +0 -65
- package/api/hooks/queries/usePlatformApiModulesQuery.d.ts +0 -69
- package/api/hooks/queries/usePlatformApiModulesQuery.js +0 -38
- package/api/orm/models/apiModule.d.ts +0 -54
- package/api/orm/models/platformApiModule.d.ts +0 -54
- package/esm/api/hooks/mutations/useCreateApiModuleMutation.d.ts +0 -34
- package/esm/api/hooks/mutations/useCreatePlatformApiModuleMutation.d.ts +0 -34
- package/esm/api/hooks/mutations/useDeleteApiModuleMutation.d.ts +0 -38
- package/esm/api/hooks/mutations/useDeletePlatformApiModuleMutation.d.ts +0 -38
- package/esm/api/hooks/mutations/useUpdateApiModuleMutation.d.ts +0 -40
- package/esm/api/hooks/mutations/useUpdatePlatformApiModuleMutation.d.ts +0 -40
- package/esm/api/hooks/queries/useApiModuleQuery.d.ts +0 -65
- package/esm/api/hooks/queries/useApiModulesQuery.d.ts +0 -69
- package/esm/api/hooks/queries/usePlatformApiModuleQuery.d.ts +0 -65
- package/esm/api/hooks/queries/usePlatformApiModulesQuery.d.ts +0 -69
- package/esm/api/orm/models/apiModule.d.ts +0 -54
- package/esm/api/orm/models/platformApiModule.d.ts +0 -54
|
@@ -21,12 +21,6 @@ export const apiMutationKeys = {
|
|
|
21
21
|
/** Update api mutation key */ update: (id) => ['mutation', 'api', 'update', id],
|
|
22
22
|
/** Delete api mutation key */ delete: (id) => ['mutation', 'api', 'delete', id],
|
|
23
23
|
};
|
|
24
|
-
export const apiModuleMutationKeys = {
|
|
25
|
-
/** All apiModule mutation keys */ all: ['mutation', 'apimodule'],
|
|
26
|
-
/** Create apiModule mutation key */ create: () => ['mutation', 'apimodule', 'create'],
|
|
27
|
-
/** Update apiModule mutation key */ update: (id) => ['mutation', 'apimodule', 'update', id],
|
|
28
|
-
/** Delete apiModule mutation key */ delete: (id) => ['mutation', 'apimodule', 'delete', id],
|
|
29
|
-
};
|
|
30
24
|
export const apiSchemaMutationKeys = {
|
|
31
25
|
/** All apiSchema mutation keys */ all: ['mutation', 'apischema'],
|
|
32
26
|
/** Create apiSchema mutation key */ create: () => ['mutation', 'apischema', 'create'],
|
|
@@ -99,6 +93,12 @@ export const domainEventMutationKeys = {
|
|
|
99
93
|
/** Update domainEvent mutation key */ update: (id) => ['mutation', 'domainevent', 'update', id],
|
|
100
94
|
/** Delete domainEvent mutation key */ delete: (id) => ['mutation', 'domainevent', 'delete', id],
|
|
101
95
|
};
|
|
96
|
+
export const domainTypeMutationKeys = {
|
|
97
|
+
/** All domainType mutation keys */ all: ['mutation', 'domaintype'],
|
|
98
|
+
/** Create domainType mutation key */ create: () => ['mutation', 'domaintype', 'create'],
|
|
99
|
+
/** Update domainType mutation key */ update: (id) => ['mutation', 'domaintype', 'update', id],
|
|
100
|
+
/** Delete domainType mutation key */ delete: (id) => ['mutation', 'domaintype', 'delete', id],
|
|
101
|
+
};
|
|
102
102
|
export const domainVerificationMutationKeys = {
|
|
103
103
|
/** All domainVerification mutation keys */ all: ['mutation', 'domainverification'],
|
|
104
104
|
/** Create domainVerification mutation key */ create: () => ['mutation', 'domainverification', 'create'],
|
|
@@ -189,12 +189,6 @@ export const platformApiMutationKeys = {
|
|
|
189
189
|
/** Update platformApi mutation key */ update: (id) => ['mutation', 'platformapi', 'update', id],
|
|
190
190
|
/** Delete platformApi mutation key */ delete: (id) => ['mutation', 'platformapi', 'delete', id],
|
|
191
191
|
};
|
|
192
|
-
export const platformApiModuleMutationKeys = {
|
|
193
|
-
/** All platformApiModule mutation keys */ all: ['mutation', 'platformapimodule'],
|
|
194
|
-
/** Create platformApiModule mutation key */ create: () => ['mutation', 'platformapimodule', 'create'],
|
|
195
|
-
/** Update platformApiModule mutation key */ update: (id) => ['mutation', 'platformapimodule', 'update', id],
|
|
196
|
-
/** Delete platformApiModule mutation key */ delete: (id) => ['mutation', 'platformapimodule', 'delete', id],
|
|
197
|
-
};
|
|
198
192
|
export const platformApiSchemaMutationKeys = {
|
|
199
193
|
/** All platformApiSchema mutation keys */ all: ['mutation', 'platformapischema'],
|
|
200
194
|
/** Create platformApiSchema mutation key */ create: () => ['mutation', 'platformapischema', 'create'],
|
|
@@ -464,7 +458,6 @@ export const customMutationKeys = {
|
|
|
464
458
|
*/
|
|
465
459
|
export const mutationKeys = {
|
|
466
460
|
api: apiMutationKeys,
|
|
467
|
-
apiModule: apiModuleMutationKeys,
|
|
468
461
|
apiSchema: apiSchemaMutationKeys,
|
|
469
462
|
apiSetting: apiSettingMutationKeys,
|
|
470
463
|
astMigration: astMigrationMutationKeys,
|
|
@@ -477,6 +470,7 @@ export const mutationKeys = {
|
|
|
477
470
|
defaultPrivilege: defaultPrivilegeMutationKeys,
|
|
478
471
|
domain: domainMutationKeys,
|
|
479
472
|
domainEvent: domainEventMutationKeys,
|
|
473
|
+
domainType: domainTypeMutationKeys,
|
|
480
474
|
domainVerification: domainVerificationMutationKeys,
|
|
481
475
|
embeddingChunk: embeddingChunkMutationKeys,
|
|
482
476
|
enum: enumMutationKeys,
|
|
@@ -492,7 +486,6 @@ export const mutationKeys = {
|
|
|
492
486
|
nodeTypeRegistry: nodeTypeRegistryMutationKeys,
|
|
493
487
|
partition: partitionMutationKeys,
|
|
494
488
|
platformApi: platformApiMutationKeys,
|
|
495
|
-
platformApiModule: platformApiModuleMutationKeys,
|
|
496
489
|
platformApiSchema: platformApiSchemaMutationKeys,
|
|
497
490
|
platformApiSetting: platformApiSettingMutationKeys,
|
|
498
491
|
platformCorsSetting: platformCorsSettingMutationKeys,
|
|
@@ -6,9 +6,6 @@
|
|
|
6
6
|
export * from './useCreateApiMutation';
|
|
7
7
|
export * from './useUpdateApiMutation';
|
|
8
8
|
export * from './useDeleteApiMutation';
|
|
9
|
-
export * from './useCreateApiModuleMutation';
|
|
10
|
-
export * from './useUpdateApiModuleMutation';
|
|
11
|
-
export * from './useDeleteApiModuleMutation';
|
|
12
9
|
export * from './useCreateApiSchemaMutation';
|
|
13
10
|
export * from './useUpdateApiSchemaMutation';
|
|
14
11
|
export * from './useDeleteApiSchemaMutation';
|
|
@@ -43,6 +40,9 @@ export * from './useDeleteDomainMutation';
|
|
|
43
40
|
export * from './useCreateDomainEventMutation';
|
|
44
41
|
export * from './useUpdateDomainEventMutation';
|
|
45
42
|
export * from './useDeleteDomainEventMutation';
|
|
43
|
+
export * from './useCreateDomainTypeMutation';
|
|
44
|
+
export * from './useUpdateDomainTypeMutation';
|
|
45
|
+
export * from './useDeleteDomainTypeMutation';
|
|
46
46
|
export * from './useCreateDomainVerificationMutation';
|
|
47
47
|
export * from './useUpdateDomainVerificationMutation';
|
|
48
48
|
export * from './useDeleteDomainVerificationMutation';
|
|
@@ -88,9 +88,6 @@ export * from './useDeletePartitionMutation';
|
|
|
88
88
|
export * from './useCreatePlatformApiMutation';
|
|
89
89
|
export * from './useUpdatePlatformApiMutation';
|
|
90
90
|
export * from './useDeletePlatformApiMutation';
|
|
91
|
-
export * from './useCreatePlatformApiModuleMutation';
|
|
92
|
-
export * from './useUpdatePlatformApiModuleMutation';
|
|
93
|
-
export * from './useDeletePlatformApiModuleMutation';
|
|
94
91
|
export * from './useCreatePlatformApiSchemaMutation';
|
|
95
92
|
export * from './useUpdatePlatformApiSchemaMutation';
|
|
96
93
|
export * from './useDeletePlatformApiSchemaMutation';
|
|
@@ -6,9 +6,6 @@
|
|
|
6
6
|
export * from './useCreateApiMutation';
|
|
7
7
|
export * from './useUpdateApiMutation';
|
|
8
8
|
export * from './useDeleteApiMutation';
|
|
9
|
-
export * from './useCreateApiModuleMutation';
|
|
10
|
-
export * from './useUpdateApiModuleMutation';
|
|
11
|
-
export * from './useDeleteApiModuleMutation';
|
|
12
9
|
export * from './useCreateApiSchemaMutation';
|
|
13
10
|
export * from './useUpdateApiSchemaMutation';
|
|
14
11
|
export * from './useDeleteApiSchemaMutation';
|
|
@@ -43,6 +40,9 @@ export * from './useDeleteDomainMutation';
|
|
|
43
40
|
export * from './useCreateDomainEventMutation';
|
|
44
41
|
export * from './useUpdateDomainEventMutation';
|
|
45
42
|
export * from './useDeleteDomainEventMutation';
|
|
43
|
+
export * from './useCreateDomainTypeMutation';
|
|
44
|
+
export * from './useUpdateDomainTypeMutation';
|
|
45
|
+
export * from './useDeleteDomainTypeMutation';
|
|
46
46
|
export * from './useCreateDomainVerificationMutation';
|
|
47
47
|
export * from './useUpdateDomainVerificationMutation';
|
|
48
48
|
export * from './useDeleteDomainVerificationMutation';
|
|
@@ -88,9 +88,6 @@ export * from './useDeletePartitionMutation';
|
|
|
88
88
|
export * from './useCreatePlatformApiMutation';
|
|
89
89
|
export * from './useUpdatePlatformApiMutation';
|
|
90
90
|
export * from './useDeletePlatformApiMutation';
|
|
91
|
-
export * from './useCreatePlatformApiModuleMutation';
|
|
92
|
-
export * from './useUpdatePlatformApiModuleMutation';
|
|
93
|
-
export * from './useDeletePlatformApiModuleMutation';
|
|
94
91
|
export * from './useCreatePlatformApiSchemaMutation';
|
|
95
92
|
export * from './useUpdatePlatformApiSchemaMutation';
|
|
96
93
|
export * from './useDeletePlatformApiSchemaMutation';
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Create mutation hook for DomainType
|
|
3
|
+
* @generated by @constructive-io/graphql-codegen
|
|
4
|
+
* DO NOT EDIT - changes will be overwritten
|
|
5
|
+
*/
|
|
6
|
+
import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
7
|
+
import type { DomainTypeSelect, DomainTypeWithRelations, CreateDomainTypeInput } from '../../orm/input-types';
|
|
8
|
+
import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types';
|
|
9
|
+
export type { DomainTypeSelect, DomainTypeWithRelations, CreateDomainTypeInput, } from '../../orm/input-types';
|
|
10
|
+
/**
|
|
11
|
+
* Mutation hook for creating a DomainType
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* const { mutate, isPending } = useCreateDomainTypeMutation({
|
|
16
|
+
* selection: { fields: { id: true, name: true } },
|
|
17
|
+
* });
|
|
18
|
+
*
|
|
19
|
+
* mutate({ name: 'New item' });
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare function useCreateDomainTypeMutation<S extends DomainTypeSelect>(params: {
|
|
23
|
+
selection: {
|
|
24
|
+
fields: S & DomainTypeSelect;
|
|
25
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
26
|
+
} & Omit<UseMutationOptions<{
|
|
27
|
+
createDomainType: {
|
|
28
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
29
|
+
};
|
|
30
|
+
}, Error, CreateDomainTypeInput['domainType']>, 'mutationFn'>): UseMutationResult<{
|
|
31
|
+
createDomainType: {
|
|
32
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
33
|
+
};
|
|
34
|
+
}, Error, CreateDomainTypeInput['domainType']>;
|
package/esm/api/hooks/mutations/{useCreateApiModuleMutation.js → useCreateDomainTypeMutation.js}
RENAMED
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Create mutation hook for DomainType
|
|
3
3
|
* @generated by @constructive-io/graphql-codegen
|
|
4
4
|
* DO NOT EDIT - changes will be overwritten
|
|
5
5
|
*/
|
|
6
6
|
import { useMutation, useQueryClient } from '@tanstack/react-query';
|
|
7
7
|
import { getClient } from '../client';
|
|
8
8
|
import { buildSelectionArgs } from '../selection';
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
export function
|
|
9
|
+
import { domainTypeKeys } from '../query-keys';
|
|
10
|
+
import { domainTypeMutationKeys } from '../mutation-keys';
|
|
11
|
+
export function useCreateDomainTypeMutation(params) {
|
|
12
12
|
const args = buildSelectionArgs(params.selection);
|
|
13
13
|
const { selection: _selection, ...mutationOptions } = params ?? {};
|
|
14
14
|
void _selection;
|
|
15
15
|
const queryClient = useQueryClient();
|
|
16
16
|
return useMutation({
|
|
17
|
-
mutationKey:
|
|
17
|
+
mutationKey: domainTypeMutationKeys.create(),
|
|
18
18
|
mutationFn: (data) => getClient()
|
|
19
|
-
.
|
|
19
|
+
.domainType.create({
|
|
20
20
|
data,
|
|
21
21
|
select: args.select,
|
|
22
22
|
})
|
|
23
23
|
.unwrap(),
|
|
24
24
|
onSuccess: () => {
|
|
25
25
|
queryClient.invalidateQueries({
|
|
26
|
-
queryKey:
|
|
26
|
+
queryKey: domainTypeKeys.lists(),
|
|
27
27
|
});
|
|
28
28
|
},
|
|
29
29
|
...mutationOptions,
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Delete mutation hook for DomainType
|
|
3
|
+
* @generated by @constructive-io/graphql-codegen
|
|
4
|
+
* DO NOT EDIT - changes will be overwritten
|
|
5
|
+
*/
|
|
6
|
+
import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
7
|
+
import type { DomainTypeSelect, DomainTypeWithRelations } from '../../orm/input-types';
|
|
8
|
+
import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types';
|
|
9
|
+
export type { DomainTypeSelect, DomainTypeWithRelations } from '../../orm/input-types';
|
|
10
|
+
/**
|
|
11
|
+
* Mutation hook for deleting a DomainType with typed selection
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* const { mutate, isPending } = useDeleteDomainTypeMutation({
|
|
16
|
+
* selection: { fields: { id: true } },
|
|
17
|
+
* });
|
|
18
|
+
*
|
|
19
|
+
* mutate({ id: 'value-to-delete' });
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare function useDeleteDomainTypeMutation<S extends DomainTypeSelect>(params: {
|
|
23
|
+
selection: {
|
|
24
|
+
fields: S & DomainTypeSelect;
|
|
25
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
26
|
+
} & Omit<UseMutationOptions<{
|
|
27
|
+
deleteDomainType: {
|
|
28
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
29
|
+
};
|
|
30
|
+
}, Error, {
|
|
31
|
+
id: string;
|
|
32
|
+
}>, 'mutationFn'>): UseMutationResult<{
|
|
33
|
+
deleteDomainType: {
|
|
34
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
35
|
+
};
|
|
36
|
+
}, Error, {
|
|
37
|
+
id: string;
|
|
38
|
+
}>;
|
package/esm/api/hooks/mutations/{useDeleteApiModuleMutation.js → useDeleteDomainTypeMutation.js}
RENAMED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Delete mutation hook for DomainType
|
|
3
3
|
* @generated by @constructive-io/graphql-codegen
|
|
4
4
|
* DO NOT EDIT - changes will be overwritten
|
|
5
5
|
*/
|
|
6
6
|
import { useMutation, useQueryClient } from '@tanstack/react-query';
|
|
7
7
|
import { getClient } from '../client';
|
|
8
8
|
import { buildSelectionArgs } from '../selection';
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
export function
|
|
9
|
+
import { domainTypeKeys } from '../query-keys';
|
|
10
|
+
import { domainTypeMutationKeys } from '../mutation-keys';
|
|
11
|
+
export function useDeleteDomainTypeMutation(params) {
|
|
12
12
|
const args = buildSelectionArgs(params.selection);
|
|
13
13
|
const { selection: _selection, ...mutationOptions } = params ?? {};
|
|
14
14
|
void _selection;
|
|
15
15
|
const queryClient = useQueryClient();
|
|
16
16
|
return useMutation({
|
|
17
|
-
mutationKey:
|
|
17
|
+
mutationKey: domainTypeMutationKeys.all,
|
|
18
18
|
mutationFn: ({ id }) => getClient()
|
|
19
|
-
.
|
|
19
|
+
.domainType.delete({
|
|
20
20
|
where: {
|
|
21
21
|
id,
|
|
22
22
|
},
|
|
@@ -25,10 +25,10 @@ export function useDeleteApiModuleMutation(params) {
|
|
|
25
25
|
.unwrap(),
|
|
26
26
|
onSuccess: (_, variables) => {
|
|
27
27
|
queryClient.removeQueries({
|
|
28
|
-
queryKey:
|
|
28
|
+
queryKey: domainTypeKeys.detail(variables.id),
|
|
29
29
|
});
|
|
30
30
|
queryClient.invalidateQueries({
|
|
31
|
-
queryKey:
|
|
31
|
+
queryKey: domainTypeKeys.lists(),
|
|
32
32
|
});
|
|
33
33
|
},
|
|
34
34
|
...mutationOptions,
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Update mutation hook for DomainType
|
|
3
|
+
* @generated by @constructive-io/graphql-codegen
|
|
4
|
+
* DO NOT EDIT - changes will be overwritten
|
|
5
|
+
*/
|
|
6
|
+
import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query';
|
|
7
|
+
import type { DomainTypeSelect, DomainTypeWithRelations, DomainTypePatch } from '../../orm/input-types';
|
|
8
|
+
import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types';
|
|
9
|
+
export type { DomainTypeSelect, DomainTypeWithRelations, DomainTypePatch, } from '../../orm/input-types';
|
|
10
|
+
/**
|
|
11
|
+
* Mutation hook for updating a DomainType
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* const { mutate, isPending } = useUpdateDomainTypeMutation({
|
|
16
|
+
* selection: { fields: { id: true, name: true } },
|
|
17
|
+
* });
|
|
18
|
+
*
|
|
19
|
+
* mutate({ id: 'value-here', domainTypePatch: { name: 'Updated' } });
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare function useUpdateDomainTypeMutation<S extends DomainTypeSelect>(params: {
|
|
23
|
+
selection: {
|
|
24
|
+
fields: S & DomainTypeSelect;
|
|
25
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
26
|
+
} & Omit<UseMutationOptions<{
|
|
27
|
+
updateDomainType: {
|
|
28
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
29
|
+
};
|
|
30
|
+
}, Error, {
|
|
31
|
+
id: string;
|
|
32
|
+
domainTypePatch: DomainTypePatch;
|
|
33
|
+
}>, 'mutationFn'>): UseMutationResult<{
|
|
34
|
+
updateDomainType: {
|
|
35
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S>;
|
|
36
|
+
};
|
|
37
|
+
}, Error, {
|
|
38
|
+
id: string;
|
|
39
|
+
domainTypePatch: DomainTypePatch;
|
|
40
|
+
}>;
|
package/esm/api/hooks/mutations/{useUpdateApiModuleMutation.js → useUpdateDomainTypeMutation.js}
RENAMED
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Update mutation hook for DomainType
|
|
3
3
|
* @generated by @constructive-io/graphql-codegen
|
|
4
4
|
* DO NOT EDIT - changes will be overwritten
|
|
5
5
|
*/
|
|
6
6
|
import { useMutation, useQueryClient } from '@tanstack/react-query';
|
|
7
7
|
import { getClient } from '../client';
|
|
8
8
|
import { buildSelectionArgs } from '../selection';
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
export function
|
|
9
|
+
import { domainTypeKeys } from '../query-keys';
|
|
10
|
+
import { domainTypeMutationKeys } from '../mutation-keys';
|
|
11
|
+
export function useUpdateDomainTypeMutation(params) {
|
|
12
12
|
const args = buildSelectionArgs(params.selection);
|
|
13
13
|
const { selection: _selection, ...mutationOptions } = params ?? {};
|
|
14
14
|
void _selection;
|
|
15
15
|
const queryClient = useQueryClient();
|
|
16
16
|
return useMutation({
|
|
17
|
-
mutationKey:
|
|
18
|
-
mutationFn: ({ id,
|
|
19
|
-
.
|
|
17
|
+
mutationKey: domainTypeMutationKeys.all,
|
|
18
|
+
mutationFn: ({ id, domainTypePatch }) => getClient()
|
|
19
|
+
.domainType.update({
|
|
20
20
|
where: {
|
|
21
21
|
id,
|
|
22
22
|
},
|
|
23
|
-
data:
|
|
23
|
+
data: domainTypePatch,
|
|
24
24
|
select: args.select,
|
|
25
25
|
})
|
|
26
26
|
.unwrap(),
|
|
27
27
|
onSuccess: (_, variables) => {
|
|
28
28
|
queryClient.invalidateQueries({
|
|
29
|
-
queryKey:
|
|
29
|
+
queryKey: domainTypeKeys.detail(variables.id),
|
|
30
30
|
});
|
|
31
31
|
queryClient.invalidateQueries({
|
|
32
|
-
queryKey:
|
|
32
|
+
queryKey: domainTypeKeys.lists(),
|
|
33
33
|
});
|
|
34
34
|
},
|
|
35
35
|
...mutationOptions,
|
|
@@ -5,8 +5,6 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export * from './useApisQuery';
|
|
7
7
|
export * from './useApiQuery';
|
|
8
|
-
export * from './useApiModulesQuery';
|
|
9
|
-
export * from './useApiModuleQuery';
|
|
10
8
|
export * from './useApiSchemasQuery';
|
|
11
9
|
export * from './useApiSchemaQuery';
|
|
12
10
|
export * from './useApiSettingsQuery';
|
|
@@ -31,6 +29,8 @@ export * from './useDomainsQuery';
|
|
|
31
29
|
export * from './useDomainQuery';
|
|
32
30
|
export * from './useDomainEventsQuery';
|
|
33
31
|
export * from './useDomainEventQuery';
|
|
32
|
+
export * from './useDomainTypesQuery';
|
|
33
|
+
export * from './useDomainTypeQuery';
|
|
34
34
|
export * from './useDomainVerificationsQuery';
|
|
35
35
|
export * from './useDomainVerificationQuery';
|
|
36
36
|
export * from './useEmbeddingChunksQuery';
|
|
@@ -61,8 +61,6 @@ export * from './usePartitionsQuery';
|
|
|
61
61
|
export * from './usePartitionQuery';
|
|
62
62
|
export * from './usePlatformApisQuery';
|
|
63
63
|
export * from './usePlatformApiQuery';
|
|
64
|
-
export * from './usePlatformApiModulesQuery';
|
|
65
|
-
export * from './usePlatformApiModuleQuery';
|
|
66
64
|
export * from './usePlatformApiSchemasQuery';
|
|
67
65
|
export * from './usePlatformApiSchemaQuery';
|
|
68
66
|
export * from './usePlatformApiSettingsQuery';
|
|
@@ -5,8 +5,6 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export * from './useApisQuery';
|
|
7
7
|
export * from './useApiQuery';
|
|
8
|
-
export * from './useApiModulesQuery';
|
|
9
|
-
export * from './useApiModuleQuery';
|
|
10
8
|
export * from './useApiSchemasQuery';
|
|
11
9
|
export * from './useApiSchemaQuery';
|
|
12
10
|
export * from './useApiSettingsQuery';
|
|
@@ -31,6 +29,8 @@ export * from './useDomainsQuery';
|
|
|
31
29
|
export * from './useDomainQuery';
|
|
32
30
|
export * from './useDomainEventsQuery';
|
|
33
31
|
export * from './useDomainEventQuery';
|
|
32
|
+
export * from './useDomainTypesQuery';
|
|
33
|
+
export * from './useDomainTypeQuery';
|
|
34
34
|
export * from './useDomainVerificationsQuery';
|
|
35
35
|
export * from './useDomainVerificationQuery';
|
|
36
36
|
export * from './useEmbeddingChunksQuery';
|
|
@@ -61,8 +61,6 @@ export * from './usePartitionsQuery';
|
|
|
61
61
|
export * from './usePartitionQuery';
|
|
62
62
|
export * from './usePlatformApisQuery';
|
|
63
63
|
export * from './usePlatformApiQuery';
|
|
64
|
-
export * from './usePlatformApiModulesQuery';
|
|
65
|
-
export * from './usePlatformApiModuleQuery';
|
|
66
64
|
export * from './usePlatformApiSchemasQuery';
|
|
67
65
|
export * from './usePlatformApiSchemaQuery';
|
|
68
66
|
export * from './usePlatformApiSettingsQuery';
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Single item query hook for DomainType
|
|
3
|
+
* @generated by @constructive-io/graphql-codegen
|
|
4
|
+
* DO NOT EDIT - changes will be overwritten
|
|
5
|
+
*/
|
|
6
|
+
import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query';
|
|
7
|
+
import type { DomainTypeSelect, DomainTypeWithRelations } from '../../orm/input-types';
|
|
8
|
+
import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types';
|
|
9
|
+
export type { DomainTypeSelect, DomainTypeWithRelations } from '../../orm/input-types';
|
|
10
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
11
|
+
export declare const domainTypeQueryKey: (id: string | number) => readonly ["domaintype", "detail", string | number];
|
|
12
|
+
/**
|
|
13
|
+
* Query hook for fetching a single DomainType
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* const { data, isLoading } = useDomainTypeQuery({
|
|
18
|
+
* id: 'some-id',
|
|
19
|
+
* selection: { fields: { id: true, name: true } },
|
|
20
|
+
* });
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
export declare function useDomainTypeQuery<S extends DomainTypeSelect, TData = {
|
|
24
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S> | null;
|
|
25
|
+
}>(params: {
|
|
26
|
+
id: string;
|
|
27
|
+
selection: {
|
|
28
|
+
fields: S;
|
|
29
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
30
|
+
} & Omit<UseQueryOptions<{
|
|
31
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S> | null;
|
|
32
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
33
|
+
/**
|
|
34
|
+
* Fetch a single DomainType without React hooks
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* ```ts
|
|
38
|
+
* const data = await fetchDomainTypeQuery({
|
|
39
|
+
* id: 'some-id',
|
|
40
|
+
* selection: { fields: { id: true } },
|
|
41
|
+
* });
|
|
42
|
+
* ```
|
|
43
|
+
*/
|
|
44
|
+
export declare function fetchDomainTypeQuery<S extends DomainTypeSelect>(params: {
|
|
45
|
+
id: string;
|
|
46
|
+
selection: {
|
|
47
|
+
fields: S;
|
|
48
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
49
|
+
}): Promise<{
|
|
50
|
+
domainType: InferSelectResult<DomainTypeWithRelations, S> | null;
|
|
51
|
+
}>;
|
|
52
|
+
/**
|
|
53
|
+
* Prefetch a single DomainType for SSR or cache warming
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* ```ts
|
|
57
|
+
* await prefetchDomainTypeQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } });
|
|
58
|
+
* ```
|
|
59
|
+
*/
|
|
60
|
+
export declare function prefetchDomainTypeQuery<S extends DomainTypeSelect>(queryClient: QueryClient, params: {
|
|
61
|
+
id: string;
|
|
62
|
+
selection: {
|
|
63
|
+
fields: S;
|
|
64
|
+
} & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
65
|
+
}): Promise<void>;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Single item query hook for DomainType
|
|
3
3
|
* @generated by @constructive-io/graphql-codegen
|
|
4
4
|
* DO NOT EDIT - changes will be overwritten
|
|
5
5
|
*/
|
|
6
6
|
import { useQuery } from '@tanstack/react-query';
|
|
7
7
|
import { getClient } from '../client';
|
|
8
8
|
import { buildSelectionArgs } from '../selection';
|
|
9
|
-
import {
|
|
9
|
+
import { domainTypeKeys } from '../query-keys';
|
|
10
10
|
/** Query key factory - re-exported from query-keys.ts */
|
|
11
|
-
export const
|
|
12
|
-
export function
|
|
11
|
+
export const domainTypeQueryKey = domainTypeKeys.detail;
|
|
12
|
+
export function useDomainTypeQuery(params) {
|
|
13
13
|
const args = buildSelectionArgs(params.selection);
|
|
14
14
|
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
15
15
|
void _selection;
|
|
16
16
|
return useQuery({
|
|
17
|
-
queryKey:
|
|
17
|
+
queryKey: domainTypeKeys.detail(params.id),
|
|
18
18
|
queryFn: () => getClient()
|
|
19
|
-
.
|
|
19
|
+
.domainType.findOne({
|
|
20
20
|
id: params.id,
|
|
21
21
|
select: args.select,
|
|
22
22
|
})
|
|
@@ -24,21 +24,21 @@ export function useApiModuleQuery(params) {
|
|
|
24
24
|
...queryOptions,
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
|
-
export async function
|
|
27
|
+
export async function fetchDomainTypeQuery(params) {
|
|
28
28
|
const args = buildSelectionArgs(params.selection);
|
|
29
29
|
return getClient()
|
|
30
|
-
.
|
|
30
|
+
.domainType.findOne({
|
|
31
31
|
id: params.id,
|
|
32
32
|
select: args.select,
|
|
33
33
|
})
|
|
34
34
|
.unwrap();
|
|
35
35
|
}
|
|
36
|
-
export async function
|
|
36
|
+
export async function prefetchDomainTypeQuery(queryClient, params) {
|
|
37
37
|
const args = buildSelectionArgs(params.selection);
|
|
38
38
|
await queryClient.prefetchQuery({
|
|
39
|
-
queryKey:
|
|
39
|
+
queryKey: domainTypeKeys.detail(params.id),
|
|
40
40
|
queryFn: () => getClient()
|
|
41
|
-
.
|
|
41
|
+
.domainType.findOne({
|
|
42
42
|
id: params.id,
|
|
43
43
|
select: args.select,
|
|
44
44
|
})
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* List query hook for DomainType
|
|
3
|
+
* @generated by @constructive-io/graphql-codegen
|
|
4
|
+
* DO NOT EDIT - changes will be overwritten
|
|
5
|
+
*/
|
|
6
|
+
import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query';
|
|
7
|
+
import type { ListSelectionConfig } from '../selection';
|
|
8
|
+
import type { DomainTypeSelect, DomainTypeWithRelations, DomainTypeFilter, DomainTypeOrderBy } from '../../orm/input-types';
|
|
9
|
+
import type { InferSelectResult, ConnectionResult, HookStrictSelect } from '../../orm/select-types';
|
|
10
|
+
export type { DomainTypeSelect, DomainTypeWithRelations, DomainTypeFilter, DomainTypeOrderBy, } from '../../orm/input-types';
|
|
11
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
12
|
+
export declare const domainTypesQueryKey: (variables?: object) => readonly ["domaintype", "list", object];
|
|
13
|
+
/**
|
|
14
|
+
* Query hook for fetching DomainType list
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* const { data, isLoading } = useDomainTypesQuery({
|
|
19
|
+
* selection: {
|
|
20
|
+
* fields: { id: true, name: true },
|
|
21
|
+
* where: { name: { equalTo: "example" } },
|
|
22
|
+
* orderBy: ['CREATED_AT_DESC'],
|
|
23
|
+
* first: 10,
|
|
24
|
+
* },
|
|
25
|
+
* });
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
export declare function useDomainTypesQuery<S extends DomainTypeSelect, TData = {
|
|
29
|
+
domainTypes: ConnectionResult<InferSelectResult<DomainTypeWithRelations, S>>;
|
|
30
|
+
}>(params: {
|
|
31
|
+
selection: {
|
|
32
|
+
fields: S;
|
|
33
|
+
} & Omit<ListSelectionConfig<S, DomainTypeFilter, DomainTypeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
34
|
+
} & Omit<UseQueryOptions<{
|
|
35
|
+
domainTypes: ConnectionResult<InferSelectResult<DomainTypeWithRelations, S>>;
|
|
36
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
37
|
+
/**
|
|
38
|
+
* Fetch DomainType list without React hooks
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```ts
|
|
42
|
+
* const data = await fetchDomainTypesQuery({
|
|
43
|
+
* selection: {
|
|
44
|
+
* fields: { id: true },
|
|
45
|
+
* first: 10,
|
|
46
|
+
* },
|
|
47
|
+
* });
|
|
48
|
+
* ```
|
|
49
|
+
*/
|
|
50
|
+
export declare function fetchDomainTypesQuery<S extends DomainTypeSelect>(params: {
|
|
51
|
+
selection: {
|
|
52
|
+
fields: S;
|
|
53
|
+
} & Omit<ListSelectionConfig<S, DomainTypeFilter, DomainTypeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
54
|
+
}): Promise<{
|
|
55
|
+
domainTypes: ConnectionResult<InferSelectResult<DomainTypeWithRelations, S>>;
|
|
56
|
+
}>;
|
|
57
|
+
/**
|
|
58
|
+
* Prefetch DomainType list for SSR or cache warming
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* ```ts
|
|
62
|
+
* await prefetchDomainTypesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } });
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
export declare function prefetchDomainTypesQuery<S extends DomainTypeSelect>(queryClient: QueryClient, params: {
|
|
66
|
+
selection: {
|
|
67
|
+
fields: S;
|
|
68
|
+
} & Omit<ListSelectionConfig<S, DomainTypeFilter, DomainTypeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, DomainTypeSelect>;
|
|
69
|
+
}): Promise<void>;
|
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* List query hook for DomainType
|
|
3
3
|
* @generated by @constructive-io/graphql-codegen
|
|
4
4
|
* DO NOT EDIT - changes will be overwritten
|
|
5
5
|
*/
|
|
6
6
|
import { useQuery } from '@tanstack/react-query';
|
|
7
7
|
import { getClient } from '../client';
|
|
8
8
|
import { buildListSelectionArgs } from '../selection';
|
|
9
|
-
import {
|
|
9
|
+
import { domainTypeKeys } from '../query-keys';
|
|
10
10
|
/** Query key factory - re-exported from query-keys.ts */
|
|
11
|
-
export const
|
|
12
|
-
export function
|
|
11
|
+
export const domainTypesQueryKey = domainTypeKeys.list;
|
|
12
|
+
export function useDomainTypesQuery(params) {
|
|
13
13
|
const args = buildListSelectionArgs(params.selection);
|
|
14
14
|
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
15
15
|
void _selection;
|
|
16
16
|
return useQuery({
|
|
17
|
-
queryKey:
|
|
18
|
-
queryFn: () => getClient().
|
|
17
|
+
queryKey: domainTypeKeys.list(args),
|
|
18
|
+
queryFn: () => getClient().domainType.findMany(args).unwrap(),
|
|
19
19
|
...queryOptions,
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
|
-
export async function
|
|
22
|
+
export async function fetchDomainTypesQuery(params) {
|
|
23
23
|
const args = buildListSelectionArgs(params.selection);
|
|
24
|
-
return getClient().
|
|
24
|
+
return getClient().domainType.findMany(args).unwrap();
|
|
25
25
|
}
|
|
26
|
-
export async function
|
|
26
|
+
export async function prefetchDomainTypesQuery(queryClient, params) {
|
|
27
27
|
const args = buildListSelectionArgs(params.selection);
|
|
28
28
|
await queryClient.prefetchQuery({
|
|
29
|
-
queryKey:
|
|
30
|
-
queryFn: () => getClient().
|
|
29
|
+
queryKey: domainTypeKeys.list(args),
|
|
30
|
+
queryFn: () => getClient().domainType.findMany(args).unwrap(),
|
|
31
31
|
});
|
|
32
32
|
}
|