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 problemOperations = [
export const problemOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
@@ -43,9 +43,9 @@ export const problemOperations = [
],
default: 'create',
},
] as INodeProperties[];
];
export const problemFields = [
export const problemFields: INodeProperties[] = [
// ----------------------------------------
// problem: create
// ----------------------------------------
@@ -74,9 +74,7 @@ export const problemFields = [
required: true,
default: '',
typeOptions: {
loadOptionsMethod: [
'getRequesters',
],
loadOptionsMethod: 'getRequesters',
},
displayOptions: {
show: {
@@ -130,9 +128,7 @@ export const problemFields = [
default: '',
description: 'ID of the agent to whom the problem is assigned. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getAgents',
],
loadOptionsMethod: 'getAgents',
},
},
{
@@ -142,9 +138,7 @@ export const problemFields = [
default: '',
description: 'ID of the department initiating the problem. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getDepartments',
],
loadOptionsMethod: 'getDepartments',
},
},
{
@@ -161,9 +155,7 @@ export const problemFields = [
default: '',
description: 'ID of the agent group to which the problem is assigned. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getAgentGroups',
],
loadOptionsMethod: 'getAgentGroups',
},
},
{
@@ -366,9 +358,7 @@ export const problemFields = [
default: '',
description: 'ID of the agent to whom the problem is assigned. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getAgents',
],
loadOptionsMethod: 'getAgents',
},
},
{
@@ -378,9 +368,7 @@ export const problemFields = [
default: '',
description: 'ID of the department initiating the problem. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getDepartments',
],
loadOptionsMethod: 'getDepartments',
},
},
{
@@ -404,9 +392,7 @@ export const problemFields = [
default: '',
description: 'ID of the agent group to which the problem is assigned. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getAgentGroups',
],
loadOptionsMethod: 'getAgentGroups',
},
},
{
@@ -460,9 +446,7 @@ export const problemFields = [
default: '',
description: 'ID of the initiator of the problem. Choose from the list or specify an ID. You can also specify the ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
typeOptions: {
loadOptionsMethod: [
'getRequesters',
],
loadOptionsMethod: 'getRequesters',
},
},
{
@@ -493,4 +477,4 @@ export const problemFields = [
},
],
},
] as INodeProperties[];
];