@jsb188/graphql 1.1.4 → 1.1.6
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/cache/config.ts +13 -7
- package/cache/index.ts +355 -144
- package/gql/fragments/accountAuthFragments.ts +3 -9
- package/gql/fragments/accountFragments.ts +11 -0
- package/gql/fragments/actionFragments.ts +16 -0
- package/gql/fragments/logFragments.ts +75 -6
- package/gql/fragments/organizationFragments.ts +70 -4
- package/gql/fragments/otherFragments.ts +10 -8
- package/gql/fragments/productFragments.ts +63 -0
- package/gql/fragments/reportFragments.ts +47 -0
- package/gql/mutations/accountMutations.ts +31 -0
- package/gql/mutations/aiChatMutations.ts +1 -0
- package/gql/mutations/authMutations.ts +80 -22
- package/gql/mutations/index.ts +8 -0
- package/gql/mutations/logMutations.ts +56 -1
- package/gql/mutations/organizationMutations.ts +42 -0
- package/gql/mutations/otherMutations.ts +0 -17
- package/gql/mutations/userAuthMutations.ts +0 -116
- package/gql/queries/aiChatQueries.ts +4 -0
- package/gql/queries/appQueries.ts +2 -1
- package/gql/queries/index.ts +6 -0
- package/gql/queries/logQueries.ts +60 -11
- package/gql/queries/organizationQueries.ts +62 -1
- package/gql/queries/productQueries.ts +70 -0
- package/gql/queries/reportQueries.ts +60 -0
- package/hooks/index.ts +259 -113
- package/hooks/use-account-mtn.ts +68 -0
- package/hooks/use-aiChat-mtn.ts +112 -0
- package/hooks/use-aiChat-qry.ts +81 -10
- package/hooks/use-auth-mtn.ts +114 -63
- package/hooks/use-log-mtn.ts +85 -0
- package/hooks/use-log-qry.ts +71 -18
- package/hooks/use-organization-mtn.ts +105 -0
- package/hooks/use-organization-qry.ts +119 -15
- package/hooks/use-product-qry.ts +109 -0
- package/hooks/use-report-qry.ts +69 -0
- package/package.json +15 -25
- package/sse.ts +11 -0
- package/types.d.ts +1 -0
- package/gql/fragments/cardFragments.ts +0 -15
- package/gql/fragments/chatFragments.ts +0 -98
- package/gql/fragments/userAuthFragments.ts +0 -8
- package/gql/fragments/userFragments.ts +0 -69
- package/gql/mutations/chatMutations.ts +0 -116
- package/gql/mutations/userMutations.ts +0 -89
- package/gql/queries/cardQueries.ts +0 -24
- package/gql/queries/chatQueries.ts +0 -86
- package/gql/queries/otherQueries.ts +0 -12
- package/gql/queries/userQueries.ts +0 -104
package/cache/config.ts
CHANGED
|
@@ -19,18 +19,26 @@ export const RULES = {
|
|
|
19
19
|
// List of queries that should be cached
|
|
20
20
|
// NOTE: Fragments are always cached
|
|
21
21
|
aiChat: true,
|
|
22
|
+
aiChats: true,
|
|
22
23
|
aiChatMessages: true,
|
|
23
24
|
alerts: true,
|
|
24
|
-
cardsForUser: true,
|
|
25
25
|
chat: true,
|
|
26
26
|
chatsList: true,
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
childOrganizations: true,
|
|
28
|
+
eventsList: true,
|
|
29
|
+
eventAttendanceList: true,
|
|
30
|
+
parentOrganization: true,
|
|
31
31
|
logEntries: true,
|
|
32
|
+
logEvidences: true,
|
|
32
33
|
myChats: true,
|
|
34
|
+
myOrganizations: true,
|
|
35
|
+
organizationRelationship: true,
|
|
36
|
+
organizationWorkflows: true,
|
|
33
37
|
platformProducts: true,
|
|
38
|
+
productAttendanceList: true,
|
|
39
|
+
productsList: true,
|
|
40
|
+
reports: true,
|
|
41
|
+
availableReports: true,
|
|
34
42
|
searchUsers: true,
|
|
35
43
|
updateNote: true,
|
|
36
44
|
userIdToChatId: true,
|
|
@@ -38,7 +46,6 @@ export const RULES = {
|
|
|
38
46
|
// All fragments are cached,
|
|
39
47
|
// but if you want to skip some, add it here
|
|
40
48
|
accountAuthFragment: false,
|
|
41
|
-
userAuthFragment: false,
|
|
42
49
|
} as {
|
|
43
50
|
__limit: number;
|
|
44
51
|
[key: string]: boolean | number;
|
|
@@ -48,5 +55,4 @@ export const PARTIALS_MAP = {
|
|
|
48
55
|
// Partial fragments are supported if you map them to its original fragment name
|
|
49
56
|
chatPartial: 'chatFragment',
|
|
50
57
|
chatStatusPartial: 'chatFragment',
|
|
51
|
-
userPartial: 'userFragment',
|
|
52
58
|
} as Record<string, string>;
|