@jsb188/graphql 1.1.11 → 1.1.13
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/LICENSE +21 -0
- package/audience.d.ts +205 -0
- package/cache/config.ts +65 -28
- package/cache/index.helpers.ts +96 -0
- package/cache/index.ts +364 -808
- package/cache/mounted-queries.ts +33 -0
- package/cache/optimistic-ui-runtime.ts +46 -0
- package/cache/optimistic-ui.ts +401 -0
- package/cache/persist.ts +107 -22
- package/cache/realtime-fence.ts +47 -0
- package/cache/realtime-live.ts +17 -0
- package/cache/store.ts +22 -64
- package/cache/value.helpers.ts +17 -0
- package/{drafts/store.ts → client/draft-persistence-indexed-db.ts} +19 -3
- package/{drafts/index.ts → client/draft-persistence.ts} +13 -39
- package/client/index.ts +4 -2
- package/client/request.helpers.ts +14 -0
- package/client/request.ts +122 -232
- package/client/storage-asset.ts +58 -0
- package/gql/fragments/accountAuthFragments.ts +0 -4
- package/gql/fragments/agentMemoryFragments.ts +5 -1
- package/gql/fragments/agentNoteFragments.ts +156 -0
- package/gql/fragments/aiChatFragments.ts +35 -11
- package/gql/fragments/aiChatLinkFragments.ts +8 -0
- package/gql/fragments/audienceFragments.ts +76 -0
- package/gql/fragments/dataTableFragments.ts +48 -80
- package/gql/fragments/emailFragments.ts +49 -21
- package/gql/fragments/emailOutreachFragments.ts +281 -0
- package/gql/fragments/fieldDocFragments.ts +222 -40
- package/gql/fragments/inboundContactFragments.ts +2 -0
- package/gql/fragments/libraryFragments.ts +120 -0
- package/gql/fragments/logFragments.ts +93 -2
- package/gql/fragments/organizationFragments.ts +12 -0
- package/gql/fragments/qrCodeFragments.ts +29 -0
- package/gql/fragments/scheduleFragments.ts +574 -145
- package/gql/fragments/sheetFragments.ts +86 -424
- package/gql/fragments/storageFragments.ts +25 -1
- package/gql/fragments/workWaitFragments.ts +13 -0
- package/gql/fragments/workflowFragments.ts +32 -4
- package/gql/mutations/agentMemoryMutations.ts +32 -0
- package/gql/mutations/agentNoteMutations.ts +64 -0
- package/gql/mutations/aiChatLinkMutations.ts +13 -0
- package/gql/mutations/aiChatMutations.ts +34 -4
- package/gql/mutations/audienceMutations.ts +58 -0
- package/gql/mutations/authMutations.ts +24 -28
- package/gql/mutations/billingMutations.ts +24 -0
- package/gql/mutations/contactMutations.ts +23 -0
- package/gql/mutations/dataTableMutations.ts +18 -75
- package/gql/mutations/emailMutations.ts +22 -0
- package/gql/mutations/emailOutreachMutations.ts +139 -0
- package/gql/mutations/fieldDocMutations.ts +162 -13
- package/gql/mutations/index.ts +10 -5
- package/gql/mutations/organizationMutations.ts +6 -0
- package/gql/mutations/qrCodeMutations.ts +20 -0
- package/gql/mutations/scheduleMutations.ts +389 -417
- package/gql/mutations/sheetMutations.ts +62 -118
- package/gql/mutations/storageMutations.ts +1 -1
- package/gql/mutations/workflowMutations.ts +94 -0
- package/gql/queries/agentMemoryQueries.ts +12 -2
- package/gql/queries/agentNoteQueries.ts +86 -0
- package/gql/queries/aiChatQueries.ts +63 -12
- package/gql/queries/audienceQueries.ts +104 -0
- package/gql/queries/authQueries.ts +20 -4
- package/gql/queries/billingQueries.ts +114 -9
- package/gql/queries/dataTableQueries.ts +43 -75
- package/gql/queries/emailOutreachQueries.ts +282 -0
- package/gql/queries/emailQueries.ts +48 -64
- package/gql/queries/emailReplyReportQueries.ts +127 -0
- package/gql/queries/fieldDocQueries.ts +128 -98
- package/gql/queries/inboundContactQueries.ts +15 -4
- package/gql/queries/index.ts +5 -3
- package/gql/queries/libraryQueries.ts +112 -0
- package/gql/queries/logQueries.ts +86 -12
- package/gql/queries/organizationQueries.ts +44 -12
- package/gql/queries/qrCodeQueries.ts +27 -0
- package/gql/queries/scheduleQueries.ts +401 -278
- package/gql/queries/sheetQueries.ts +94 -165
- package/gql/queries/storageQueries.ts +11 -4
- package/gql/queries/workflowQueries.ts +61 -12
- package/gql/reactivity.ts +98 -0
- package/gql/recordReads.ts +171 -0
- package/hooks/index.helpers.ts +52 -0
- package/hooks/index.ts +920 -715
- package/hooks/use-agentMemory-mtn.ts +29 -31
- package/hooks/use-agentMemory-qry.ts +15 -3
- package/hooks/use-agentNote-mtn.ts +89 -0
- package/hooks/use-agentNote-qry.ts +162 -0
- package/hooks/use-agentNote-recovery.helpers.ts +58 -0
- package/hooks/use-agentNote-recovery.ts +57 -0
- package/hooks/use-aiChat-mtn.ts +104 -115
- package/hooks/use-aiChat-qry.helpers.ts +124 -0
- package/hooks/use-aiChat-qry.ts +254 -387
- package/hooks/use-aiChat-stream-mtn.ts +14 -0
- package/hooks/use-audience-mtn.ts +170 -0
- package/hooks/use-audience-qry.helpers.ts +39 -0
- package/hooks/use-audience-qry.ts +245 -0
- package/hooks/use-auth-mtn.ts +30 -1
- package/hooks/use-billing-mtn.ts +31 -0
- package/hooks/use-billing-qry.ts +76 -0
- package/hooks/use-dataTable-mtn.ts +23 -115
- package/hooks/use-dataTable-qry.ts +69 -914
- package/hooks/use-email-mtn.ts +26 -0
- package/hooks/use-email-qry.helpers.ts +37 -0
- package/hooks/use-email-qry.ts +44 -174
- package/hooks/use-emailOutreach-mtn.ts +211 -0
- package/hooks/use-emailOutreach-qry.helpers.ts +25 -0
- package/hooks/use-emailOutreach-qry.ts +367 -0
- package/hooks/use-emailOutreachReplyReport-qry.ts +46 -0
- package/hooks/use-fieldDoc-mtn.ts +244 -32
- package/hooks/use-fieldDoc-qry.helpers.ts +49 -0
- package/hooks/use-fieldDoc-qry.ts +134 -102
- package/hooks/use-inboundContact-qry.ts +7 -9
- package/hooks/use-library-qry.ts +233 -0
- package/hooks/use-log-mtn.ts +25 -12
- package/hooks/use-log-qry.ts +99 -46
- package/hooks/use-organization-qry.ts +16 -60
- package/hooks/use-qrCode-mtn.ts +40 -0
- package/hooks/use-qrCode-qry.ts +78 -0
- package/hooks/use-schedule-mtn.ts +231 -348
- package/hooks/use-schedule-qry.ts +208 -139
- package/hooks/use-schedule-reactive.ts +218 -0
- package/hooks/use-sheet-mtn.ts +91 -199
- package/hooks/use-sheet-qry.ts +88 -237
- package/hooks/use-storage-qry.ts +84 -61
- package/hooks/use-workflow-mtn.ts +84 -23
- package/hooks/use-workflow-qry.ts +60 -61
- package/libs/ai-chat-link-events.ts +78 -0
- package/libs/ai-chat-outgoing.helpers.ts +153 -0
- package/libs/ai-chat-outgoing.ts +11 -0
- package/libs/ai-chat-outgoing.types.ts +25 -0
- package/libs/ai-chat-run-realtime.ts +20 -0
- package/libs/ai-chat-submission-realtime.ts +150 -0
- package/libs/data-changes.helpers.ts +161 -0
- package/libs/data-changes.ts +382 -0
- package/libs/fragment-realtime-sequence.ts +55 -0
- package/libs/open-sheet.ts +138 -0
- package/libs/record-read.ts +327 -0
- package/libs/sheet-command-batch.ts +45 -0
- package/libs/sheet-realtime-packet.ts +53 -0
- package/libs/sheet-view-realtime-router.ts +99 -0
- package/loaders/emailPreference.ts +69 -0
- package/loaders/rest.ts +12 -0
- package/package.json +77 -25
- package/schedule.d.ts +1183 -0
- package/sse.helpers.ts +19 -0
- package/sse.ts +26 -115
- package/types.d.ts +48 -25
- package/cache/index.test.ts +0 -881
- package/client/data-table-realtime-subscriptions.test.ts +0 -740
- package/client/data-table-realtime-subscriptions.ts +0 -955
- package/client/data-table-realtime.test.ts +0 -792
- package/client/data-table-realtime.ts +0 -1218
- package/client/fragment-realtime-sequence.ts +0 -52
- package/client/open-sheet.ts +0 -137
- package/client/request-managed-session.test.ts +0 -574
- package/client/request-no-store.test.ts +0 -157
- package/client/sse-ticket.test.ts +0 -26
- package/deno.lock +0 -170
- package/deno.test.json +0 -10
- package/gql/fragments/agentDocFragments.ts +0 -46
- package/gql/fragments/billingFragments.ts +0 -14
- package/gql/fragments/campaignFragments.ts +0 -277
- package/gql/mutations/agentDocMutations.ts +0 -177
- package/gql/mutations/campaignMutations.ts +0 -215
- package/gql/queries/agentDocQueries.ts +0 -120
- package/gql/queries/appQueries.ts +0 -14
- package/gql/queries/campaignQueries.ts +0 -127
- package/hooks/use-agentDoc-mtn.ts +0 -285
- package/hooks/use-agentDoc-qry.ts +0 -208
- package/hooks/use-app-qry.ts +0 -22
- package/hooks/use-campaign-mtn.ts +0 -377
- package/hooks/use-campaign-qry.ts +0 -257
- package/loaders/campaign.ts +0 -137
- package/tsconfig.json +0 -13
|
@@ -1,315 +1,438 @@
|
|
|
1
1
|
import { gql } from 'graphql-tag';
|
|
2
2
|
import {
|
|
3
|
+
scheduleActivityAssignmentFragment,
|
|
4
|
+
scheduleActivityFragment,
|
|
5
|
+
scheduleBaselineActivityFragment,
|
|
6
|
+
scheduleBaselineFragment,
|
|
3
7
|
scheduleCalendarFragment,
|
|
4
|
-
|
|
5
|
-
|
|
8
|
+
scheduleCodeTypeFragment,
|
|
9
|
+
scheduleProjectFragment,
|
|
10
|
+
scheduleProjectRunFragment,
|
|
11
|
+
scheduleRelationshipFragment,
|
|
12
|
+
scheduleResourceCapacityFragment,
|
|
6
13
|
scheduleResourceFragment,
|
|
7
|
-
|
|
14
|
+
scheduleRoleFragment,
|
|
15
|
+
scheduleShiftFragment,
|
|
16
|
+
scheduleTaskFragment,
|
|
17
|
+
scheduleTimeOffFragment,
|
|
18
|
+
scheduleViolationFragment,
|
|
19
|
+
scheduleWbsNodeFragment,
|
|
20
|
+
scheduleWorkCalendarExceptionFragment,
|
|
21
|
+
scheduleWorkCalendarFragment,
|
|
8
22
|
} from '../fragments/scheduleFragments.ts';
|
|
23
|
+
import { live } from '../reactivity.ts';
|
|
9
24
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
25
|
+
export const scheduleWorkCalendarsQry = live(
|
|
26
|
+
gql`
|
|
27
|
+
query scheduleWorkCalendars($organizationId: GenericID!) {
|
|
28
|
+
scheduleWorkCalendars(organizationId: $organizationId) {
|
|
29
|
+
...scheduleWorkCalendarFragment
|
|
30
|
+
exceptions {
|
|
31
|
+
...scheduleWorkCalendarExceptionFragment
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
${scheduleWorkCalendarFragment}
|
|
36
|
+
${scheduleWorkCalendarExceptionFragment}
|
|
37
|
+
`,
|
|
38
|
+
{ refresh: 'auto', lists: ['scheduleWorkCalendar'], derived: ['scheduleWorkCalendar'] },
|
|
39
|
+
);
|
|
15
40
|
|
|
16
|
-
export const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
41
|
+
export const scheduleResourcesQry = live(
|
|
42
|
+
gql`
|
|
43
|
+
query scheduleResources($organizationId: GenericID!, $kinds: [ScheduleResourceKind!], $includeRetired: Boolean) {
|
|
44
|
+
scheduleResources(organizationId: $organizationId, kinds: $kinds, includeRetired: $includeRetired) {
|
|
45
|
+
...scheduleResourceFragment
|
|
46
|
+
viewerNotify {
|
|
47
|
+
channels
|
|
48
|
+
inherited
|
|
49
|
+
}
|
|
50
|
+
capacityPeriods {
|
|
51
|
+
...scheduleResourceCapacityFragment
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
${scheduleResourceFragment}
|
|
56
|
+
${scheduleResourceCapacityFragment}
|
|
57
|
+
`,
|
|
58
|
+
{ refresh: 'auto', lists: ['scheduleResource'], derived: ['scheduleResource'] },
|
|
59
|
+
);
|
|
26
60
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
61
|
+
export const scheduleCodeTypesQry = live(
|
|
62
|
+
gql`
|
|
63
|
+
query scheduleCodeTypes($organizationId: GenericID!, $projectId: GenericID) {
|
|
64
|
+
scheduleCodeTypes(organizationId: $organizationId, projectId: $projectId) {
|
|
65
|
+
...scheduleCodeTypeFragment
|
|
30
66
|
}
|
|
67
|
+
}
|
|
68
|
+
${scheduleCodeTypeFragment}
|
|
69
|
+
`,
|
|
70
|
+
{ refresh: 'auto', derived: ['scheduleCodeType', 'scheduleProject'] },
|
|
71
|
+
);
|
|
31
72
|
|
|
32
|
-
|
|
33
|
-
|
|
73
|
+
export const scheduleResourceUsageQry = live(
|
|
74
|
+
gql`
|
|
75
|
+
query scheduleResourceUsage($organizationId: GenericID!, $projectId: GenericID!, $resourceIds: [GenericID!], $from: String!, $to: String!) {
|
|
76
|
+
scheduleResourceUsage(organizationId: $organizationId, projectId: $projectId, resourceIds: $resourceIds, from: $from, to: $to) {
|
|
77
|
+
resourceId
|
|
78
|
+
date
|
|
79
|
+
demandUnits
|
|
80
|
+
externalUnits
|
|
81
|
+
availableUnits
|
|
82
|
+
overallocated
|
|
83
|
+
}
|
|
84
|
+
}
|
|
34
85
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
) {
|
|
39
|
-
scheduleCalendar (
|
|
40
|
-
calendarId: $calendarId
|
|
41
|
-
) {
|
|
42
|
-
...scheduleCalendarFragment
|
|
86
|
+
`,
|
|
87
|
+
{ refresh: 'auto', derived: ['scheduleProjectNetwork', 'scheduleProject'] },
|
|
88
|
+
);
|
|
43
89
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
90
|
+
export const scheduleCalendarsQry = live(
|
|
91
|
+
gql`
|
|
92
|
+
query scheduleCalendars($organizationId: GenericID!) {
|
|
93
|
+
scheduleCalendars(organizationId: $organizationId) {
|
|
94
|
+
...scheduleCalendarFragment
|
|
95
|
+
viewerPermission
|
|
96
|
+
viewerIsManager
|
|
97
|
+
viewerResourceId
|
|
98
|
+
}
|
|
47
99
|
}
|
|
48
|
-
|
|
49
100
|
${scheduleCalendarFragment}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
//
|
|
58
|
-
// It is deliberately per-calendar rather than taking a list: the reset key is
|
|
59
|
-
// an exact per-variable match, so one query per calendar lets an edit on one
|
|
60
|
-
// calendar leave every other overlaid calendar's cache untouched.
|
|
101
|
+
`,
|
|
102
|
+
{
|
|
103
|
+
refresh: 'auto',
|
|
104
|
+
lists: ['scheduleCalendar'],
|
|
105
|
+
derived: ['scheduleCalendarWindow', 'scheduleResource', 'scheduleWorkCalendar', 'scheduleTimeOff', 'scheduleRole'],
|
|
106
|
+
},
|
|
107
|
+
);
|
|
61
108
|
|
|
62
|
-
export const
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
$publishedOnly: Boolean
|
|
69
|
-
$mineOnly: Boolean
|
|
70
|
-
$limit: Int
|
|
71
|
-
) {
|
|
72
|
-
scheduleOccurrences (
|
|
73
|
-
organizationId: $organizationId
|
|
74
|
-
calendarId: $calendarId
|
|
75
|
-
from: $from
|
|
76
|
-
to: $to
|
|
77
|
-
publishedOnly: $publishedOnly
|
|
78
|
-
mineOnly: $mineOnly
|
|
79
|
-
limit: $limit
|
|
80
|
-
) {
|
|
81
|
-
...scheduleOccurrenceFragment
|
|
82
|
-
}
|
|
109
|
+
export const scheduleShiftsQry = live(
|
|
110
|
+
gql`
|
|
111
|
+
query scheduleShifts($organizationId: GenericID!, $calendarId: GenericID!, $fromDate: String!, $toDate: String!) {
|
|
112
|
+
scheduleShifts(organizationId: $organizationId, calendarId: $calendarId, fromDate: $fromDate, toDate: $toDate) {
|
|
113
|
+
shifts {
|
|
114
|
+
...scheduleShiftFragment
|
|
83
115
|
}
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
`;
|
|
87
|
-
|
|
88
|
-
export const scheduleOccurrenceQry = gql`
|
|
89
|
-
query scheduleOccurrence (
|
|
90
|
-
$occurrenceId: GenericID!
|
|
91
|
-
) {
|
|
92
|
-
scheduleOccurrence (
|
|
93
|
-
occurrenceId: $occurrenceId
|
|
94
|
-
) {
|
|
95
|
-
...scheduleOccurrenceFragment
|
|
96
|
-
}
|
|
116
|
+
roles {
|
|
117
|
+
...scheduleRoleFragment
|
|
97
118
|
}
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
`;
|
|
101
|
-
|
|
102
|
-
export const scheduleResourcesQry = gql`
|
|
103
|
-
query scheduleResources (
|
|
104
|
-
$organizationId: GenericID!
|
|
105
|
-
) {
|
|
106
|
-
scheduleResources (
|
|
107
|
-
organizationId: $organizationId
|
|
108
|
-
) {
|
|
109
|
-
...scheduleResourceFragment
|
|
110
|
-
}
|
|
119
|
+
locations {
|
|
120
|
+
...scheduleResourceFragment
|
|
111
121
|
}
|
|
112
|
-
|
|
122
|
+
people {
|
|
123
|
+
...scheduleResourceFragment
|
|
124
|
+
}
|
|
125
|
+
fromDate
|
|
126
|
+
toDate
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
${scheduleShiftFragment}
|
|
130
|
+
${scheduleRoleFragment}
|
|
113
131
|
${scheduleResourceFragment}
|
|
114
|
-
|
|
132
|
+
`,
|
|
133
|
+
{
|
|
134
|
+
refresh: 'auto',
|
|
135
|
+
derived: ['scheduleCalendarWindow', 'scheduleResource', 'scheduleWorkCalendar', 'scheduleTimeOff', 'scheduleRole'],
|
|
136
|
+
},
|
|
137
|
+
);
|
|
115
138
|
|
|
116
|
-
export const
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
139
|
+
export const scheduleMyShiftsQry = live(
|
|
140
|
+
gql`
|
|
141
|
+
query scheduleMyShifts($organizationId: GenericID!, $fromDate: String!, $toDate: String!) {
|
|
142
|
+
scheduleMyShifts(organizationId: $organizationId, fromDate: $fromDate, toDate: $toDate) {
|
|
143
|
+
shifts {
|
|
144
|
+
...scheduleShiftFragment
|
|
145
|
+
}
|
|
146
|
+
calendars {
|
|
147
|
+
...scheduleCalendarFragment
|
|
148
|
+
viewerPermission
|
|
149
|
+
viewerIsManager
|
|
150
|
+
viewerResourceId
|
|
151
|
+
}
|
|
152
|
+
roles {
|
|
153
|
+
...scheduleRoleFragment
|
|
154
|
+
}
|
|
155
|
+
locations {
|
|
156
|
+
...scheduleResourceFragment
|
|
157
|
+
viewerNotify {
|
|
158
|
+
channels
|
|
159
|
+
inherited
|
|
160
|
+
}
|
|
161
|
+
capacityPeriods {
|
|
162
|
+
...scheduleResourceCapacityFragment
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
me {
|
|
166
|
+
...scheduleResourceFragment
|
|
167
|
+
viewerNotify {
|
|
168
|
+
channels
|
|
169
|
+
inherited
|
|
127
170
|
}
|
|
171
|
+
capacityPeriods {
|
|
172
|
+
...scheduleResourceCapacityFragment
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
fromDate
|
|
176
|
+
toDate
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
${scheduleShiftFragment}
|
|
180
|
+
${scheduleCalendarFragment}
|
|
181
|
+
${scheduleRoleFragment}
|
|
182
|
+
${scheduleResourceFragment}
|
|
183
|
+
${scheduleResourceCapacityFragment}
|
|
184
|
+
`,
|
|
185
|
+
{
|
|
186
|
+
refresh: 'auto',
|
|
187
|
+
derived: [
|
|
188
|
+
'scheduleCalendarWindow',
|
|
189
|
+
'scheduleResource',
|
|
190
|
+
'scheduleWorkCalendar',
|
|
191
|
+
'scheduleTimeOff',
|
|
192
|
+
'scheduleRole',
|
|
193
|
+
'scheduleMyItems',
|
|
194
|
+
],
|
|
195
|
+
},
|
|
196
|
+
);
|
|
128
197
|
|
|
129
|
-
|
|
130
|
-
|
|
198
|
+
export const scheduleViolationsQry = live(
|
|
199
|
+
gql`
|
|
200
|
+
query scheduleViolations($organizationId: GenericID!, $calendarId: GenericID!, $fromDate: String!, $toDate: String!) {
|
|
201
|
+
scheduleViolations(organizationId: $organizationId, calendarId: $calendarId, fromDate: $fromDate, toDate: $toDate) {
|
|
202
|
+
...scheduleViolationFragment
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
${scheduleViolationFragment}
|
|
206
|
+
`,
|
|
207
|
+
{
|
|
208
|
+
refresh: 'auto',
|
|
209
|
+
derived: ['scheduleCalendarWindow', 'scheduleResource', 'scheduleWorkCalendar', 'scheduleTimeOff', 'scheduleRole'],
|
|
210
|
+
},
|
|
211
|
+
);
|
|
131
212
|
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
213
|
+
export const scheduleTimeOffListQry = live(
|
|
214
|
+
gql`
|
|
215
|
+
query scheduleTimeOffList($organizationId: GenericID!, $resourceIds: [GenericID!], $statuses: [ScheduleTimeOffStatus!], $mine: Boolean, $from: DateTime, $to: DateTime, $cursor: Cursor, $after: Boolean, $limit: Int) {
|
|
216
|
+
scheduleTimeOffList(organizationId: $organizationId, resourceIds: $resourceIds, statuses: $statuses, mine: $mine, from: $from, to: $to, cursor: $cursor, after: $after, limit: $limit) {
|
|
217
|
+
...scheduleTimeOffFragment
|
|
218
|
+
conflictingShifts {
|
|
219
|
+
...scheduleShiftFragment
|
|
220
|
+
}
|
|
221
|
+
releasedShiftIds
|
|
222
|
+
viewerIsRequester
|
|
223
|
+
viewerCanDecide
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
${scheduleTimeOffFragment}
|
|
227
|
+
${scheduleShiftFragment}
|
|
228
|
+
`,
|
|
229
|
+
{
|
|
230
|
+
refresh: 'auto',
|
|
231
|
+
derived: [
|
|
232
|
+
'scheduleCalendarWindow',
|
|
233
|
+
'scheduleResource',
|
|
234
|
+
'scheduleWorkCalendar',
|
|
235
|
+
'scheduleTimeOff',
|
|
236
|
+
'scheduleRole',
|
|
237
|
+
'scheduleMyItems',
|
|
238
|
+
],
|
|
239
|
+
},
|
|
240
|
+
);
|
|
137
241
|
|
|
138
|
-
export const
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
to: $to
|
|
150
|
-
) {
|
|
151
|
-
calendarId
|
|
152
|
-
windowStart
|
|
153
|
-
windowEnd
|
|
154
|
-
segmentCount
|
|
155
|
-
blockingCount
|
|
156
|
-
draftCount
|
|
242
|
+
export const scheduleTasksQry = live(
|
|
243
|
+
gql`
|
|
244
|
+
query scheduleTasks($organizationId: GenericID!, $calendarId: GenericID, $projectId: GenericID, $statuses: [ScheduleTaskStatus!]) {
|
|
245
|
+
scheduleTasks(organizationId: $organizationId, calendarId: $calendarId, projectId: $projectId, statuses: $statuses) {
|
|
246
|
+
...scheduleTaskFragment
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
${scheduleTaskFragment}
|
|
250
|
+
`,
|
|
251
|
+
{ refresh: 'auto', lists: ['scheduleTask'] },
|
|
252
|
+
);
|
|
157
253
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
detail
|
|
170
|
-
key
|
|
171
|
-
}
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
`;
|
|
254
|
+
export const scheduleMyTasksQry = live(
|
|
255
|
+
gql`
|
|
256
|
+
query scheduleMyTasks($organizationId: GenericID!, $statuses: [ScheduleTaskStatus!]) {
|
|
257
|
+
scheduleMyTasks(organizationId: $organizationId, statuses: $statuses) {
|
|
258
|
+
...scheduleTaskFragment
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
${scheduleTaskFragment}
|
|
262
|
+
`,
|
|
263
|
+
{ refresh: 'auto', lists: ['scheduleTask'] },
|
|
264
|
+
);
|
|
175
265
|
|
|
176
|
-
export const
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
effectiveFrom
|
|
195
|
-
effectiveTo
|
|
196
|
-
ordinal
|
|
197
|
-
version
|
|
198
|
-
createdAt
|
|
199
|
-
updatedAt
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
`;
|
|
266
|
+
export const scheduleProjectsQry = live(
|
|
267
|
+
gql`
|
|
268
|
+
query scheduleProjects($organizationId: GenericID!, $statuses: [ScheduleProjectStatus!], $includeArchived: Boolean, $search: String) {
|
|
269
|
+
scheduleProjects(organizationId: $organizationId, statuses: $statuses, includeArchived: $includeArchived, search: $search) {
|
|
270
|
+
...scheduleProjectFragment
|
|
271
|
+
activityCount
|
|
272
|
+
unreviewedCount
|
|
273
|
+
viewerPermission
|
|
274
|
+
viewerCanEdit
|
|
275
|
+
viewerCanEditAccess
|
|
276
|
+
viewerIsManager
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
${scheduleProjectFragment}
|
|
280
|
+
${scheduleProjectRunFragment}
|
|
281
|
+
`,
|
|
282
|
+
{ refresh: 'auto', lists: ['scheduleProject'], derived: ['scheduleProjectNetwork'] },
|
|
283
|
+
);
|
|
203
284
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
285
|
+
export const scheduleProjectNetworkQry = live(
|
|
286
|
+
gql`
|
|
287
|
+
query scheduleProjectNetwork($projectId: GenericID!, $filter: ScheduleNetworkFilter) {
|
|
288
|
+
scheduleProjectNetwork(projectId: $projectId, filter: $filter) {
|
|
289
|
+
project {
|
|
290
|
+
...scheduleProjectFragment
|
|
291
|
+
activityCount
|
|
292
|
+
unreviewedCount
|
|
293
|
+
viewerPermission
|
|
294
|
+
viewerCanEdit
|
|
295
|
+
viewerCanEditAccess
|
|
296
|
+
viewerIsManager
|
|
297
|
+
}
|
|
298
|
+
wbsNodes {
|
|
299
|
+
...scheduleWbsNodeFragment
|
|
300
|
+
}
|
|
301
|
+
activities {
|
|
302
|
+
...scheduleActivityFragment
|
|
303
|
+
}
|
|
304
|
+
relationships {
|
|
305
|
+
...scheduleRelationshipFragment
|
|
306
|
+
}
|
|
307
|
+
assignments {
|
|
308
|
+
...scheduleActivityAssignmentFragment
|
|
309
|
+
}
|
|
310
|
+
baselineActivities {
|
|
311
|
+
...scheduleBaselineActivityFragment
|
|
312
|
+
}
|
|
313
|
+
resources {
|
|
314
|
+
...scheduleResourceFragment
|
|
315
|
+
viewerNotify {
|
|
316
|
+
channels
|
|
317
|
+
inherited
|
|
318
|
+
}
|
|
319
|
+
capacityPeriods {
|
|
320
|
+
...scheduleResourceCapacityFragment
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
workCalendars {
|
|
324
|
+
...scheduleWorkCalendarFragment
|
|
325
|
+
exceptions {
|
|
326
|
+
...scheduleWorkCalendarExceptionFragment
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
networkRevision
|
|
330
|
+
totalActivityCount
|
|
331
|
+
filtered
|
|
332
|
+
truncated
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
${scheduleProjectFragment}
|
|
336
|
+
${scheduleProjectRunFragment}
|
|
337
|
+
${scheduleWbsNodeFragment}
|
|
338
|
+
${scheduleActivityFragment}
|
|
339
|
+
${scheduleRelationshipFragment}
|
|
340
|
+
${scheduleActivityAssignmentFragment}
|
|
341
|
+
${scheduleBaselineActivityFragment}
|
|
342
|
+
${scheduleResourceFragment}
|
|
343
|
+
${scheduleResourceCapacityFragment}
|
|
344
|
+
${scheduleWorkCalendarFragment}
|
|
345
|
+
${scheduleWorkCalendarExceptionFragment}
|
|
346
|
+
`,
|
|
347
|
+
{ refresh: 'auto', derived: ['scheduleProjectNetwork'] },
|
|
348
|
+
);
|
|
207
349
|
|
|
208
|
-
export const
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
) {
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
messageTemplate
|
|
220
|
-
defaultConfig
|
|
221
|
-
defaultSeverity
|
|
222
|
-
ordinal
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
`;
|
|
350
|
+
export const scheduleProjectRunsQry = live(
|
|
351
|
+
gql`
|
|
352
|
+
query scheduleProjectRuns($projectId: GenericID!, $cursor: Cursor, $after: Boolean, $limit: Int) {
|
|
353
|
+
scheduleProjectRuns(projectId: $projectId, cursor: $cursor, after: $after, limit: $limit) {
|
|
354
|
+
...scheduleProjectRunFragment
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
${scheduleProjectRunFragment}
|
|
358
|
+
`,
|
|
359
|
+
{ refresh: 'auto', lists: ['scheduleRun'], derived: ['scheduleProject'] },
|
|
360
|
+
);
|
|
226
361
|
|
|
227
|
-
export const
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
id
|
|
239
|
-
organizationId
|
|
240
|
-
resourceId
|
|
241
|
-
category
|
|
242
|
-
startAt
|
|
243
|
-
endAt
|
|
244
|
-
quantity
|
|
245
|
-
source
|
|
246
|
-
createdAt
|
|
247
|
-
updatedAt
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
`;
|
|
362
|
+
export const scheduleBaselinesQry = live(
|
|
363
|
+
gql`
|
|
364
|
+
query scheduleBaselines($projectId: GenericID!, $cursor: Cursor, $after: Boolean, $limit: Int) {
|
|
365
|
+
scheduleBaselines(projectId: $projectId, cursor: $cursor, after: $after, limit: $limit) {
|
|
366
|
+
...scheduleBaselineFragment
|
|
367
|
+
}
|
|
368
|
+
}
|
|
369
|
+
${scheduleBaselineFragment}
|
|
370
|
+
`,
|
|
371
|
+
{ refresh: 'auto', derived: ['scheduleBaseline', 'scheduleProject'] },
|
|
372
|
+
);
|
|
251
373
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
374
|
+
export const scheduleWorkCalendarQry = live(
|
|
375
|
+
gql`
|
|
376
|
+
query scheduleWorkCalendar($organizationId: GenericID!, $workCalendarId: GenericID!) {
|
|
377
|
+
scheduleWorkCalendar(organizationId: $organizationId, workCalendarId: $workCalendarId) {
|
|
378
|
+
...scheduleWorkCalendarFragment
|
|
379
|
+
exceptions {
|
|
380
|
+
...scheduleWorkCalendarExceptionFragment
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
${scheduleWorkCalendarFragment}
|
|
385
|
+
${scheduleWorkCalendarExceptionFragment}
|
|
386
|
+
`,
|
|
387
|
+
{ refresh: 'auto', derived: ['scheduleWorkCalendar'] },
|
|
388
|
+
);
|
|
256
389
|
|
|
257
|
-
export const
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
statuses: $statuses
|
|
270
|
-
mineOnly: $mineOnly
|
|
271
|
-
offeredToMe: $offeredToMe
|
|
272
|
-
limit: $limit
|
|
273
|
-
) {
|
|
274
|
-
...scheduleRequestFragment
|
|
275
|
-
}
|
|
390
|
+
export const scheduleResourceQry = live(
|
|
391
|
+
gql`
|
|
392
|
+
query scheduleResource($organizationId: GenericID!, $resourceId: GenericID!) {
|
|
393
|
+
scheduleResource(organizationId: $organizationId, resourceId: $resourceId) {
|
|
394
|
+
...scheduleResourceFragment
|
|
395
|
+
viewerNotify {
|
|
396
|
+
channels
|
|
397
|
+
inherited
|
|
398
|
+
}
|
|
399
|
+
capacityPeriods {
|
|
400
|
+
...scheduleResourceCapacityFragment
|
|
401
|
+
}
|
|
276
402
|
}
|
|
403
|
+
}
|
|
404
|
+
${scheduleResourceFragment}
|
|
405
|
+
${scheduleResourceCapacityFragment}
|
|
406
|
+
`,
|
|
407
|
+
{ refresh: 'auto', derived: ['scheduleResource'] },
|
|
408
|
+
);
|
|
277
409
|
|
|
278
|
-
|
|
279
|
-
|
|
410
|
+
// Revision probes (use-schedule-reactive.ts) read one counter with
|
|
411
|
+
// graphqlRequestNoStore. They never write the cache, so selecting only the id
|
|
412
|
+
// and the counter instead of the shared fragment leaves no partial records.
|
|
280
413
|
|
|
281
|
-
export const
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
organizationId: $organizationId
|
|
288
|
-
requestId: $requestId
|
|
289
|
-
) {
|
|
290
|
-
...scheduleRequestFragment
|
|
291
|
-
}
|
|
414
|
+
export const scheduleProjectRevisionQry = live(
|
|
415
|
+
gql`
|
|
416
|
+
query scheduleProjectRevision($projectId: GenericID!) {
|
|
417
|
+
scheduleProject(projectId: $projectId) {
|
|
418
|
+
id
|
|
419
|
+
networkRevision
|
|
292
420
|
}
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
`,
|
|
424
|
+
{ refresh: 'auto' },
|
|
425
|
+
);
|
|
293
426
|
|
|
294
|
-
|
|
295
|
-
|
|
427
|
+
export const scheduleCalendarRevisionQry = live(
|
|
428
|
+
gql`
|
|
429
|
+
query scheduleCalendarRevision($calendarId: GenericID!) {
|
|
430
|
+
scheduleCalendar(calendarId: $calendarId) {
|
|
431
|
+
id
|
|
432
|
+
revision
|
|
433
|
+
}
|
|
434
|
+
}
|
|
296
435
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
$requestId: GenericID!
|
|
301
|
-
) {
|
|
302
|
-
scheduleRequestEvents (
|
|
303
|
-
organizationId: $organizationId
|
|
304
|
-
requestId: $requestId
|
|
305
|
-
) {
|
|
306
|
-
id
|
|
307
|
-
requestId
|
|
308
|
-
fromStatus
|
|
309
|
-
toStatus
|
|
310
|
-
actorAccountId
|
|
311
|
-
detail
|
|
312
|
-
createdAt
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
`;
|
|
436
|
+
`,
|
|
437
|
+
{ refresh: 'auto' },
|
|
438
|
+
);
|