Enforce type checking in all node params (#2509)

This commit is contained in:
Iván Ovejero
2021-12-03 09:44:16 +01:00
committed by GitHub
parent ca761c88c8
commit a783288338
527 changed files with 2289 additions and 2259 deletions

View File

@@ -2,7 +2,7 @@ import {
INodeProperties,
} from 'n8n-workflow';
export const accountContactOperations = [
export const accountContactOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -34,9 +34,9 @@ export const accountContactOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const accountContactFields = [
export const accountContactFields: INodeProperties[] = [
// ----------------------------------
// accountContact:create
// ----------------------------------
@@ -172,4 +172,4 @@ export const accountContactFields = [
},
],
},
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const accountOperations = [
export const accountOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -48,9 +48,9 @@ export const accountOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const accountFields = [
export const accountFields: INodeProperties[] = [
// ----------------------------------
// contact:create
// ----------------------------------
@@ -299,4 +299,4 @@ export const accountFields = [
],
},
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const connectionOperations = [
export const connectionOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -49,9 +49,9 @@ export const connectionOperations = [
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const connectionFields = [
export const connectionFields: INodeProperties[] = [
// ----------------------------------
// connection:create
// ----------------------------------
@@ -286,4 +286,4 @@ export const connectionFields = [
// ----------------------------------
...activeCampaignDefaultGetAllProperties('connection', 'getAll'),
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const contactOperations = [
export const contactOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -48,9 +48,9 @@ export const contactOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const contactFields = [
export const contactFields: INodeProperties[] = [
// ----------------------------------
// contact:create
// ----------------------------------
@@ -510,4 +510,4 @@ export const contactFields = [
},
],
},
] as INodeProperties[];
];

View File

@@ -2,7 +2,7 @@ import {
INodeProperties,
} from 'n8n-workflow';
export const contactListOperations = [
export const contactListOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -29,9 +29,9 @@ export const contactListOperations = [
default: 'add',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const contactListFields = [
export const contactListFields: INodeProperties[] = [
// ----------------------------------
// contactList:add
// ----------------------------------
@@ -111,4 +111,4 @@ export const contactListFields = [
},
description: 'Contact ID',
},
] as INodeProperties[];
];

View File

@@ -2,7 +2,7 @@ import {
INodeProperties,
} from 'n8n-workflow';
export const contactTagOperations = [
export const contactTagOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -29,9 +29,9 @@ export const contactTagOperations = [
default: 'add',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const contactTagFields = [
export const contactTagFields: INodeProperties[] = [
// ----------------------------------
// contactTag:add
// ----------------------------------
@@ -95,4 +95,4 @@ export const contactTagFields = [
required: true,
description: 'ID of the contact tag to delete.',
},
] as INodeProperties[];
];

View File

@@ -10,7 +10,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const dealOperations = [
export const dealOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -63,9 +63,9 @@ export const dealOperations = [
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const dealFields = [
export const dealFields: INodeProperties[] = [
// ----------------------------------
// deal:create
// ----------------------------------
@@ -494,4 +494,4 @@ export const dealFields = [
description: 'The content of the deal note',
},
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const ecomCustomerOperations = [
export const ecomCustomerOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -48,9 +48,9 @@ export const ecomCustomerOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const ecomCustomerFields = [
export const ecomCustomerFields: INodeProperties[] = [
// ----------------------------------
// ecommerceCustomer:create
// ----------------------------------
@@ -253,4 +253,4 @@ export const ecomCustomerFields = [
// ecommerceCustomer:getAll
// ----------------------------------
...activeCampaignDefaultGetAllProperties('ecommerceCustomer', 'getAll'),
] as INodeProperties[];
];

View File

@@ -10,7 +10,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const ecomOrderOperations = [
export const ecomOrderOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -52,9 +52,9 @@ export const ecomOrderOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const ecomOrderFields = [
export const ecomOrderFields: INodeProperties[] = [
// ----------------------------------
// ecommerceOrder:create
// ----------------------------------
@@ -682,4 +682,4 @@ export const ecomOrderFields = [
// ----------------------------------
...activeCampaignDefaultGetAllProperties('ecommerceOrder', 'getAll'),
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const ecomOrderProductsOperations = [
export const ecomOrderProductsOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -38,9 +38,9 @@ export const ecomOrderProductsOperations = [
default: 'getAll',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const ecomOrderProductsFields = [
export const ecomOrderProductsFields: INodeProperties[] = [
// ----------------------------------
// ecommerceOrderProducts:getByOrderId
// ----------------------------------
@@ -87,4 +87,4 @@ export const ecomOrderProductsFields = [
// ecommerceOrderProducts:getAll
// ----------------------------------
...activeCampaignDefaultGetAllProperties('ecommerceOrderProducts', 'getAll'),
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const listOperations = [
export const listOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -28,11 +28,11 @@ export const listOperations = [
default: 'getAll',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const listFields = [
export const listFields: INodeProperties[] = [
// ----------------------------------
// list:getAll
// ----------------------------------
...activeCampaignDefaultGetAllProperties('list', 'getAll'),
] as INodeProperties[];
];

View File

@@ -6,7 +6,7 @@ import {
activeCampaignDefaultGetAllProperties,
} from './GenericFunctions';
export const tagOperations = [
export const tagOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -48,9 +48,9 @@ export const tagOperations = [
default: 'create',
description: 'The operation to perform.',
},
] as INodeProperties[];
];
export const tagFields = [
export const tagFields: INodeProperties[] = [
// ----------------------------------
// contact:create
// ----------------------------------
@@ -229,4 +229,4 @@ export const tagFields = [
// tag:getAll
// ----------------------------------
...activeCampaignDefaultGetAllProperties('tag', 'getAll'),
] as INodeProperties[];
];