@clxmedia/types 1.0.197 → 1.0.199
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/dist/core/tasks/index.d.ts +18 -44
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { CLiQUserLocator, CLiQUserLocatorSlug } from "../auth";
|
|
2
|
-
import { CLXFormRuleSet } from "../clxforms";
|
|
2
|
+
import type { CLXFormRuleSet } from "../clxforms";
|
|
3
3
|
import type { EnterpriseEventSlugs } from "../events";
|
|
4
4
|
export type CLXSortDirection = "asc" | "desc";
|
|
5
5
|
export type ISODateString = `${number}-${number}-${number}`;
|
|
@@ -10,7 +10,6 @@ export type CLXTaskFilter = {
|
|
|
10
10
|
master_id?: number;
|
|
11
11
|
include_closed?: boolean;
|
|
12
12
|
slug?: string;
|
|
13
|
-
awaiting_verification?: boolean;
|
|
14
13
|
take?: number;
|
|
15
14
|
skip?: number;
|
|
16
15
|
sort_by?: string;
|
|
@@ -22,7 +21,7 @@ export type PagedResult<T> = {
|
|
|
22
21
|
take: number;
|
|
23
22
|
skip: number;
|
|
24
23
|
};
|
|
25
|
-
export type CLXProjectActionType = "
|
|
24
|
+
export type CLXProjectActionType = "create" | "activate" | "complete" | "notify" | "archive";
|
|
26
25
|
export type CLXProjectStepInstance = {
|
|
27
26
|
id: number;
|
|
28
27
|
project_id: number;
|
|
@@ -50,7 +49,7 @@ export type CLXProjectInstance = {
|
|
|
50
49
|
archived_at: Date | null;
|
|
51
50
|
steps: CLXProjectStepInstance[];
|
|
52
51
|
};
|
|
53
|
-
export type CLXTaskActionType = "create" | "activate" | "assign" | "comment" | "notify" | "
|
|
52
|
+
export type CLXTaskActionType = "create" | "activate" | "assign" | "comment" | "notify" | "skip" | "complete";
|
|
54
53
|
export type CLXTaskTargetNone = {
|
|
55
54
|
type: "none";
|
|
56
55
|
};
|
|
@@ -145,57 +144,37 @@ export type TaskReminderConfig = {
|
|
|
145
144
|
schedule: TaskReminderScheduleEntry[];
|
|
146
145
|
};
|
|
147
146
|
export type TaskActivateReminderConfig = TaskReminderConfig & {
|
|
148
|
-
target_status: "activate";
|
|
149
147
|
origin_status: "create";
|
|
150
|
-
|
|
151
|
-
export type TaskStartReminderConfig = TaskReminderConfig & {
|
|
152
|
-
target_status: "start";
|
|
153
|
-
origin_status: "activate";
|
|
148
|
+
target_status: "activate";
|
|
154
149
|
};
|
|
155
150
|
export type TaskCompleteReminderConfig = TaskReminderConfig & {
|
|
151
|
+
origin_status: "activate";
|
|
156
152
|
target_status: "complete";
|
|
157
|
-
origin_status: "start";
|
|
158
|
-
};
|
|
159
|
-
export type TaskVerifyReminderConfig = TaskReminderConfig & {
|
|
160
|
-
target_status: "verify";
|
|
161
|
-
origin_status: "complete";
|
|
162
|
-
};
|
|
163
|
-
export type TaskCloseReminderConfig = TaskReminderConfig & {
|
|
164
|
-
target_status: "close";
|
|
165
|
-
origin_status: "verify";
|
|
166
153
|
};
|
|
167
154
|
export type TaskReminderScheduleConfig = {
|
|
168
155
|
activate?: TaskActivateReminderConfig;
|
|
169
|
-
start?: TaskStartReminderConfig;
|
|
170
156
|
complete?: TaskCompleteReminderConfig;
|
|
171
|
-
verify?: TaskVerifyReminderConfig;
|
|
172
|
-
close?: TaskCloseReminderConfig;
|
|
173
157
|
};
|
|
174
|
-
export type TaskReminderConfigTypes = TaskActivateReminderConfig |
|
|
175
|
-
export type ProjectReminderConfigTypes = ProjectActivateReminderConfig | ProjectCompleteReminderConfig
|
|
158
|
+
export type TaskReminderConfigTypes = TaskActivateReminderConfig | TaskCompleteReminderConfig;
|
|
159
|
+
export type ProjectReminderConfigTypes = ProjectActivateReminderConfig | ProjectCompleteReminderConfig;
|
|
176
160
|
export type ProjectActivateReminderConfig = ProjectReminderConfig & {
|
|
177
|
-
target_status: "activate";
|
|
178
161
|
origin_status: "create";
|
|
162
|
+
target_status: "activate";
|
|
179
163
|
};
|
|
180
164
|
export type ProjectCompleteReminderConfig = ProjectReminderConfig & {
|
|
181
|
-
target_status: "complete";
|
|
182
165
|
origin_status: "activate";
|
|
183
|
-
|
|
184
|
-
export type ProjectArchiveReminderConfig = ProjectReminderConfig & {
|
|
185
|
-
target_status: "archive";
|
|
186
|
-
origin_status: "complete";
|
|
166
|
+
target_status: "complete";
|
|
187
167
|
};
|
|
188
168
|
export type ProjectReminderScheduleConfig = {
|
|
189
169
|
activate?: ProjectActivateReminderConfig;
|
|
190
170
|
complete?: ProjectCompleteReminderConfig;
|
|
191
|
-
archive?: ProjectArchiveReminderConfig;
|
|
192
171
|
};
|
|
193
172
|
export type ProjectReminderConfig = {
|
|
194
173
|
origin_status: CLXProjectActionType;
|
|
195
174
|
template_slug: string;
|
|
196
175
|
schedule: ProjectReminderScheduleEntry[];
|
|
197
176
|
};
|
|
198
|
-
export type CLXPriority =
|
|
177
|
+
export type CLXPriority = number;
|
|
199
178
|
export type CLXTaskChecklistItem = {
|
|
200
179
|
guid: string;
|
|
201
180
|
description: string;
|
|
@@ -203,7 +182,6 @@ export type CLXTaskChecklistItem = {
|
|
|
203
182
|
is_done: boolean;
|
|
204
183
|
};
|
|
205
184
|
export type CLXTaskMetaData = {
|
|
206
|
-
verifier: CLiQUserLocator | null;
|
|
207
185
|
resource?: {
|
|
208
186
|
path: string;
|
|
209
187
|
label: string;
|
|
@@ -219,7 +197,7 @@ export type CLXTaskTriggerConstraint = "event_user_to_onboarding_recipient_match
|
|
|
219
197
|
export type CLXTaskTriggerConfig = {
|
|
220
198
|
constraints: CLXTaskTriggerConstraint[];
|
|
221
199
|
};
|
|
222
|
-
export type CLXTaskTriggerAction = "activate" | "
|
|
200
|
+
export type CLXTaskTriggerAction = "activate" | "skip" | "complete" | "require" | "optional" | "delete";
|
|
223
201
|
export type CLXTaskTrigger = {
|
|
224
202
|
trigger_slug: EnterpriseEventSlugs;
|
|
225
203
|
action_type: CLXTaskTriggerAction;
|
|
@@ -238,29 +216,31 @@ export type CLXTaskBase = {
|
|
|
238
216
|
export type CLXTaskResolution = "done" | "skipped" | "none";
|
|
239
217
|
export type CLXTaskTag = {
|
|
240
218
|
id: number;
|
|
219
|
+
task_id: number;
|
|
241
220
|
name: string;
|
|
221
|
+
added_by_user_id?: number;
|
|
222
|
+
comment?: string;
|
|
223
|
+
created_at: Date;
|
|
242
224
|
};
|
|
243
225
|
export type CLXTask = CLXTaskBase & {
|
|
244
226
|
id: number;
|
|
245
227
|
is_required: boolean;
|
|
246
228
|
conditions: CLXFormRuleSet | any;
|
|
247
229
|
project_step_id?: number;
|
|
248
|
-
updated_at?: Date;
|
|
249
|
-
requires_verification: boolean;
|
|
250
|
-
depends_on?: CLXTaskBase;
|
|
251
230
|
internal_only: boolean;
|
|
252
231
|
meta_data?: CLXTaskMetaData;
|
|
253
232
|
description?: string;
|
|
254
233
|
instructions?: string;
|
|
234
|
+
due_at: Date | null;
|
|
255
235
|
created_at: Date;
|
|
236
|
+
updated_at?: Date;
|
|
256
237
|
closed_at: Date | null;
|
|
257
238
|
master_id: number;
|
|
258
239
|
entity_name: string;
|
|
259
240
|
assignment: CLiQUserLocator | null;
|
|
260
241
|
target: CLXTaskTargetNone | CLXTaskTarget;
|
|
261
242
|
resolution: CLXTaskResolution;
|
|
262
|
-
|
|
263
|
-
priority: "low" | "medium" | "high";
|
|
243
|
+
priority: number;
|
|
264
244
|
tags: CLXTaskTag[];
|
|
265
245
|
};
|
|
266
246
|
export type CLXTaskHistoryEntry = {
|
|
@@ -277,10 +257,6 @@ export type CLXTaskHistoryEntry = {
|
|
|
277
257
|
};
|
|
278
258
|
export type CLXTaskWithStatus = CLXTask & {
|
|
279
259
|
activated_at: Date | null;
|
|
280
|
-
started_at: Date | null;
|
|
281
|
-
completed_at: Date | null;
|
|
282
|
-
verified_at: Date | null;
|
|
283
|
-
skipped_at: Date | null;
|
|
284
260
|
responsibility: "internal" | "external";
|
|
285
261
|
status: CLXTaskStatus;
|
|
286
262
|
};
|
|
@@ -311,9 +287,7 @@ export type TaskArchive = {
|
|
|
311
287
|
name: string;
|
|
312
288
|
created_at: Date;
|
|
313
289
|
is_required: boolean;
|
|
314
|
-
requires_verification: boolean;
|
|
315
290
|
activated_at: Date;
|
|
316
|
-
completed_at: Date;
|
|
317
291
|
closed_at: Date;
|
|
318
292
|
resolution: string;
|
|
319
293
|
history: TaskHistoryArchive[];
|