mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
refactor: Format nodes-base package (A-F) (#3800)
* 🔨 prettier formated nodes - A * 🔨 prettier formated nodes - B * ⚡ prettier formated nodes - C * ⚡ prettier formated nodes - D * ⚡ prettier formated nodes - E-F * 🎨 Adjust nodes-base formatting command (#3805) * Format additional files in nodes A-F (#3811) * ⚡ fixes * 🎨 Add Mindee to ignored dirs Co-authored-by: Iván Ovejero <ivov.src@gmail.com>
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const checklistOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const checklistOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -40,7 +36,6 @@ export const checklistOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const checklistFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* checklist:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -51,12 +46,8 @@ export const checklistFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -68,12 +59,8 @@ export const checklistFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -88,12 +75,8 @@ export const checklistFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -108,12 +91,8 @@ export const checklistFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -126,12 +105,8 @@ export const checklistFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklist',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['checklist'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const checklistItemOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const checklistItemOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -40,7 +36,6 @@ export const checklistItemOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const checklistItemFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* checklistItem:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -51,12 +46,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -68,12 +59,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -86,12 +73,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -114,12 +97,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -131,12 +110,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -152,12 +127,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -169,12 +140,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -187,12 +154,8 @@ export const checklistItemFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'checklistItem',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['checklistItem'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
IExecuteFunctions,
|
||||
} from 'n8n-core';
|
||||
import { IExecuteFunctions } from 'n8n-core';
|
||||
|
||||
import {
|
||||
IDataObject,
|
||||
@@ -12,94 +10,44 @@ import {
|
||||
NodeOperationError,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import {
|
||||
clickupApiRequest,
|
||||
clickupApiRequestAllItems,
|
||||
validateJSON,
|
||||
} from './GenericFunctions';
|
||||
import { clickupApiRequest, clickupApiRequestAllItems, validateJSON } from './GenericFunctions';
|
||||
|
||||
import {
|
||||
checklistFields,
|
||||
checklistOperations,
|
||||
} from './ChecklistDescription';
|
||||
import { checklistFields, checklistOperations } from './ChecklistDescription';
|
||||
|
||||
import {
|
||||
checklistItemFields,
|
||||
checklistItemOperations,
|
||||
} from './ChecklistItemDescription';
|
||||
import { checklistItemFields, checklistItemOperations } from './ChecklistItemDescription';
|
||||
|
||||
import {
|
||||
commentFields,
|
||||
commentOperations,
|
||||
} from './CommentDescription';
|
||||
import { commentFields, commentOperations } from './CommentDescription';
|
||||
|
||||
import {
|
||||
folderFields,
|
||||
folderOperations,
|
||||
} from './FolderDescription';
|
||||
import { folderFields, folderOperations } from './FolderDescription';
|
||||
|
||||
import {
|
||||
goalFields,
|
||||
goalOperations,
|
||||
} from './GoalDescription';
|
||||
import { goalFields, goalOperations } from './GoalDescription';
|
||||
|
||||
import {
|
||||
goalKeyResultFields,
|
||||
goalKeyResultOperations,
|
||||
} from './GoalKeyResultDescription';
|
||||
import { goalKeyResultFields, goalKeyResultOperations } from './GoalKeyResultDescription';
|
||||
|
||||
// import {
|
||||
// guestFields,
|
||||
// guestOperations,
|
||||
// } from './guestDescription';
|
||||
|
||||
import {
|
||||
taskFields,
|
||||
taskOperations,
|
||||
} from './TaskDescription';
|
||||
import { taskFields, taskOperations } from './TaskDescription';
|
||||
|
||||
import {
|
||||
taskListFields,
|
||||
taskListOperations,
|
||||
} from './TaskListDescription';
|
||||
import { taskListFields, taskListOperations } from './TaskListDescription';
|
||||
|
||||
import {
|
||||
taskTagFields,
|
||||
taskTagOperations,
|
||||
} from './TaskTagDescription';
|
||||
import { taskTagFields, taskTagOperations } from './TaskTagDescription';
|
||||
|
||||
import {
|
||||
spaceTagFields,
|
||||
spaceTagOperations,
|
||||
} from './SpaceTagDescription';
|
||||
import { spaceTagFields, spaceTagOperations } from './SpaceTagDescription';
|
||||
|
||||
import {
|
||||
taskDependencyFields,
|
||||
taskDependencyOperations,
|
||||
} from './TaskDependencyDescription';
|
||||
import { taskDependencyFields, taskDependencyOperations } from './TaskDependencyDescription';
|
||||
|
||||
import {
|
||||
timeEntryFields,
|
||||
timeEntryOperations,
|
||||
} from './TimeEntryDescription';
|
||||
import { timeEntryFields, timeEntryOperations } from './TimeEntryDescription';
|
||||
|
||||
import {
|
||||
timeEntryTagFields,
|
||||
timeEntryTagOperations,
|
||||
} from './TimeEntryTagDescription';
|
||||
import { timeEntryTagFields, timeEntryTagOperations } from './TimeEntryTagDescription';
|
||||
|
||||
import {
|
||||
listFields,
|
||||
listOperations,
|
||||
} from './ListDescription';
|
||||
import { listFields, listOperations } from './ListDescription';
|
||||
|
||||
import {
|
||||
ITask,
|
||||
} from './TaskInterface';
|
||||
import { ITask } from './TaskInterface';
|
||||
|
||||
import {
|
||||
IList,
|
||||
} from './ListInterface';
|
||||
import { IList } from './ListInterface';
|
||||
|
||||
import moment from 'moment-timezone';
|
||||
|
||||
@@ -123,9 +71,7 @@ export class ClickUp implements INodeType {
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
authentication: [
|
||||
'accessToken',
|
||||
],
|
||||
authentication: ['accessToken'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -134,9 +80,7 @@ export class ClickUp implements INodeType {
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
authentication: [
|
||||
'oAuth2',
|
||||
],
|
||||
authentication: ['oAuth2'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -366,8 +310,7 @@ export class ClickUp implements INodeType {
|
||||
let url: string;
|
||||
if (listId) {
|
||||
url = `/list/${listId}/member`;
|
||||
}
|
||||
else if (taskId) {
|
||||
} else if (taskId) {
|
||||
url = `/task/${taskId}/member`;
|
||||
} else {
|
||||
return returnData;
|
||||
@@ -405,7 +348,11 @@ export class ClickUp implements INodeType {
|
||||
async getTimeEntryTags(this: ILoadOptionsFunctions): Promise<INodePropertyOptions[]> {
|
||||
const teamId = this.getCurrentNodeParameter('team') as string;
|
||||
const returnData: INodePropertyOptions[] = [];
|
||||
const { data: tags } = await clickupApiRequest.call(this, 'GET', `/team/${teamId}/time_entries/tags`);
|
||||
const { data: tags } = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/team/${teamId}/time_entries/tags`,
|
||||
);
|
||||
for (const tag of tags) {
|
||||
const tagName = tag.name;
|
||||
const tagId = JSON.stringify(tag);
|
||||
@@ -456,7 +403,11 @@ export class ClickUp implements INodeType {
|
||||
const listId = this.getCurrentNodeParameter('list') as string;
|
||||
const archived = this.getCurrentNodeParameter('archived') as string;
|
||||
const returnData: INodePropertyOptions[] = [];
|
||||
const { tasks } = await clickupApiRequest.call(this, 'GET', `/list/${listId}/task?archived=${archived}`);
|
||||
const { tasks } = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/list/${listId}/task?archived=${archived}`,
|
||||
);
|
||||
for (const task of tasks) {
|
||||
const taskName = task.name;
|
||||
const taskId = task.id;
|
||||
@@ -489,12 +440,21 @@ export class ClickUp implements INodeType {
|
||||
const body: IDataObject = {
|
||||
name,
|
||||
};
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/task/${taskId}/checklist`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/task/${taskId}/checklist`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.checklist;
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const checklistId = this.getNodeParameter('checklist', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/checklist/${checklistId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/checklist/${checklistId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'update') {
|
||||
@@ -507,7 +467,12 @@ export class ClickUp implements INodeType {
|
||||
if (updateFields.position) {
|
||||
body.position = updateFields.position as number;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/checklist/${checklistId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'PUT',
|
||||
`/checklist/${checklistId}`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.checklist;
|
||||
}
|
||||
}
|
||||
@@ -522,13 +487,22 @@ export class ClickUp implements INodeType {
|
||||
if (additionalFields.assignee) {
|
||||
body.assignee = parseInt(additionalFields.assignee as string, 10);
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/checklist/${checklistId}/checklist_item`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/checklist/${checklistId}/checklist_item`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.checklist;
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const checklistId = this.getNodeParameter('checklist', i) as string;
|
||||
const checklistItemId = this.getNodeParameter('checklistItem', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/checklist/${checklistId}/checklist_item/${checklistItemId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/checklist/${checklistId}/checklist_item/${checklistItemId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'update') {
|
||||
@@ -548,7 +522,12 @@ export class ClickUp implements INodeType {
|
||||
if (updateFields.resolved) {
|
||||
body.resolved = updateFields.resolved as boolean;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/checklist/${checklistId}/checklist_item/${checklistItemId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'PUT',
|
||||
`/checklist/${checklistId}/checklist_item/${checklistItemId}`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.checklist;
|
||||
}
|
||||
}
|
||||
@@ -567,7 +546,12 @@ export class ClickUp implements INodeType {
|
||||
if (additionalFields.notifyAll) {
|
||||
body.notify_all = additionalFields.notifyAll as boolean;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/${resource}/${id}/comment`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/${resource}/${id}/comment`,
|
||||
body,
|
||||
);
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const commentId = this.getNodeParameter('comment', i) as string;
|
||||
@@ -578,7 +562,13 @@ export class ClickUp implements INodeType {
|
||||
const resource = this.getNodeParameter('commentsOn', i) as string;
|
||||
const id = this.getNodeParameter('id', i) as string;
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/${resource}/${id}/comment`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/${resource}/${id}/comment`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.comments;
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
}
|
||||
@@ -606,7 +596,12 @@ export class ClickUp implements INodeType {
|
||||
const body: IDataObject = {
|
||||
name,
|
||||
};
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/space/${spaceId}/folder`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/space/${spaceId}/folder`,
|
||||
body,
|
||||
);
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const folderId = this.getNodeParameter('folder', i) as string;
|
||||
@@ -624,7 +619,13 @@ export class ClickUp implements INodeType {
|
||||
qs.archived = filters.archived as boolean;
|
||||
}
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/space/${spaceId}/folder`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/space/${spaceId}/folder`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.folders;
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
}
|
||||
@@ -659,7 +660,9 @@ export class ClickUp implements INodeType {
|
||||
body.color = additionalFields.color as string;
|
||||
}
|
||||
if (additionalFields.owners) {
|
||||
body.owners = ((additionalFields.owners as string).split(',') as string[]).map((e: string) => parseInt(e, 10));
|
||||
body.owners = ((additionalFields.owners as string).split(',') as string[]).map(
|
||||
(e: string) => parseInt(e, 10),
|
||||
);
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/goal`, body);
|
||||
responseData = responseData.goal;
|
||||
@@ -677,10 +680,15 @@ export class ClickUp implements INodeType {
|
||||
if (operation === 'getAll') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/team/${teamId}/goal`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/team/${teamId}/goal`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.goals;
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
|
||||
}
|
||||
if (operation === 'update') {
|
||||
const goalId = this.getNodeParameter('goal', i) as string;
|
||||
@@ -699,10 +707,14 @@ export class ClickUp implements INodeType {
|
||||
body.color = updateFields.color as string;
|
||||
}
|
||||
if (updateFields.addOwners) {
|
||||
body.add_owners = ((updateFields.addOwners as string).split(',') as string[]).map((e: string) => parseInt(e, 10)) as number[];
|
||||
body.add_owners = ((updateFields.addOwners as string).split(',') as string[]).map(
|
||||
(e: string) => parseInt(e, 10),
|
||||
) as number[];
|
||||
}
|
||||
if (updateFields.removeOwners) {
|
||||
body.rem_owners = ((updateFields.removeOwners as string).split(',') as string[]).map((e: string) => parseInt(e, 10)) as number[];
|
||||
body.rem_owners = ((updateFields.removeOwners as string).split(',') as string[]).map(
|
||||
(e: string) => parseInt(e, 10),
|
||||
) as number[];
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/goal/${goalId}`, body);
|
||||
responseData = responseData.goal;
|
||||
@@ -720,14 +732,26 @@ export class ClickUp implements INodeType {
|
||||
};
|
||||
if (type === 'number' || type === 'currency') {
|
||||
if (!additionalFields.unit) {
|
||||
throw new NodeOperationError(this.getNode(), 'Unit field must be set', { itemIndex: i });
|
||||
throw new NodeOperationError(this.getNode(), 'Unit field must be set', {
|
||||
itemIndex: i,
|
||||
});
|
||||
}
|
||||
}
|
||||
if (type === 'number' || type === 'percentaje'
|
||||
|| type === 'automatic' || type === 'currency') {
|
||||
if (additionalFields.stepsStart === undefined
|
||||
|| !additionalFields.stepsEnd === undefined) {
|
||||
throw new NodeOperationError(this.getNode(), 'Steps start and steps end fields must be set', { itemIndex: i });
|
||||
if (
|
||||
type === 'number' ||
|
||||
type === 'percentaje' ||
|
||||
type === 'automatic' ||
|
||||
type === 'currency'
|
||||
) {
|
||||
if (
|
||||
additionalFields.stepsStart === undefined ||
|
||||
!additionalFields.stepsEnd === undefined
|
||||
) {
|
||||
throw new NodeOperationError(
|
||||
this.getNode(),
|
||||
'Steps start and steps end fields must be set',
|
||||
{ itemIndex: i },
|
||||
);
|
||||
}
|
||||
}
|
||||
if (additionalFields.unit) {
|
||||
@@ -746,14 +770,25 @@ export class ClickUp implements INodeType {
|
||||
body.list_ids = (additionalFields.listIds as string).split(',');
|
||||
}
|
||||
if (additionalFields.owners) {
|
||||
body.owners = ((additionalFields.owners as string).split(',') as string[]).map((e: string) => parseInt(e, 10));
|
||||
body.owners = ((additionalFields.owners as string).split(',') as string[]).map(
|
||||
(e: string) => parseInt(e, 10),
|
||||
);
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/goal/${goalId}/key_result`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/goal/${goalId}/key_result`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.key_result;
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const keyResultId = this.getNodeParameter('keyResult', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/key_result/${keyResultId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/key_result/${keyResultId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'update') {
|
||||
@@ -778,7 +813,12 @@ export class ClickUp implements INodeType {
|
||||
if (updateFields.unit) {
|
||||
body.unit = updateFields.unit as string;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/key_result/${keyResultId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'PUT',
|
||||
`/key_result/${keyResultId}`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.key_result;
|
||||
}
|
||||
}
|
||||
@@ -799,19 +839,32 @@ export class ClickUp implements INodeType {
|
||||
if (additionalFields.canSeeTimeEstimated) {
|
||||
body.can_see_time_estimated = additionalFields.canSeeTimeEstimated as boolean;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/guest`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/team/${teamId}/guest`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.team;
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
const guestId = this.getNodeParameter('guest', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/team/${teamId}/guest/${guestId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/team/${teamId}/guest/${guestId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'get') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
const guestId = this.getNodeParameter('guest', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/team/${teamId}/guest/${guestId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/team/${teamId}/guest/${guestId}`,
|
||||
);
|
||||
responseData = responseData.team;
|
||||
}
|
||||
if (operation === 'update') {
|
||||
@@ -831,7 +884,12 @@ export class ClickUp implements INodeType {
|
||||
if (updateFields.canSeeTimeEstimated) {
|
||||
body.can_see_time_estimated = updateFields.canSeeTimeEstimated as boolean;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/team/${teamId}/guest/${guestId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'PUT',
|
||||
`/team/${teamId}/guest/${guestId}`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.team;
|
||||
}
|
||||
}
|
||||
@@ -846,7 +904,9 @@ export class ClickUp implements INodeType {
|
||||
if (additionalFields.customFieldsJson) {
|
||||
const customFields = validateJSON(additionalFields.customFieldsJson as string);
|
||||
if (customFields === undefined) {
|
||||
throw new NodeOperationError(this.getNode(), 'Custom Fields: Invalid JSON', { itemIndex: i });
|
||||
throw new NodeOperationError(this.getNode(), 'Custom Fields: Invalid JSON', {
|
||||
itemIndex: i,
|
||||
});
|
||||
}
|
||||
body.custom_fields = customFields;
|
||||
}
|
||||
@@ -933,11 +993,15 @@ export class ClickUp implements INodeType {
|
||||
}
|
||||
if (updateFields.addAssignees) {
|
||||
//@ts-ignore
|
||||
body.assignees.add = ((updateFields.addAssignees as string).split(',') as string[]).map((e: string) => parseInt(e, 10));
|
||||
body.assignees.add = (
|
||||
(updateFields.addAssignees as string).split(',') as string[]
|
||||
).map((e: string) => parseInt(e, 10));
|
||||
}
|
||||
if (updateFields.removeAssignees) {
|
||||
//@ts-ignore
|
||||
body.assignees.rem = ((updateFields.removeAssignees as string).split(',') as string[]).map((e: string) => parseInt(e, 10));
|
||||
body.assignees.rem = (
|
||||
(updateFields.removeAssignees as string).split(',') as string[]
|
||||
).map((e: string) => parseInt(e, 10));
|
||||
}
|
||||
if (updateFields.status) {
|
||||
body.status = updateFields.status as string;
|
||||
@@ -995,13 +1059,15 @@ export class ClickUp implements INodeType {
|
||||
qs.date_updated_lt = new Date(filters.dateUpdatedLt as string).getTime();
|
||||
}
|
||||
if (filters.customFieldsUi) {
|
||||
const customFieldsValues = (filters.customFieldsUi as IDataObject).customFieldsValues as IDataObject[];
|
||||
const customFieldsValues = (filters.customFieldsUi as IDataObject)
|
||||
.customFieldsValues as IDataObject[];
|
||||
if (customFieldsValues) {
|
||||
const customFields: IDataObject[] = [];
|
||||
for (const customFieldValue of customFieldsValues) {
|
||||
customFields.push({
|
||||
field_id: customFieldValue.fieldId,
|
||||
operator: (customFieldValue.operator === 'equal') ? '=' : customFieldValue.operator,
|
||||
operator:
|
||||
customFieldValue.operator === 'equal' ? '=' : customFieldValue.operator,
|
||||
value: customFieldValue.value as string,
|
||||
});
|
||||
}
|
||||
@@ -1012,10 +1078,24 @@ export class ClickUp implements INodeType {
|
||||
|
||||
const listId = this.getNodeParameter('list', i) as string;
|
||||
if (returnAll === true) {
|
||||
responseData = await clickupApiRequestAllItems.call(this, 'tasks', 'GET', `/list/${listId}/task`, {}, qs);
|
||||
responseData = await clickupApiRequestAllItems.call(
|
||||
this,
|
||||
'tasks',
|
||||
'GET',
|
||||
`/list/${listId}/task`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
} else {
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequestAllItems.call(this, 'tasks', 'GET', `/list/${listId}/task`, {}, qs);
|
||||
responseData = await clickupApiRequestAllItems.call(
|
||||
this,
|
||||
'tasks',
|
||||
'GET',
|
||||
`/list/${listId}/task`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
}
|
||||
}
|
||||
@@ -1023,11 +1103,23 @@ export class ClickUp implements INodeType {
|
||||
const taskId = this.getNodeParameter('id', i) as string;
|
||||
const returnAll = this.getNodeParameter('returnAll', i) as boolean;
|
||||
if (returnAll === true) {
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/task/${taskId}/member`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/task/${taskId}/member`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.members;
|
||||
} else {
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/task/${taskId}/member`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/task/${taskId}/member`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.members;
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
}
|
||||
@@ -1043,7 +1135,9 @@ export class ClickUp implements INodeType {
|
||||
if (jsonParse === true) {
|
||||
body.value = validateJSON(body.value);
|
||||
if (body.value === undefined) {
|
||||
throw new NodeOperationError(this.getNode(), 'Value is invalid JSON!', { itemIndex: i });
|
||||
throw new NodeOperationError(this.getNode(), 'Value is invalid JSON!', {
|
||||
itemIndex: i,
|
||||
});
|
||||
}
|
||||
} else {
|
||||
//@ts-ignore
|
||||
@@ -1051,7 +1145,12 @@ export class ClickUp implements INodeType {
|
||||
body.value = parseInt(body.value, 10);
|
||||
}
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/task/${taskId}/field/${fieldId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/task/${taskId}/field/${fieldId}`,
|
||||
body,
|
||||
);
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const taskId = this.getNodeParameter('id', i) as string;
|
||||
@@ -1066,7 +1165,13 @@ export class ClickUp implements INodeType {
|
||||
const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject;
|
||||
const qs: IDataObject = {};
|
||||
Object.assign(qs, additionalFields);
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/task/${taskId}/tag/${name}`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/task/${taskId}/tag/${name}`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'remove') {
|
||||
@@ -1075,7 +1180,13 @@ export class ClickUp implements INodeType {
|
||||
const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject;
|
||||
const qs: IDataObject = {};
|
||||
Object.assign(qs, additionalFields);
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/task/${taskId}/tag/${name}`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/task/${taskId}/tag/${name}`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
}
|
||||
@@ -1083,13 +1194,21 @@ export class ClickUp implements INodeType {
|
||||
if (operation === 'add') {
|
||||
const taskId = this.getNodeParameter('taskId', i) as string;
|
||||
const listId = this.getNodeParameter('listId', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/list/${listId}/task/${taskId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/list/${listId}/task/${taskId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'remove') {
|
||||
const taskId = this.getNodeParameter('taskId', i) as string;
|
||||
const listId = this.getNodeParameter('listId', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/list/${listId}/task/${taskId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/list/${listId}/task/${taskId}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
}
|
||||
@@ -1101,7 +1220,12 @@ export class ClickUp implements INodeType {
|
||||
|
||||
body.depends_on = dependsOnTaskId;
|
||||
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/task/${taskId}/dependency`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/task/${taskId}/dependency`,
|
||||
body,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
@@ -1110,7 +1234,13 @@ export class ClickUp implements INodeType {
|
||||
|
||||
qs.depends_on = dependsOnTaskId;
|
||||
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/task/${taskId}/dependency`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/task/${taskId}/dependency`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
}
|
||||
@@ -1128,7 +1258,7 @@ export class ClickUp implements INodeType {
|
||||
}
|
||||
|
||||
if (body.duration) {
|
||||
body.duration = body.duration as number * 60000;
|
||||
body.duration = (body.duration as number) * 60000;
|
||||
}
|
||||
|
||||
if (body.task) {
|
||||
@@ -1136,7 +1266,12 @@ export class ClickUp implements INodeType {
|
||||
body.custom_task_ids = true;
|
||||
}
|
||||
|
||||
responseData = await clickupApiRequest.call(this, 'PUT', `/team/${teamId}/time_entries/${timeEntryId}`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'PUT',
|
||||
`/team/${teamId}/time_entries/${timeEntryId}`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.data;
|
||||
}
|
||||
if (operation === 'getAll') {
|
||||
@@ -1152,7 +1287,13 @@ export class ClickUp implements INodeType {
|
||||
if (filters.end_date) {
|
||||
qs.end_date = moment.tz(qs.end_date, timezone).valueOf();
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/team/${teamId}/time_entries`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/team/${teamId}/time_entries`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
|
||||
responseData = responseData.data;
|
||||
|
||||
@@ -1160,7 +1301,6 @@ export class ClickUp implements INodeType {
|
||||
const limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = responseData.splice(0, limit);
|
||||
}
|
||||
|
||||
}
|
||||
if (operation === 'get') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
@@ -1191,10 +1331,15 @@ export class ClickUp implements INodeType {
|
||||
Object.assign(body, additionalFields);
|
||||
|
||||
if (body.tags) {
|
||||
body.tags = (body.tags as string[]).map((tag) => (JSON.parse(tag)));
|
||||
body.tags = (body.tags as string[]).map((tag) => JSON.parse(tag));
|
||||
}
|
||||
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/time_entries`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/team/${teamId}/time_entries`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.data;
|
||||
}
|
||||
if (operation === 'start') {
|
||||
@@ -1204,23 +1349,38 @@ export class ClickUp implements INodeType {
|
||||
body.tid = taskId;
|
||||
const additionalFields = this.getNodeParameter('additionalFields', i) as IDataObject;
|
||||
Object.assign(body, additionalFields);
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/time_entries/start`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/team/${teamId}/time_entries/start`,
|
||||
body,
|
||||
);
|
||||
responseData = responseData.data;
|
||||
}
|
||||
if (operation === 'stop') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/time_entries/stop`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/team/${teamId}/time_entries/stop`,
|
||||
);
|
||||
|
||||
if (responseData.data) {
|
||||
responseData = responseData.data;
|
||||
} else {
|
||||
throw new NodeOperationError(this.getNode(), 'There seems to be nothing to stop.', { itemIndex: i });
|
||||
throw new NodeOperationError(this.getNode(), 'There seems to be nothing to stop.', {
|
||||
itemIndex: i,
|
||||
});
|
||||
}
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
const timeEntryId = this.getNodeParameter('timeEntry', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/team/${teamId}/time_entries/${timeEntryId}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/team/${teamId}/time_entries/${timeEntryId}`,
|
||||
);
|
||||
responseData = responseData.data;
|
||||
}
|
||||
}
|
||||
@@ -1234,17 +1394,28 @@ export class ClickUp implements INodeType {
|
||||
if (tagsUi) {
|
||||
const tags = (tagsUi as IDataObject).tagsValues as IDataObject[];
|
||||
if (tags === undefined) {
|
||||
throw new NodeOperationError(this.getNode(), 'At least one tag must be set', { itemIndex: i });
|
||||
throw new NodeOperationError(this.getNode(), 'At least one tag must be set', {
|
||||
itemIndex: i,
|
||||
});
|
||||
}
|
||||
body.tags = tags;
|
||||
}
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/team/${teamId}/time_entries/tags`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/team/${teamId}/time_entries/tags`,
|
||||
body,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'getAll') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
const returnAll = this.getNodeParameter('returnAll', i) as boolean;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/team/${teamId}/time_entries/tags`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/team/${teamId}/time_entries/tags`,
|
||||
);
|
||||
|
||||
responseData = responseData.data;
|
||||
|
||||
@@ -1252,7 +1423,6 @@ export class ClickUp implements INodeType {
|
||||
const limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = responseData.splice(0, limit);
|
||||
}
|
||||
|
||||
}
|
||||
if (operation === 'remove') {
|
||||
const teamId = this.getNodeParameter('team', i) as string;
|
||||
@@ -1260,11 +1430,15 @@ export class ClickUp implements INodeType {
|
||||
const tagNames = this.getNodeParameter('tagNames', i) as string[];
|
||||
const body: IDataObject = {};
|
||||
body.time_entry_ids = timeEntryIds.split(',');
|
||||
body.tags = tagNames.map((tag) => (JSON.parse(tag).name));
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/team/${teamId}/time_entries/tags`, body);
|
||||
body.tags = tagNames.map((tag) => JSON.parse(tag).name);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/team/${teamId}/time_entries/tags`,
|
||||
body,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
|
||||
}
|
||||
if (resource === 'spaceTag') {
|
||||
if (operation === 'create') {
|
||||
@@ -1279,13 +1453,22 @@ export class ClickUp implements INodeType {
|
||||
tag_fg: foregroundColor,
|
||||
},
|
||||
};
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/space/${spaceId}/tag`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/space/${spaceId}/tag`,
|
||||
body,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'delete') {
|
||||
const spaceId = this.getNodeParameter('space', i) as string;
|
||||
const name = this.getNodeParameter('name', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'DELETE', `/space/${spaceId}/tag/${name}`);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'DELETE',
|
||||
`/space/${spaceId}/tag/${name}`,
|
||||
);
|
||||
responseData = { success: true };
|
||||
}
|
||||
if (operation === 'getAll') {
|
||||
@@ -1343,21 +1526,43 @@ export class ClickUp implements INodeType {
|
||||
body.status = additionalFields.status as string;
|
||||
}
|
||||
if (folderless) {
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/space/${spaceId}/list`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/space/${spaceId}/list`,
|
||||
body,
|
||||
);
|
||||
} else {
|
||||
const folderId = this.getNodeParameter('folder', i) as string;
|
||||
responseData = await clickupApiRequest.call(this, 'POST', `/folder/${folderId}/list`, body);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'POST',
|
||||
`/folder/${folderId}/list`,
|
||||
body,
|
||||
);
|
||||
}
|
||||
}
|
||||
if (operation === 'member') {
|
||||
const listId = this.getNodeParameter('id', i) as string;
|
||||
const returnAll = this.getNodeParameter('returnAll', i) as boolean;
|
||||
if (returnAll === true) {
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/list/${listId}/member`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/list/${listId}/member`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.members;
|
||||
} else {
|
||||
qs.limit = this.getNodeParameter('limit', i) as number;
|
||||
responseData = await clickupApiRequest.call(this, 'GET', `/list/${listId}/member`, {}, qs);
|
||||
responseData = await clickupApiRequest.call(
|
||||
this,
|
||||
'GET',
|
||||
`/list/${listId}/member`,
|
||||
{},
|
||||
qs,
|
||||
);
|
||||
responseData = responseData.members;
|
||||
responseData = responseData.splice(0, qs.limit);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
import {
|
||||
IHookFunctions,
|
||||
IWebhookFunctions,
|
||||
} from 'n8n-core';
|
||||
import { IHookFunctions, IWebhookFunctions } from 'n8n-core';
|
||||
|
||||
import {
|
||||
IDataObject,
|
||||
@@ -12,13 +9,9 @@ import {
|
||||
IWebhookResponseData,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import {
|
||||
clickupApiRequest,
|
||||
} from './GenericFunctions';
|
||||
import { clickupApiRequest } from './GenericFunctions';
|
||||
|
||||
import {
|
||||
createHmac,
|
||||
} from 'crypto';
|
||||
import { createHmac } from 'crypto';
|
||||
|
||||
export class ClickUpTrigger implements INodeType {
|
||||
description: INodeTypeDescription = {
|
||||
@@ -39,9 +32,7 @@ export class ClickUpTrigger implements INodeType {
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
authentication: [
|
||||
'accessToken',
|
||||
],
|
||||
authentication: ['accessToken'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -50,9 +41,7 @@ export class ClickUpTrigger implements INodeType {
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
authentication: [
|
||||
'oAuth2',
|
||||
],
|
||||
authentication: ['oAuth2'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -86,7 +75,8 @@ export class ClickUpTrigger implements INodeType {
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTeams',
|
||||
},
|
||||
@@ -339,15 +329,15 @@ export class ClickUpTrigger implements INodeType {
|
||||
const webhookData = this.getWorkflowStaticData('node');
|
||||
const headerData = this.getHeaderData() as IDataObject;
|
||||
const req = this.getRequestObject();
|
||||
const computedSignature = createHmac('sha256', webhookData.secret as string).update(JSON.stringify(req.body)).digest('hex');
|
||||
const computedSignature = createHmac('sha256', webhookData.secret as string)
|
||||
.update(JSON.stringify(req.body))
|
||||
.digest('hex');
|
||||
if (headerData['x-signature'] !== computedSignature) {
|
||||
// Signature is not valid so ignore call
|
||||
return {};
|
||||
}
|
||||
return {
|
||||
workflowData: [
|
||||
this.helpers.returnJsonArray(req.body),
|
||||
],
|
||||
workflowData: [this.helpers.returnJsonArray(req.body)],
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const commentOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const commentOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
resource: ['comment'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -46,7 +42,6 @@ export const commentOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const commentFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* comment:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -71,12 +66,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -87,12 +78,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -104,12 +91,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -121,12 +104,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -141,7 +120,8 @@ export const commentFields: INodeProperties[] = [
|
||||
name: 'notifyAll',
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description: 'Whether creation notifications will be sent to everyone including the creator of the comment',
|
||||
description:
|
||||
'Whether creation notifications will be sent to everyone including the creator of the comment',
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -156,12 +136,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -191,12 +167,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -207,12 +179,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -223,12 +191,8 @@ export const commentFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -249,12 +213,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -267,12 +227,8 @@ export const commentFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'comment',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['comment'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const folderOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const folderOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
resource: ['folder'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -52,7 +48,6 @@ export const folderOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const folderFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* folder:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -60,16 +55,13 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -81,23 +73,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -108,12 +95,8 @@ export const folderFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -126,16 +109,13 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -147,23 +127,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -171,23 +146,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -199,16 +169,13 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -220,23 +187,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -244,23 +206,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -272,16 +229,13 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -293,23 +247,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -319,12 +268,8 @@ export const folderFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -342,12 +287,8 @@ export const folderFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -367,16 +308,13 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -388,23 +326,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -412,23 +345,18 @@ export const folderFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -440,12 +368,8 @@ export const folderFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'folder',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['folder'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
OptionsWithUri,
|
||||
} from 'request';
|
||||
import { OptionsWithUri } from 'request';
|
||||
|
||||
import {
|
||||
IExecuteFunctions,
|
||||
@@ -10,14 +8,24 @@ import {
|
||||
IWebhookFunctions,
|
||||
} from 'n8n-core';
|
||||
|
||||
import {
|
||||
IDataObject,
|
||||
IOAuth2Options,
|
||||
NodeApiError,
|
||||
} from 'n8n-workflow';
|
||||
import { IDataObject, IOAuth2Options, NodeApiError } from 'n8n-workflow';
|
||||
|
||||
|
||||
export async function clickupApiRequest(this: IHookFunctions | IExecuteFunctions | IExecuteSingleFunctions | ILoadOptionsFunctions | IWebhookFunctions, method: string, resource: string, body: any = {}, qs: IDataObject = {}, uri?: string, option: IDataObject = {}): Promise<any> { // tslint:disable-line:no-any
|
||||
export async function clickupApiRequest(
|
||||
this:
|
||||
| IHookFunctions
|
||||
| IExecuteFunctions
|
||||
| IExecuteSingleFunctions
|
||||
| ILoadOptionsFunctions
|
||||
| IWebhookFunctions,
|
||||
method: string,
|
||||
resource: string,
|
||||
// tslint:disable-next-line:no-any
|
||||
body: any = {},
|
||||
qs: IDataObject = {},
|
||||
uri?: string,
|
||||
option: IDataObject = {},
|
||||
// tslint:disable-next-line:no-any
|
||||
): Promise<any> {
|
||||
const options: OptionsWithUri = {
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
@@ -34,22 +42,34 @@ export async function clickupApiRequest(this: IHookFunctions | IExecuteFunctions
|
||||
|
||||
if (authenticationMethod === 'accessToken') {
|
||||
return await this.helpers.requestWithAuthentication.call(this, 'clickUpApi', options);
|
||||
|
||||
} else {
|
||||
const oAuth2Options: IOAuth2Options = {
|
||||
keepBearer: false,
|
||||
tokenType: 'Bearer',
|
||||
};
|
||||
// @ts-ignore
|
||||
return await this.helpers.requestOAuth2!.call(this, 'clickUpOAuth2Api', options, oAuth2Options);
|
||||
return await this.helpers.requestOAuth2!.call(
|
||||
this,
|
||||
'clickUpOAuth2Api',
|
||||
options,
|
||||
oAuth2Options,
|
||||
);
|
||||
}
|
||||
} catch(error) {
|
||||
} catch (error) {
|
||||
throw new NodeApiError(this.getNode(), error);
|
||||
}
|
||||
}
|
||||
|
||||
export async function clickupApiRequestAllItems(this: IHookFunctions | IExecuteFunctions | ILoadOptionsFunctions, propertyName: string, method: string, resource: string, body: any = {}, query: IDataObject = {}): Promise<any> { // tslint:disable-line:no-any
|
||||
|
||||
export async function clickupApiRequestAllItems(
|
||||
this: IHookFunctions | IExecuteFunctions | ILoadOptionsFunctions,
|
||||
propertyName: string,
|
||||
method: string,
|
||||
resource: string,
|
||||
// tslint:disable-next-line:no-any
|
||||
body: any = {},
|
||||
query: IDataObject = {},
|
||||
// tslint:disable-next-line:no-any
|
||||
): Promise<any> {
|
||||
const returnData: IDataObject[] = [];
|
||||
|
||||
let responseData;
|
||||
@@ -62,14 +82,12 @@ export async function clickupApiRequestAllItems(this: IHookFunctions | IExecuteF
|
||||
if (query.limit && query.limit <= returnData.length) {
|
||||
return returnData;
|
||||
}
|
||||
} while (
|
||||
responseData[propertyName] &&
|
||||
responseData[propertyName].length !== 0
|
||||
);
|
||||
} while (responseData[propertyName] && responseData[propertyName].length !== 0);
|
||||
return returnData;
|
||||
}
|
||||
|
||||
export function validateJSON(json: string | undefined): any { // tslint:disable-line:no-any
|
||||
// tslint:disable-next-line:no-any
|
||||
export function validateJSON(json: string | undefined): any {
|
||||
let result;
|
||||
try {
|
||||
result = JSON.parse(json!);
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const goalOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const goalOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
resource: ['goal'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -52,7 +48,6 @@ export const goalOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const goalFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* goal:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -60,16 +55,13 @@ export const goalFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -84,12 +76,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -102,12 +90,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -157,12 +141,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -178,12 +158,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -196,16 +172,13 @@ export const goalFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -219,12 +192,8 @@ export const goalFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -245,12 +214,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -263,12 +228,8 @@ export const goalFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goal',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['goal'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const goalKeyResultOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const goalKeyResultOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -40,7 +36,6 @@ export const goalKeyResultOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const goalKeyResultFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* goalKeyResult:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -51,12 +46,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -68,12 +59,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -107,12 +94,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -125,12 +108,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -177,7 +156,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
name: 'unit',
|
||||
type: 'string',
|
||||
default: '',
|
||||
description: 'Only matters for type Number and Currency. For Currency the unit must be a valid currency code.',
|
||||
description:
|
||||
'Only matters for type Number and Currency. For Currency the unit must be a valid currency code.',
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -192,12 +172,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -213,12 +189,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -231,12 +203,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'goalKeyResult',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['goalKeyResult'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -287,7 +255,8 @@ export const goalKeyResultFields: INodeProperties[] = [
|
||||
name: 'unit',
|
||||
type: 'string',
|
||||
default: '',
|
||||
description: 'Only matters for type Number and Currency. For Currency the unit must be a valid currency code.',
|
||||
description:
|
||||
'Only matters for type Number and Currency. For Currency the unit must be a valid currency code.',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const guestOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const guestOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
resource: ['guest'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -46,7 +42,6 @@ export const guestOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const guestFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* guest:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -54,16 +49,13 @@ export const guestFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -79,12 +71,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -96,12 +84,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -133,16 +117,13 @@ export const guestFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -157,12 +138,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -175,16 +152,13 @@ export const guestFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -199,12 +173,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -217,16 +187,13 @@ export const guestFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -241,12 +208,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -259,12 +222,8 @@ export const guestFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'guest',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['guest'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const listOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const listOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
resource: ['list'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -25,7 +21,7 @@ export const listOperations: INodeProperties[] = [
|
||||
{
|
||||
name: 'Custom Fields',
|
||||
value: 'customFields',
|
||||
description: 'Retrieve list\'s custom fields',
|
||||
description: "Retrieve list's custom fields",
|
||||
action: 'Get custom fields from a list',
|
||||
},
|
||||
{
|
||||
@@ -64,7 +60,6 @@ export const listOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const listFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* list:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -72,16 +67,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -93,23 +85,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -120,12 +107,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -134,26 +117,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -164,12 +140,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -182,12 +154,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -233,12 +201,11 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Status Name or ID',
|
||||
name: 'status',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getStatuses',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: '',
|
||||
},
|
||||
@@ -256,12 +223,8 @@ export const listFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['member'],
|
||||
},
|
||||
},
|
||||
description: 'Task ID',
|
||||
@@ -272,12 +235,8 @@ export const listFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['member'],
|
||||
},
|
||||
},
|
||||
default: true,
|
||||
@@ -289,15 +248,9 @@ export const listFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['member'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -314,16 +267,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -335,23 +285,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'teamId',
|
||||
],
|
||||
loadOptionsDependsOn: ['teamId'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -362,12 +307,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -376,26 +317,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -403,26 +337,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
folderless: [
|
||||
true,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
folderless: [true],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolderlessLists',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -430,26 +357,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'customFields',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['customFields'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getLists',
|
||||
loadOptionsDependsOn: [
|
||||
'folder',
|
||||
],
|
||||
loadOptionsDependsOn: ['folder'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -461,16 +381,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -482,23 +399,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -509,12 +421,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -523,26 +431,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['delete'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -553,12 +454,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -571,16 +468,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -592,23 +486,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -619,12 +508,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -633,26 +518,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['get'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -663,12 +541,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -681,16 +555,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -702,23 +573,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -729,12 +595,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -743,26 +605,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -772,12 +627,8 @@ export const listFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -795,12 +646,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -820,16 +667,13 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -841,23 +685,18 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -868,12 +707,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -882,26 +717,19 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -912,12 +740,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -930,12 +754,8 @@ export const listFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'list',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['list'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -943,12 +763,11 @@ export const listFields: INodeProperties[] = [
|
||||
displayName: 'Assignee Name or ID',
|
||||
name: 'assignee',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getAssignees',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
|
||||
default: '',
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
export interface IList {
|
||||
name?: string;
|
||||
content?: string;
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const spaceTagOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const spaceTagOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -56,15 +52,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
'delete',
|
||||
'getAll',
|
||||
'update',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['create', 'delete', 'getAll', 'update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -76,12 +65,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -90,23 +75,17 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
displayName: 'Name or ID',
|
||||
name: 'name',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
loadOptionsMethod: 'getTags',
|
||||
},
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
'update',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['delete', 'update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -119,12 +98,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -136,13 +111,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
default: '#000000',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
'update',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['create', 'update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -154,13 +124,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
default: '#000000',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
'update',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['create', 'update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -171,12 +136,8 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
default: true,
|
||||
@@ -188,15 +149,9 @@ export const spaceTagFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'spaceTag',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['spaceTag'],
|
||||
operation: ['getAll'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const taskDependencyOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const taskDependencyOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskDependency',
|
||||
],
|
||||
resource: ['taskDependency'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -34,7 +30,6 @@ export const taskDependencyOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const taskDependencyFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* taskDependency:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -45,12 +40,8 @@ export const taskDependencyFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskDependency',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['taskDependency'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -62,12 +53,8 @@ export const taskDependencyFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskDependency',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['taskDependency'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -83,12 +70,8 @@ export const taskDependencyFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskDependency',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['taskDependency'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -100,12 +83,8 @@ export const taskDependencyFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskDependency',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['taskDependency'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const taskOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const taskOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
resource: ['task'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -64,7 +60,6 @@ export const taskOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const taskFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* task:create */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -72,16 +67,13 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -93,23 +85,18 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -120,12 +107,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -134,26 +117,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -161,26 +137,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
true,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
folderless: [true],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolderlessLists',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -188,26 +157,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getLists',
|
||||
loadOptionsDependsOn: [
|
||||
'folder',
|
||||
],
|
||||
loadOptionsDependsOn: ['folder'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -218,12 +180,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -237,12 +195,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -250,12 +204,11 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Assignee Names or IDs',
|
||||
name: 'assignees',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getAssignees',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: [],
|
||||
},
|
||||
@@ -268,7 +221,8 @@ export const taskFields: INodeProperties[] = [
|
||||
},
|
||||
default: '',
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-description-miscased-id
|
||||
description: 'Custom fields to set as JSON in the format: <code>[ {"id": "", "value": ""} ]</code>',
|
||||
description:
|
||||
'Custom fields to set as JSON in the format: <code>[ {"id": "", "value": ""} ]</code>',
|
||||
},
|
||||
{
|
||||
displayName: 'Content',
|
||||
@@ -336,12 +290,11 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Status Name or ID',
|
||||
name: 'status',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getStatuses',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: '',
|
||||
},
|
||||
@@ -351,12 +304,11 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'multiOptions',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTags',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
default: [],
|
||||
description: 'The array of tags applied to this task. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
description:
|
||||
'The array of tags applied to this task. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
},
|
||||
{
|
||||
displayName: 'Time Estimate',
|
||||
@@ -379,12 +331,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -396,12 +344,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -501,7 +445,6 @@ export const taskFields: INodeProperties[] = [
|
||||
default: 1,
|
||||
},
|
||||
],
|
||||
|
||||
},
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -515,12 +458,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -532,16 +471,13 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -553,23 +489,18 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -580,12 +511,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -594,26 +521,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -621,26 +541,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
folderless: [
|
||||
true,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
folderless: [true],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolderlessLists',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -648,26 +561,19 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getLists',
|
||||
loadOptionsDependsOn: [
|
||||
'folder',
|
||||
],
|
||||
loadOptionsDependsOn: ['folder'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -677,12 +583,8 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
default: true,
|
||||
@@ -694,15 +596,9 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -720,12 +616,8 @@ export const taskFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -739,12 +631,11 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Assignee Names or IDs',
|
||||
name: 'assignees',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getAssignees',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
|
||||
default: [],
|
||||
@@ -772,7 +663,8 @@ export const taskFields: INodeProperties[] = [
|
||||
loadOptionsMethod: 'getCustomFields',
|
||||
},
|
||||
default: '',
|
||||
description: 'The ID of the field to add custom field to. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
description:
|
||||
'The ID of the field to add custom field to. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
},
|
||||
{
|
||||
displayName: 'Operator',
|
||||
@@ -821,10 +713,7 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'string',
|
||||
displayOptions: {
|
||||
hide: {
|
||||
operator: [
|
||||
'IS NULL',
|
||||
'IS NOT NULL',
|
||||
],
|
||||
operator: ['IS NULL', 'IS NOT NULL'],
|
||||
},
|
||||
},
|
||||
default: '',
|
||||
@@ -882,7 +771,8 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-description-boolean-without-whether
|
||||
description: 'The response does by default not include closed tasks. Set this to true and dont send a status filter to include closed tasks.',
|
||||
description:
|
||||
'The response does by default not include closed tasks. Set this to true and dont send a status filter to include closed tasks.',
|
||||
},
|
||||
{
|
||||
displayName: 'Order By',
|
||||
@@ -912,12 +802,11 @@ export const taskFields: INodeProperties[] = [
|
||||
displayName: 'Status Names or IDs',
|
||||
name: 'statuses',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getStatuses',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: [],
|
||||
},
|
||||
@@ -934,12 +823,11 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'multiOptions',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTags',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
default: [],
|
||||
description: 'The array of tags applied to this task. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
description:
|
||||
'The array of tags applied to this task. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -955,12 +843,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -976,12 +860,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['member'],
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -991,12 +871,8 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['member'],
|
||||
},
|
||||
},
|
||||
default: true,
|
||||
@@ -1008,15 +884,9 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'member',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['member'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -1038,12 +908,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'setCustomField',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['setCustomField'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the task to add custom field to',
|
||||
@@ -1056,12 +922,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'setCustomField',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['setCustomField'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the field to add custom field to',
|
||||
@@ -1072,17 +934,14 @@ export const taskFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'setCustomField',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['setCustomField'],
|
||||
},
|
||||
},
|
||||
default: false,
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-description-boolean-without-whether
|
||||
description: 'The value is JSON and will be parsed as such. Is needed if for example needed for labels which expects the value to be an array.',
|
||||
description:
|
||||
'The value is JSON and will be parsed as such. Is needed if for example needed for labels which expects the value to be an array.',
|
||||
},
|
||||
{
|
||||
displayName: 'Value',
|
||||
@@ -1092,12 +951,8 @@ export const taskFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'task',
|
||||
],
|
||||
operation: [
|
||||
'setCustomField',
|
||||
],
|
||||
resource: ['task'],
|
||||
operation: ['setCustomField'],
|
||||
},
|
||||
},
|
||||
description: 'The value to set on custom field',
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
IDataObject
|
||||
} from 'n8n-workflow';
|
||||
import { IDataObject } from 'n8n-workflow';
|
||||
|
||||
export interface ITask {
|
||||
name?: string;
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const taskListOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const taskListOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskList',
|
||||
],
|
||||
resource: ['taskList'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -44,13 +40,8 @@ export const taskListFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskList',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
'add',
|
||||
],
|
||||
resource: ['taskList'],
|
||||
operation: ['remove', 'add'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -62,13 +53,8 @@ export const taskListFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskList',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
'add',
|
||||
],
|
||||
resource: ['taskList'],
|
||||
operation: ['remove', 'add'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const taskTagOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const taskTagOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskTag',
|
||||
],
|
||||
resource: ['taskTag'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -44,13 +40,8 @@ export const taskTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
'add',
|
||||
],
|
||||
resource: ['taskTag'],
|
||||
operation: ['remove', 'add'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -62,13 +53,8 @@ export const taskTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
'add',
|
||||
],
|
||||
resource: ['taskTag'],
|
||||
operation: ['remove', 'add'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -81,13 +67,8 @@ export const taskTagFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'taskTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
'add',
|
||||
],
|
||||
resource: ['taskTag'],
|
||||
operation: ['remove', 'add'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -96,7 +77,7 @@ export const taskTagFields: INodeProperties[] = [
|
||||
name: 'custom_task_ids',
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
description: 'Whether to reference a task by it\'s custom task ID',
|
||||
description: "Whether to reference a task by it's custom task ID",
|
||||
},
|
||||
{
|
||||
displayName: 'Team Name or ID',
|
||||
@@ -106,7 +87,8 @@ export const taskTagFields: INodeProperties[] = [
|
||||
loadOptionsMethod: 'getTeams',
|
||||
},
|
||||
default: '',
|
||||
description: 'Only used when the parameter is set to custom_task_ids=true. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
description:
|
||||
'Only used when the parameter is set to custom_task_ids=true. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const timeEntryOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const timeEntryOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -64,7 +60,6 @@ export const timeEntryOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const timeEntryFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* timeEntry:getAll */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -72,16 +67,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -95,12 +87,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
default: false,
|
||||
@@ -112,15 +100,9 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['getAll'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -138,12 +120,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -169,16 +147,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -192,12 +167,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['get'],
|
||||
},
|
||||
},
|
||||
default: false,
|
||||
@@ -210,15 +181,9 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
running: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['get'],
|
||||
running: [false],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -231,16 +196,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -252,23 +214,18 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -279,12 +236,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -293,26 +246,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -320,26 +266,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
true,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
folderless: [true],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolderlessLists',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -347,26 +286,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getLists',
|
||||
loadOptionsDependsOn: [
|
||||
'folder',
|
||||
],
|
||||
loadOptionsDependsOn: ['folder'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -376,12 +308,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
type: 'dateTime',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -393,12 +321,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
default: 0,
|
||||
@@ -409,22 +333,17 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Task Name or ID',
|
||||
name: 'task',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTasks',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: '',
|
||||
},
|
||||
@@ -436,12 +355,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['create'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -449,12 +364,11 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Assignee Name or ID',
|
||||
name: 'assignee',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getAssignees',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: [],
|
||||
},
|
||||
@@ -475,11 +389,10 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Tag Names or IDs',
|
||||
name: 'tags',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
loadOptionsMethod: 'getTimeEntryTags',
|
||||
},
|
||||
default: [],
|
||||
@@ -494,16 +407,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'start',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['start'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -518,12 +428,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'start',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['start'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -536,12 +442,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'start',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['start'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -568,16 +470,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'stop',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['stop'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -593,16 +492,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -617,12 +513,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['delete'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -635,16 +527,13 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -656,23 +545,18 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Space Name or ID',
|
||||
name: 'space',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getSpaces',
|
||||
loadOptionsDependsOn: [
|
||||
'team',
|
||||
],
|
||||
loadOptionsDependsOn: ['team'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -683,12 +567,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -697,26 +577,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Folder Name or ID',
|
||||
name: 'folder',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolders',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -724,26 +597,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
folderless: [
|
||||
true,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
folderless: [true],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getFolderlessLists',
|
||||
loadOptionsDependsOn: [
|
||||
'space',
|
||||
],
|
||||
loadOptionsDependsOn: ['space'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -751,26 +617,19 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'List Name or ID',
|
||||
name: 'list',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
folderless: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
folderless: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getLists',
|
||||
loadOptionsDependsOn: [
|
||||
'folder',
|
||||
],
|
||||
loadOptionsDependsOn: ['folder'],
|
||||
},
|
||||
required: true,
|
||||
},
|
||||
@@ -781,12 +640,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: false,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -798,12 +653,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -816,12 +667,8 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntry',
|
||||
],
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: ['timeEntry'],
|
||||
operation: ['update'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -829,12 +676,11 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Assignee Name or ID',
|
||||
name: 'assignee',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getAssignees',
|
||||
loadOptionsDependsOn: [
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['list'],
|
||||
},
|
||||
default: [],
|
||||
},
|
||||
@@ -868,11 +714,10 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Tag Names or IDs',
|
||||
name: 'tags',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsDependsOn: [
|
||||
'spaceId',
|
||||
],
|
||||
loadOptionsDependsOn: ['spaceId'],
|
||||
loadOptionsMethod: 'getTags',
|
||||
},
|
||||
default: [],
|
||||
@@ -881,13 +726,11 @@ export const timeEntryFields: INodeProperties[] = [
|
||||
displayName: 'Task Name or ID',
|
||||
name: 'task',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTasks',
|
||||
loadOptionsDependsOn: [
|
||||
'archived',
|
||||
'list',
|
||||
],
|
||||
loadOptionsDependsOn: ['archived', 'list'],
|
||||
},
|
||||
default: '',
|
||||
},
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
export const timeEntryTagOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -10,9 +8,7 @@ export const timeEntryTagOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -40,7 +36,6 @@ export const timeEntryTagOperations: INodeProperties[] = [
|
||||
];
|
||||
|
||||
export const timeEntryTagFields: INodeProperties[] = [
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
/* timeEntryTag:getAll */
|
||||
/* -------------------------------------------------------------------------- */
|
||||
@@ -48,16 +43,13 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -71,12 +63,8 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
type: 'boolean',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['getAll'],
|
||||
},
|
||||
},
|
||||
default: false,
|
||||
@@ -88,15 +76,9 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
type: 'number',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'getAll',
|
||||
],
|
||||
returnAll: [
|
||||
false,
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['getAll'],
|
||||
returnAll: [false],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -114,16 +96,13 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'add',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['add'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -138,12 +117,8 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'add',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['add'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -159,12 +134,8 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
default: {},
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'add',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['add'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -202,16 +173,13 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
displayName: 'Team Name or ID',
|
||||
name: 'team',
|
||||
type: 'options',
|
||||
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['remove'],
|
||||
},
|
||||
},
|
||||
typeOptions: {
|
||||
@@ -226,12 +194,8 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['remove'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
@@ -240,22 +204,17 @@ export const timeEntryTagFields: INodeProperties[] = [
|
||||
displayName: 'Tag Names or IDs',
|
||||
name: 'tagNames',
|
||||
type: 'multiOptions',
|
||||
description: 'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
description:
|
||||
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
|
||||
typeOptions: {
|
||||
loadOptionsMethod: 'getTimeEntryTags',
|
||||
loadOptionsDependsOn: [
|
||||
'teamId',
|
||||
],
|
||||
loadOptionsDependsOn: ['teamId'],
|
||||
},
|
||||
default: [],
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'timeEntryTag',
|
||||
],
|
||||
operation: [
|
||||
'remove',
|
||||
],
|
||||
resource: ['timeEntryTag'],
|
||||
operation: ['remove'],
|
||||
},
|
||||
},
|
||||
required: true,
|
||||
|
||||
Reference in New Issue
Block a user