@constructive-io/react 1.9.2 → 1.9.3
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
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
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 { OrgChartEdgeSelect, OrgChartEdgeWithRelations } from '../../orm/input-types';
|
|
8
|
+
import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types';
|
|
9
|
+
export type { OrgChartEdgeSelect, OrgChartEdgeWithRelations } from '../../orm/input-types';
|
|
10
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
11
|
+
export declare const orgChartEdgeQueryKey: (id: string | number) => readonly ["orgchartedge", "detail", string | number];
|
|
12
|
+
/**
|
|
13
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* const { data, isLoading } = useOrgChartEdgeQuery({
|
|
18
|
+
* id: 'some-id',
|
|
19
|
+
* selection: { fields: { id: true, name: true } },
|
|
20
|
+
* });
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
export declare function useOrgChartEdgeQuery<S extends OrgChartEdgeSelect, TData = {
|
|
24
|
+
orgChartEdge: InferSelectResult<OrgChartEdgeWithRelations, S> | null;
|
|
25
|
+
}>(params: {
|
|
26
|
+
id: string;
|
|
27
|
+
selection: {
|
|
28
|
+
fields: S;
|
|
29
|
+
} & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
30
|
+
} & Omit<UseQueryOptions<{
|
|
31
|
+
orgChartEdge: InferSelectResult<OrgChartEdgeWithRelations, S> | null;
|
|
32
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
33
|
+
/**
|
|
34
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* ```ts
|
|
38
|
+
* const data = await fetchOrgChartEdgeQuery({
|
|
39
|
+
* id: 'some-id',
|
|
40
|
+
* selection: { fields: { id: true } },
|
|
41
|
+
* });
|
|
42
|
+
* ```
|
|
43
|
+
*/
|
|
44
|
+
export declare function fetchOrgChartEdgeQuery<S extends OrgChartEdgeSelect>(params: {
|
|
45
|
+
id: string;
|
|
46
|
+
selection: {
|
|
47
|
+
fields: S;
|
|
48
|
+
} & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
49
|
+
}): Promise<{
|
|
50
|
+
orgChartEdge: InferSelectResult<OrgChartEdgeWithRelations, S> | null;
|
|
51
|
+
}>;
|
|
52
|
+
/**
|
|
53
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* ```ts
|
|
57
|
+
* await prefetchOrgChartEdgeQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } });
|
|
58
|
+
* ```
|
|
59
|
+
*/
|
|
60
|
+
export declare function prefetchOrgChartEdgeQuery<S extends OrgChartEdgeSelect>(queryClient: QueryClient, params: {
|
|
61
|
+
id: string;
|
|
62
|
+
selection: {
|
|
63
|
+
fields: S;
|
|
64
|
+
} & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
65
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
4
|
+
* @generated by @constructive-io/graphql-codegen
|
|
5
|
+
* DO NOT EDIT - changes will be overwritten
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.orgChartEdgeQueryKey = void 0;
|
|
9
|
+
exports.useOrgChartEdgeQuery = useOrgChartEdgeQuery;
|
|
10
|
+
exports.fetchOrgChartEdgeQuery = fetchOrgChartEdgeQuery;
|
|
11
|
+
exports.prefetchOrgChartEdgeQuery = prefetchOrgChartEdgeQuery;
|
|
12
|
+
const react_query_1 = require("@tanstack/react-query");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const selection_1 = require("../selection");
|
|
15
|
+
const query_keys_1 = require("../query-keys");
|
|
16
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
17
|
+
exports.orgChartEdgeQueryKey = query_keys_1.orgChartEdgeKeys.detail;
|
|
18
|
+
function useOrgChartEdgeQuery(params) {
|
|
19
|
+
const args = (0, selection_1.buildSelectionArgs)(params.selection);
|
|
20
|
+
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
21
|
+
void _selection;
|
|
22
|
+
return (0, react_query_1.useQuery)({
|
|
23
|
+
queryKey: query_keys_1.orgChartEdgeKeys.detail(params.id),
|
|
24
|
+
queryFn: () => (0, client_1.getClient)()
|
|
25
|
+
.orgChartEdge.findOne({
|
|
26
|
+
id: params.id,
|
|
27
|
+
select: args.select,
|
|
28
|
+
})
|
|
29
|
+
.unwrap(),
|
|
30
|
+
...queryOptions,
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
async function fetchOrgChartEdgeQuery(params) {
|
|
34
|
+
const args = (0, selection_1.buildSelectionArgs)(params.selection);
|
|
35
|
+
return (0, client_1.getClient)()
|
|
36
|
+
.orgChartEdge.findOne({
|
|
37
|
+
id: params.id,
|
|
38
|
+
select: args.select,
|
|
39
|
+
})
|
|
40
|
+
.unwrap();
|
|
41
|
+
}
|
|
42
|
+
async function prefetchOrgChartEdgeQuery(queryClient, params) {
|
|
43
|
+
const args = (0, selection_1.buildSelectionArgs)(params.selection);
|
|
44
|
+
await queryClient.prefetchQuery({
|
|
45
|
+
queryKey: query_keys_1.orgChartEdgeKeys.detail(params.id),
|
|
46
|
+
queryFn: () => (0, client_1.getClient)()
|
|
47
|
+
.orgChartEdge.findOne({
|
|
48
|
+
id: params.id,
|
|
49
|
+
select: args.select,
|
|
50
|
+
})
|
|
51
|
+
.unwrap(),
|
|
52
|
+
});
|
|
53
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
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 { OrgChartEdgeSelect, OrgChartEdgeWithRelations, OrgChartEdgeFilter, OrgChartEdgeOrderBy } from '../../orm/input-types';
|
|
9
|
+
import type { InferSelectResult, ConnectionResult, HookStrictSelect } from '../../orm/select-types';
|
|
10
|
+
export type { OrgChartEdgeSelect, OrgChartEdgeWithRelations, OrgChartEdgeFilter, OrgChartEdgeOrderBy, } from '../../orm/input-types';
|
|
11
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
12
|
+
export declare const orgChartEdgesQueryKey: (variables?: object) => readonly ["orgchartedge", "list", object];
|
|
13
|
+
/**
|
|
14
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* const { data, isLoading } = useOrgChartEdgesQuery({
|
|
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 useOrgChartEdgesQuery<S extends OrgChartEdgeSelect, TData = {
|
|
29
|
+
orgChartEdges: ConnectionResult<InferSelectResult<OrgChartEdgeWithRelations, S>>;
|
|
30
|
+
}>(params: {
|
|
31
|
+
selection: {
|
|
32
|
+
fields: S;
|
|
33
|
+
} & Omit<ListSelectionConfig<S, OrgChartEdgeFilter, OrgChartEdgeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
34
|
+
} & Omit<UseQueryOptions<{
|
|
35
|
+
orgChartEdges: ConnectionResult<InferSelectResult<OrgChartEdgeWithRelations, S>>;
|
|
36
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
37
|
+
/**
|
|
38
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```ts
|
|
42
|
+
* const data = await fetchOrgChartEdgesQuery({
|
|
43
|
+
* selection: {
|
|
44
|
+
* fields: { id: true },
|
|
45
|
+
* first: 10,
|
|
46
|
+
* },
|
|
47
|
+
* });
|
|
48
|
+
* ```
|
|
49
|
+
*/
|
|
50
|
+
export declare function fetchOrgChartEdgesQuery<S extends OrgChartEdgeSelect>(params: {
|
|
51
|
+
selection: {
|
|
52
|
+
fields: S;
|
|
53
|
+
} & Omit<ListSelectionConfig<S, OrgChartEdgeFilter, OrgChartEdgeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
54
|
+
}): Promise<{
|
|
55
|
+
orgChartEdges: ConnectionResult<InferSelectResult<OrgChartEdgeWithRelations, S>>;
|
|
56
|
+
}>;
|
|
57
|
+
/**
|
|
58
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* ```ts
|
|
62
|
+
* await prefetchOrgChartEdgesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } });
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
export declare function prefetchOrgChartEdgesQuery<S extends OrgChartEdgeSelect>(queryClient: QueryClient, params: {
|
|
66
|
+
selection: {
|
|
67
|
+
fields: S;
|
|
68
|
+
} & Omit<ListSelectionConfig<S, OrgChartEdgeFilter, OrgChartEdgeOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgChartEdgeSelect>;
|
|
69
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Organizational chart edges defining parent-child reporting relationships between members within an entity
|
|
4
|
+
* @generated by @constructive-io/graphql-codegen
|
|
5
|
+
* DO NOT EDIT - changes will be overwritten
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.orgChartEdgesQueryKey = void 0;
|
|
9
|
+
exports.useOrgChartEdgesQuery = useOrgChartEdgesQuery;
|
|
10
|
+
exports.fetchOrgChartEdgesQuery = fetchOrgChartEdgesQuery;
|
|
11
|
+
exports.prefetchOrgChartEdgesQuery = prefetchOrgChartEdgesQuery;
|
|
12
|
+
const react_query_1 = require("@tanstack/react-query");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const selection_1 = require("../selection");
|
|
15
|
+
const query_keys_1 = require("../query-keys");
|
|
16
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
17
|
+
exports.orgChartEdgesQueryKey = query_keys_1.orgChartEdgeKeys.list;
|
|
18
|
+
function useOrgChartEdgesQuery(params) {
|
|
19
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
20
|
+
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
21
|
+
void _selection;
|
|
22
|
+
return (0, react_query_1.useQuery)({
|
|
23
|
+
queryKey: query_keys_1.orgChartEdgeKeys.list(args),
|
|
24
|
+
queryFn: () => (0, client_1.getClient)().orgChartEdge.findMany(args).unwrap(),
|
|
25
|
+
...queryOptions,
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
async function fetchOrgChartEdgesQuery(params) {
|
|
29
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
30
|
+
return (0, client_1.getClient)().orgChartEdge.findMany(args).unwrap();
|
|
31
|
+
}
|
|
32
|
+
async function prefetchOrgChartEdgesQuery(queryClient, params) {
|
|
33
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
34
|
+
await queryClient.prefetchQuery({
|
|
35
|
+
queryKey: query_keys_1.orgChartEdgeKeys.list(args),
|
|
36
|
+
queryFn: () => (0, client_1.getClient)().orgChartEdge.findMany(args).unwrap(),
|
|
37
|
+
});
|
|
38
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* List query hook for OrgGetManagersRecord
|
|
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 { OrgGetManagersRecordSelect, OrgGetManagersRecordWithRelations, OrgGetManagersRecordFilter, OrgGetManagersRecordsOrderBy } from '../../orm/input-types';
|
|
9
|
+
import type { InferSelectResult, ConnectionResult, HookStrictSelect } from '../../orm/select-types';
|
|
10
|
+
export type { OrgGetManagersRecordSelect, OrgGetManagersRecordWithRelations, OrgGetManagersRecordFilter, OrgGetManagersRecordsOrderBy, } from '../../orm/input-types';
|
|
11
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
12
|
+
export declare const orgGetManagersQueryKey: (variables?: object) => readonly ["orggetmanagersrecord", "list", object];
|
|
13
|
+
/**
|
|
14
|
+
* Query hook for fetching OrgGetManagersRecord list
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* const { data, isLoading } = useOrgGetManagersQuery({
|
|
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 useOrgGetManagersQuery<S extends OrgGetManagersRecordSelect, TData = {
|
|
29
|
+
orgGetManagers: ConnectionResult<InferSelectResult<OrgGetManagersRecordWithRelations, S>>;
|
|
30
|
+
}>(params: {
|
|
31
|
+
selection: {
|
|
32
|
+
fields: S;
|
|
33
|
+
} & Omit<ListSelectionConfig<S, OrgGetManagersRecordFilter, OrgGetManagersRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetManagersRecordSelect>;
|
|
34
|
+
} & Omit<UseQueryOptions<{
|
|
35
|
+
orgGetManagers: ConnectionResult<InferSelectResult<OrgGetManagersRecordWithRelations, S>>;
|
|
36
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
37
|
+
/**
|
|
38
|
+
* Fetch OrgGetManagersRecord list without React hooks
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```ts
|
|
42
|
+
* const data = await fetchOrgGetManagersQuery({
|
|
43
|
+
* selection: {
|
|
44
|
+
* fields: { id: true },
|
|
45
|
+
* first: 10,
|
|
46
|
+
* },
|
|
47
|
+
* });
|
|
48
|
+
* ```
|
|
49
|
+
*/
|
|
50
|
+
export declare function fetchOrgGetManagersQuery<S extends OrgGetManagersRecordSelect>(params: {
|
|
51
|
+
selection: {
|
|
52
|
+
fields: S;
|
|
53
|
+
} & Omit<ListSelectionConfig<S, OrgGetManagersRecordFilter, OrgGetManagersRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetManagersRecordSelect>;
|
|
54
|
+
}): Promise<{
|
|
55
|
+
orgGetManagers: ConnectionResult<InferSelectResult<OrgGetManagersRecordWithRelations, S>>;
|
|
56
|
+
}>;
|
|
57
|
+
/**
|
|
58
|
+
* Prefetch OrgGetManagersRecord list for SSR or cache warming
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* ```ts
|
|
62
|
+
* await prefetchOrgGetManagersQuery(queryClient, { selection: { fields: { id: true }, first: 10 } });
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
export declare function prefetchOrgGetManagersQuery<S extends OrgGetManagersRecordSelect>(queryClient: QueryClient, params: {
|
|
66
|
+
selection: {
|
|
67
|
+
fields: S;
|
|
68
|
+
} & Omit<ListSelectionConfig<S, OrgGetManagersRecordFilter, OrgGetManagersRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetManagersRecordSelect>;
|
|
69
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* List query hook for OrgGetManagersRecord
|
|
4
|
+
* @generated by @constructive-io/graphql-codegen
|
|
5
|
+
* DO NOT EDIT - changes will be overwritten
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.orgGetManagersQueryKey = void 0;
|
|
9
|
+
exports.useOrgGetManagersQuery = useOrgGetManagersQuery;
|
|
10
|
+
exports.fetchOrgGetManagersQuery = fetchOrgGetManagersQuery;
|
|
11
|
+
exports.prefetchOrgGetManagersQuery = prefetchOrgGetManagersQuery;
|
|
12
|
+
const react_query_1 = require("@tanstack/react-query");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const selection_1 = require("../selection");
|
|
15
|
+
const query_keys_1 = require("../query-keys");
|
|
16
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
17
|
+
exports.orgGetManagersQueryKey = query_keys_1.orgGetManagersRecordKeys.list;
|
|
18
|
+
function useOrgGetManagersQuery(params) {
|
|
19
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
20
|
+
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
21
|
+
void _selection;
|
|
22
|
+
return (0, react_query_1.useQuery)({
|
|
23
|
+
queryKey: query_keys_1.orgGetManagersRecordKeys.list(args),
|
|
24
|
+
queryFn: () => (0, client_1.getClient)().orgGetManagersRecord.findMany(args).unwrap(),
|
|
25
|
+
...queryOptions,
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
async function fetchOrgGetManagersQuery(params) {
|
|
29
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
30
|
+
return (0, client_1.getClient)().orgGetManagersRecord.findMany(args).unwrap();
|
|
31
|
+
}
|
|
32
|
+
async function prefetchOrgGetManagersQuery(queryClient, params) {
|
|
33
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
34
|
+
await queryClient.prefetchQuery({
|
|
35
|
+
queryKey: query_keys_1.orgGetManagersRecordKeys.list(args),
|
|
36
|
+
queryFn: () => (0, client_1.getClient)().orgGetManagersRecord.findMany(args).unwrap(),
|
|
37
|
+
});
|
|
38
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* List query hook for OrgGetSubordinatesRecord
|
|
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 { OrgGetSubordinatesRecordSelect, OrgGetSubordinatesRecordWithRelations, OrgGetSubordinatesRecordFilter, OrgGetSubordinatesRecordsOrderBy } from '../../orm/input-types';
|
|
9
|
+
import type { InferSelectResult, ConnectionResult, HookStrictSelect } from '../../orm/select-types';
|
|
10
|
+
export type { OrgGetSubordinatesRecordSelect, OrgGetSubordinatesRecordWithRelations, OrgGetSubordinatesRecordFilter, OrgGetSubordinatesRecordsOrderBy, } from '../../orm/input-types';
|
|
11
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
12
|
+
export declare const orgGetSubordinatesQueryKey: (variables?: object) => readonly ["orggetsubordinatesrecord", "list", object];
|
|
13
|
+
/**
|
|
14
|
+
* Query hook for fetching OrgGetSubordinatesRecord list
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* const { data, isLoading } = useOrgGetSubordinatesQuery({
|
|
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 useOrgGetSubordinatesQuery<S extends OrgGetSubordinatesRecordSelect, TData = {
|
|
29
|
+
orgGetSubordinates: ConnectionResult<InferSelectResult<OrgGetSubordinatesRecordWithRelations, S>>;
|
|
30
|
+
}>(params: {
|
|
31
|
+
selection: {
|
|
32
|
+
fields: S;
|
|
33
|
+
} & Omit<ListSelectionConfig<S, OrgGetSubordinatesRecordFilter, OrgGetSubordinatesRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetSubordinatesRecordSelect>;
|
|
34
|
+
} & Omit<UseQueryOptions<{
|
|
35
|
+
orgGetSubordinates: ConnectionResult<InferSelectResult<OrgGetSubordinatesRecordWithRelations, S>>;
|
|
36
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
37
|
+
/**
|
|
38
|
+
* Fetch OrgGetSubordinatesRecord list without React hooks
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```ts
|
|
42
|
+
* const data = await fetchOrgGetSubordinatesQuery({
|
|
43
|
+
* selection: {
|
|
44
|
+
* fields: { id: true },
|
|
45
|
+
* first: 10,
|
|
46
|
+
* },
|
|
47
|
+
* });
|
|
48
|
+
* ```
|
|
49
|
+
*/
|
|
50
|
+
export declare function fetchOrgGetSubordinatesQuery<S extends OrgGetSubordinatesRecordSelect>(params: {
|
|
51
|
+
selection: {
|
|
52
|
+
fields: S;
|
|
53
|
+
} & Omit<ListSelectionConfig<S, OrgGetSubordinatesRecordFilter, OrgGetSubordinatesRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetSubordinatesRecordSelect>;
|
|
54
|
+
}): Promise<{
|
|
55
|
+
orgGetSubordinates: ConnectionResult<InferSelectResult<OrgGetSubordinatesRecordWithRelations, S>>;
|
|
56
|
+
}>;
|
|
57
|
+
/**
|
|
58
|
+
* Prefetch OrgGetSubordinatesRecord list for SSR or cache warming
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* ```ts
|
|
62
|
+
* await prefetchOrgGetSubordinatesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } });
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
export declare function prefetchOrgGetSubordinatesQuery<S extends OrgGetSubordinatesRecordSelect>(queryClient: QueryClient, params: {
|
|
66
|
+
selection: {
|
|
67
|
+
fields: S;
|
|
68
|
+
} & Omit<ListSelectionConfig<S, OrgGetSubordinatesRecordFilter, OrgGetSubordinatesRecordsOrderBy>, 'fields'> & HookStrictSelect<NoInfer<S>, OrgGetSubordinatesRecordSelect>;
|
|
69
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* List query hook for OrgGetSubordinatesRecord
|
|
4
|
+
* @generated by @constructive-io/graphql-codegen
|
|
5
|
+
* DO NOT EDIT - changes will be overwritten
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.orgGetSubordinatesQueryKey = void 0;
|
|
9
|
+
exports.useOrgGetSubordinatesQuery = useOrgGetSubordinatesQuery;
|
|
10
|
+
exports.fetchOrgGetSubordinatesQuery = fetchOrgGetSubordinatesQuery;
|
|
11
|
+
exports.prefetchOrgGetSubordinatesQuery = prefetchOrgGetSubordinatesQuery;
|
|
12
|
+
const react_query_1 = require("@tanstack/react-query");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const selection_1 = require("../selection");
|
|
15
|
+
const query_keys_1 = require("../query-keys");
|
|
16
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
17
|
+
exports.orgGetSubordinatesQueryKey = query_keys_1.orgGetSubordinatesRecordKeys.list;
|
|
18
|
+
function useOrgGetSubordinatesQuery(params) {
|
|
19
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
20
|
+
const { selection: _selection, ...queryOptions } = params ?? {};
|
|
21
|
+
void _selection;
|
|
22
|
+
return (0, react_query_1.useQuery)({
|
|
23
|
+
queryKey: query_keys_1.orgGetSubordinatesRecordKeys.list(args),
|
|
24
|
+
queryFn: () => (0, client_1.getClient)().orgGetSubordinatesRecord.findMany(args).unwrap(),
|
|
25
|
+
...queryOptions,
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
async function fetchOrgGetSubordinatesQuery(params) {
|
|
29
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
30
|
+
return (0, client_1.getClient)().orgGetSubordinatesRecord.findMany(args).unwrap();
|
|
31
|
+
}
|
|
32
|
+
async function prefetchOrgGetSubordinatesQuery(queryClient, params) {
|
|
33
|
+
const args = (0, selection_1.buildListSelectionArgs)(params.selection);
|
|
34
|
+
await queryClient.prefetchQuery({
|
|
35
|
+
queryKey: query_keys_1.orgGetSubordinatesRecordKeys.list(args),
|
|
36
|
+
queryFn: () => (0, client_1.getClient)().orgGetSubordinatesRecord.findMany(args).unwrap(),
|
|
37
|
+
});
|
|
38
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Custom query hook for orgIsManagerOf
|
|
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 { OrgIsManagerOfVariables } from '../../orm/query';
|
|
8
|
+
export type { OrgIsManagerOfVariables } from '../../orm/query';
|
|
9
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
10
|
+
export declare const orgIsManagerOfQueryKey: (variables?: object) => readonly ["orgIsManagerOf", object];
|
|
11
|
+
/**
|
|
12
|
+
* Query hook for orgIsManagerOf
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```tsx
|
|
16
|
+
* const { data, isLoading } = useOrgIsManagerOfQuery({ variables: { managerId, maxDepth, targetEntityId, userId } });
|
|
17
|
+
*
|
|
18
|
+
* if (data?.orgIsManagerOf) {
|
|
19
|
+
* console.log(data.orgIsManagerOf);
|
|
20
|
+
* }
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
export declare function useOrgIsManagerOfQuery<TData = {
|
|
24
|
+
orgIsManagerOf: boolean | null;
|
|
25
|
+
}>(params?: {
|
|
26
|
+
variables?: OrgIsManagerOfVariables;
|
|
27
|
+
} & Omit<UseQueryOptions<{
|
|
28
|
+
orgIsManagerOf: boolean | null;
|
|
29
|
+
}, Error, TData>, 'queryKey' | 'queryFn'>): UseQueryResult<TData>;
|
|
30
|
+
/**
|
|
31
|
+
* Fetch orgIsManagerOf without React hooks
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* const data = await fetchOrgIsManagerOfQuery({ variables: { managerId, maxDepth, targetEntityId, userId } });
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
export declare function fetchOrgIsManagerOfQuery(params?: {
|
|
39
|
+
variables?: OrgIsManagerOfVariables;
|
|
40
|
+
}): Promise<{
|
|
41
|
+
orgIsManagerOf: boolean | null;
|
|
42
|
+
}>;
|
|
43
|
+
/**
|
|
44
|
+
* Prefetch orgIsManagerOf for SSR or cache warming
|
|
45
|
+
*
|
|
46
|
+
* @example
|
|
47
|
+
* ```ts
|
|
48
|
+
* await prefetchOrgIsManagerOfQuery(queryClient, { variables: { managerId, maxDepth, targetEntityId, userId } });
|
|
49
|
+
* ```
|
|
50
|
+
*/
|
|
51
|
+
export declare function prefetchOrgIsManagerOfQuery(queryClient: QueryClient, params?: {
|
|
52
|
+
variables?: OrgIsManagerOfVariables;
|
|
53
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Custom query hook for orgIsManagerOf
|
|
4
|
+
* @generated by @constructive-io/graphql-codegen
|
|
5
|
+
* DO NOT EDIT - changes will be overwritten
|
|
6
|
+
*/
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.orgIsManagerOfQueryKey = void 0;
|
|
9
|
+
exports.useOrgIsManagerOfQuery = useOrgIsManagerOfQuery;
|
|
10
|
+
exports.fetchOrgIsManagerOfQuery = fetchOrgIsManagerOfQuery;
|
|
11
|
+
exports.prefetchOrgIsManagerOfQuery = prefetchOrgIsManagerOfQuery;
|
|
12
|
+
const react_query_1 = require("@tanstack/react-query");
|
|
13
|
+
const client_1 = require("../client");
|
|
14
|
+
const query_keys_1 = require("../query-keys");
|
|
15
|
+
/** Query key factory - re-exported from query-keys.ts */
|
|
16
|
+
exports.orgIsManagerOfQueryKey = query_keys_1.customQueryKeys.orgIsManagerOf;
|
|
17
|
+
function useOrgIsManagerOfQuery(params) {
|
|
18
|
+
const variables = params?.variables ?? {};
|
|
19
|
+
const { variables: _variables, ...queryOptions } = params ?? {};
|
|
20
|
+
void _variables;
|
|
21
|
+
return (0, react_query_1.useQuery)({
|
|
22
|
+
queryKey: (0, exports.orgIsManagerOfQueryKey)(variables),
|
|
23
|
+
queryFn: () => (0, client_1.getClient)().query.orgIsManagerOf(variables).unwrap(),
|
|
24
|
+
...queryOptions,
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Fetch orgIsManagerOf without React hooks
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* ```ts
|
|
32
|
+
* const data = await fetchOrgIsManagerOfQuery({ variables: { managerId, maxDepth, targetEntityId, userId } });
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
async function fetchOrgIsManagerOfQuery(params) {
|
|
36
|
+
const variables = params?.variables ?? {};
|
|
37
|
+
return (0, client_1.getClient)().query.orgIsManagerOf(variables).unwrap();
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Prefetch orgIsManagerOf for SSR or cache warming
|
|
41
|
+
*
|
|
42
|
+
* @example
|
|
43
|
+
* ```ts
|
|
44
|
+
* await prefetchOrgIsManagerOfQuery(queryClient, { variables: { managerId, maxDepth, targetEntityId, userId } });
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
async function prefetchOrgIsManagerOfQuery(queryClient, params) {
|
|
48
|
+
const variables = params?.variables ?? {};
|
|
49
|
+
await queryClient.prefetchQuery({
|
|
50
|
+
queryKey: (0, exports.orgIsManagerOfQueryKey)(variables),
|
|
51
|
+
queryFn: () => (0, client_1.getClient)().query.orgIsManagerOf(variables).unwrap(),
|
|
52
|
+
});
|
|
53
|
+
}
|
|
@@ -94,6 +94,20 @@ export declare const orgAdminGrantKeys: {
|
|
|
94
94
|
/** Detail query keys */ readonly details: () => readonly ["orgadmingrant", "detail"];
|
|
95
95
|
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgadmingrant", "detail", string | number];
|
|
96
96
|
};
|
|
97
|
+
export declare const orgChartEdgeKeys: {
|
|
98
|
+
/** All orgChartEdge queries */ readonly all: readonly ["orgchartedge"];
|
|
99
|
+
/** List query keys */ readonly lists: () => readonly ["orgchartedge", "list"];
|
|
100
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orgchartedge", "list", object];
|
|
101
|
+
/** Detail query keys */ readonly details: () => readonly ["orgchartedge", "detail"];
|
|
102
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgchartedge", "detail", string | number];
|
|
103
|
+
};
|
|
104
|
+
export declare const orgChartEdgeGrantKeys: {
|
|
105
|
+
/** All orgChartEdgeGrant queries */ readonly all: readonly ["orgchartedgegrant"];
|
|
106
|
+
/** List query keys */ readonly lists: () => readonly ["orgchartedgegrant", "list"];
|
|
107
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orgchartedgegrant", "list", object];
|
|
108
|
+
/** Detail query keys */ readonly details: () => readonly ["orgchartedgegrant", "detail"];
|
|
109
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgchartedgegrant", "detail", string | number];
|
|
110
|
+
};
|
|
97
111
|
export declare const orgClaimedInviteKeys: {
|
|
98
112
|
/** All orgClaimedInvite queries */ readonly all: readonly ["orgclaimedinvite"];
|
|
99
113
|
/** List query keys */ readonly lists: () => readonly ["orgclaimedinvite", "list"];
|
|
@@ -101,6 +115,20 @@ export declare const orgClaimedInviteKeys: {
|
|
|
101
115
|
/** Detail query keys */ readonly details: () => readonly ["orgclaimedinvite", "detail"];
|
|
102
116
|
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgclaimedinvite", "detail", string | number];
|
|
103
117
|
};
|
|
118
|
+
export declare const orgGetManagersRecordKeys: {
|
|
119
|
+
/** All orgGetManagersRecord queries */ readonly all: readonly ["orggetmanagersrecord"];
|
|
120
|
+
/** List query keys */ readonly lists: () => readonly ["orggetmanagersrecord", "list"];
|
|
121
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orggetmanagersrecord", "list", object];
|
|
122
|
+
/** Detail query keys */ readonly details: () => readonly ["orggetmanagersrecord", "detail"];
|
|
123
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orggetmanagersrecord", "detail", string | number];
|
|
124
|
+
};
|
|
125
|
+
export declare const orgGetSubordinatesRecordKeys: {
|
|
126
|
+
/** All orgGetSubordinatesRecord queries */ readonly all: readonly ["orggetsubordinatesrecord"];
|
|
127
|
+
/** List query keys */ readonly lists: () => readonly ["orggetsubordinatesrecord", "list"];
|
|
128
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orggetsubordinatesrecord", "list", object];
|
|
129
|
+
/** Detail query keys */ readonly details: () => readonly ["orggetsubordinatesrecord", "detail"];
|
|
130
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orggetsubordinatesrecord", "detail", string | number];
|
|
131
|
+
};
|
|
104
132
|
export declare const orgGrantKeys: {
|
|
105
133
|
/** All orgGrant queries */ readonly all: readonly ["orggrant"];
|
|
106
134
|
/** List query keys */ readonly lists: () => readonly ["orggrant", "list"];
|
|
@@ -190,6 +218,7 @@ export declare const customQueryKeys: {
|
|
|
190
218
|
/** Query key for appPermissionsGetMask */ readonly appPermissionsGetMask: (variables?: object) => readonly ["appPermissionsGetMask", object];
|
|
191
219
|
/** Query key for appPermissionsGetMaskByNames */ readonly appPermissionsGetMaskByNames: (variables?: object) => readonly ["appPermissionsGetMaskByNames", object];
|
|
192
220
|
/** Query key for appPermissionsGetPaddedMask */ readonly appPermissionsGetPaddedMask: (variables?: object) => readonly ["appPermissionsGetPaddedMask", object];
|
|
221
|
+
/** Query key for orgIsManagerOf */ readonly orgIsManagerOf: (variables?: object) => readonly ["orgIsManagerOf", object];
|
|
193
222
|
/** Query key for orgPermissionsGetByMask */ readonly orgPermissionsGetByMask: (variables?: object) => readonly ["orgPermissionsGetByMask", object];
|
|
194
223
|
/** Query key for orgPermissionsGetMask */ readonly orgPermissionsGetMask: (variables?: object) => readonly ["orgPermissionsGetMask", object];
|
|
195
224
|
/** Query key for orgPermissionsGetMaskByNames */ readonly orgPermissionsGetMaskByNames: (variables?: object) => readonly ["orgPermissionsGetMaskByNames", object];
|
|
@@ -309,6 +338,20 @@ export declare const queryKeys: {
|
|
|
309
338
|
/** Detail query keys */ readonly details: () => readonly ["orgadmingrant", "detail"];
|
|
310
339
|
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgadmingrant", "detail", string | number];
|
|
311
340
|
};
|
|
341
|
+
readonly orgChartEdge: {
|
|
342
|
+
/** All orgChartEdge queries */ readonly all: readonly ["orgchartedge"];
|
|
343
|
+
/** List query keys */ readonly lists: () => readonly ["orgchartedge", "list"];
|
|
344
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orgchartedge", "list", object];
|
|
345
|
+
/** Detail query keys */ readonly details: () => readonly ["orgchartedge", "detail"];
|
|
346
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgchartedge", "detail", string | number];
|
|
347
|
+
};
|
|
348
|
+
readonly orgChartEdgeGrant: {
|
|
349
|
+
/** All orgChartEdgeGrant queries */ readonly all: readonly ["orgchartedgegrant"];
|
|
350
|
+
/** List query keys */ readonly lists: () => readonly ["orgchartedgegrant", "list"];
|
|
351
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orgchartedgegrant", "list", object];
|
|
352
|
+
/** Detail query keys */ readonly details: () => readonly ["orgchartedgegrant", "detail"];
|
|
353
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgchartedgegrant", "detail", string | number];
|
|
354
|
+
};
|
|
312
355
|
readonly orgClaimedInvite: {
|
|
313
356
|
/** All orgClaimedInvite queries */ readonly all: readonly ["orgclaimedinvite"];
|
|
314
357
|
/** List query keys */ readonly lists: () => readonly ["orgclaimedinvite", "list"];
|
|
@@ -316,6 +359,20 @@ export declare const queryKeys: {
|
|
|
316
359
|
/** Detail query keys */ readonly details: () => readonly ["orgclaimedinvite", "detail"];
|
|
317
360
|
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orgclaimedinvite", "detail", string | number];
|
|
318
361
|
};
|
|
362
|
+
readonly orgGetManagersRecord: {
|
|
363
|
+
/** All orgGetManagersRecord queries */ readonly all: readonly ["orggetmanagersrecord"];
|
|
364
|
+
/** List query keys */ readonly lists: () => readonly ["orggetmanagersrecord", "list"];
|
|
365
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orggetmanagersrecord", "list", object];
|
|
366
|
+
/** Detail query keys */ readonly details: () => readonly ["orggetmanagersrecord", "detail"];
|
|
367
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orggetmanagersrecord", "detail", string | number];
|
|
368
|
+
};
|
|
369
|
+
readonly orgGetSubordinatesRecord: {
|
|
370
|
+
/** All orgGetSubordinatesRecord queries */ readonly all: readonly ["orggetsubordinatesrecord"];
|
|
371
|
+
/** List query keys */ readonly lists: () => readonly ["orggetsubordinatesrecord", "list"];
|
|
372
|
+
/** List query key with variables */ readonly list: (variables?: object) => readonly ["orggetsubordinatesrecord", "list", object];
|
|
373
|
+
/** Detail query keys */ readonly details: () => readonly ["orggetsubordinatesrecord", "detail"];
|
|
374
|
+
/** Detail query key for specific item */ readonly detail: (id: string | number) => readonly ["orggetsubordinatesrecord", "detail", string | number];
|
|
375
|
+
};
|
|
319
376
|
readonly orgGrant: {
|
|
320
377
|
/** All orgGrant queries */ readonly all: readonly ["orggrant"];
|
|
321
378
|
/** List query keys */ readonly lists: () => readonly ["orggrant", "list"];
|
|
@@ -405,6 +462,7 @@ export declare const queryKeys: {
|
|
|
405
462
|
/** Query key for appPermissionsGetMask */ readonly appPermissionsGetMask: (variables?: object) => readonly ["appPermissionsGetMask", object];
|
|
406
463
|
/** Query key for appPermissionsGetMaskByNames */ readonly appPermissionsGetMaskByNames: (variables?: object) => readonly ["appPermissionsGetMaskByNames", object];
|
|
407
464
|
/** Query key for appPermissionsGetPaddedMask */ readonly appPermissionsGetPaddedMask: (variables?: object) => readonly ["appPermissionsGetPaddedMask", object];
|
|
465
|
+
/** Query key for orgIsManagerOf */ readonly orgIsManagerOf: (variables?: object) => readonly ["orgIsManagerOf", object];
|
|
408
466
|
/** Query key for orgPermissionsGetByMask */ readonly orgPermissionsGetByMask: (variables?: object) => readonly ["orgPermissionsGetByMask", object];
|
|
409
467
|
/** Query key for orgPermissionsGetMask */ readonly orgPermissionsGetMask: (variables?: object) => readonly ["orgPermissionsGetMask", object];
|
|
410
468
|
/** Query key for orgPermissionsGetMaskByNames */ readonly orgPermissionsGetMaskByNames: (variables?: object) => readonly ["orgPermissionsGetMaskByNames", object];
|