refactor: Apply more eslint-plugin-n8n-nodes-base autofixable rules (#3432)

*  Update `lintfix` script

* 👕 Remove unneeded lint exceptions

* 👕 Run baseline `lintfix`

* 👕 Apply `node-param-description-miscased-url` (#3441)

* 👕 Apply `rule node-param-placeholder-miscased-id` (#3443)

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

* 👕 Apply `node-param-option-name-wrong-for-upsert` (#3446)

* 👕 Apply `node-param-min-value-wrong-for-limit` (#3442)

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

* Apply `node-param-display-name-wrong-for-dynamic-options` (#3454)

* 🔨 fix

*  Fix `Assigned To` fields

Co-authored-by: Michael Kret <michael.k@radency.com>

* 👕 Apply `rule node-param-default-wrong-for-number` (#3453)

* 👕 Apply `node-param-default-wrong-for-string` (#3452)

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

* Apply `node-param-display-name-miscased` (#3449)

* 🔨 fix

* 🔨 exceptions

*  review fixes

* 👕 Apply `node-param-description-lowercase-first-char` (#3451)

*  fix

*  review fixes

*  fix

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

* 👕 Apply `node-param-description-wrong-for-dynamic-options` (#3456)

* Rule working as intended

* Add rule

* 🔥 Remove repetitions

* 👕 Add exceptions

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

* 👕 Small fix for `node-param-description-wrong-for-dynamic-options`

* 👕 Apply `node-param-default-wrong-for-fixed-collection` (#3460)

* 👕 Apply `node-param-description-line-break-html-tag` (#3462)

* 👕 Run baseline `lintfix`

* 👕 Apply `node-param-options-type-unsorted-items` (#3459)

*  fix

* 🔨 exceptions

* Add exception for Salesmate and Zoom

Co-authored-by: Michael Kret <michael.k@radency.com>
Co-authored-by: Iván Ovejero <ivov.src@gmail.com>

*  Restore `lintfix` command

Co-authored-by: Omar Ajoue <krynble@gmail.com>
Co-authored-by: Michael Kret <88898367+michael-radency@users.noreply.github.com>
Co-authored-by: agobrech <45268029+agobrech@users.noreply.github.com>
Co-authored-by: Michael Kret <michael.k@radency.com>
Co-authored-by: brianinoa <54530642+brianinoa@users.noreply.github.com>
This commit is contained in:
Iván Ovejero
2022-06-03 19:23:49 +02:00
committed by GitHub
parent 58ecadf53c
commit 70ae90fa3c
501 changed files with 4668 additions and 4555 deletions

View File

@@ -72,6 +72,7 @@ export const leadFields: INodeProperties[] = [
/* lead:create */
/* -------------------------------------------------------------------------- */
{
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-wrong-for-dynamic-options
displayName: 'Match Against',
name: 'externalId',
type: 'options',
@@ -93,7 +94,7 @@ export const leadFields: INodeProperties[] = [
],
},
},
description: 'The field to check to see if the lead already exists',
description: 'The field to check to see if the lead already exists. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Value to Match',
@@ -209,14 +210,14 @@ export const leadFields: INodeProperties[] = [
displayName: 'Custom Field',
values: [
{
displayName: 'Field ID',
displayName: 'Field Name or ID',
name: 'fieldId',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getCustomFields',
},
default: '',
description: 'The ID of the field to add custom field to',
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/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Value',
@@ -275,14 +276,14 @@ export const leadFields: INodeProperties[] = [
description: 'References the ID of a contact in Data.com. If a lead has a value in this field, it means that a contact was imported as a lead from Data.com.',
},
{
displayName: 'Lead Source',
displayName: 'Lead Source Name or ID',
name: 'leadSource',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadSources',
},
default: '',
description: 'Source from which the lead was obtained',
description: 'Source from which the lead was obtained. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Mobile Phone',
@@ -299,14 +300,14 @@ export const leadFields: INodeProperties[] = [
description: 'Number of employees at the leads company. Label is Employees.',
},
{
displayName: 'Owner',
displayName: 'Owner Name or ID',
name: 'owner',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadOwners',
},
default: '',
description: 'The owner of the lead',
description: 'The owner of the lead. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Phone',
@@ -323,7 +324,7 @@ export const leadFields: INodeProperties[] = [
description: 'Postal code for the address of the lead. Label is Zip/Postal Code.',
},
{
displayName: 'Record Type ID',
displayName: 'Record Type Name or ID',
name: 'recordTypeId',
type: 'options',
typeOptions: {
@@ -353,14 +354,14 @@ export const leadFields: INodeProperties[] = [
description: 'State for the address of the lead',
},
{
displayName: 'Status',
displayName: 'Status Name or ID',
name: 'status',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadStatuses',
},
default: '',
description: 'Status code for this converted lead',
description: 'Status code for this converted lead. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Street',
@@ -471,14 +472,14 @@ export const leadFields: INodeProperties[] = [
displayName: 'Custom Field',
values: [
{
displayName: 'Field ID',
displayName: 'Field Name or ID',
name: 'fieldId',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getCustomFields',
},
default: '',
description: 'The ID of the field to add custom field to',
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/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Value',
@@ -544,14 +545,14 @@ export const leadFields: INodeProperties[] = [
description: 'Required. Last name of the lead. Limited to 80 characters.',
},
{
displayName: 'Lead Source',
displayName: 'Lead Source Name or ID',
name: 'leadSource',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadSources',
},
default: '',
description: 'Source from which the lead was obtained',
description: 'Source from which the lead was obtained. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Mobile Phone',
@@ -568,14 +569,14 @@ export const leadFields: INodeProperties[] = [
description: 'Number of employees at the leads company. Label is Employees.',
},
{
displayName: 'Owner',
displayName: 'Owner Name or ID',
name: 'owner',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadOwners',
},
default: '',
description: 'The owner of the lead',
description: 'The owner of the lead. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Postal Code',
@@ -592,7 +593,7 @@ export const leadFields: INodeProperties[] = [
description: 'Phone number for the lead',
},
{
displayName: 'Record Type ID',
displayName: 'Record Type Name or ID',
name: 'recordTypeId',
type: 'options',
typeOptions: {
@@ -622,14 +623,14 @@ export const leadFields: INodeProperties[] = [
description: 'State for the address of the lead',
},
{
displayName: 'Status',
displayName: 'Status Name or ID',
name: 'status',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadStatuses',
},
default: '',
description: 'Status code for this converted lead',
description: 'Status code for this converted lead. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Street',
@@ -776,14 +777,14 @@ export const leadFields: INodeProperties[] = [
displayName: 'Condition',
values: [
{
displayName: 'Field',
displayName: 'Field Name or ID',
name: 'field',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getLeadFields',
},
default: '',
description: 'For date, number, or boolean, please use expressions',
description: 'For date, number, or boolean, please use expressions. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
// eslint-disable-next-line n8n-nodes-base/node-param-operation-without-no-data-expression
{
@@ -791,6 +792,14 @@ export const leadFields: INodeProperties[] = [
name: 'operation',
type: 'options',
options: [
{
name: '<',
value: '<',
},
{
name: '<=',
value: '<=',
},
{
name: '=',
value: 'equal',
@@ -799,18 +808,10 @@ export const leadFields: INodeProperties[] = [
name: '>',
value: '>',
},
{
name: '<',
value: '<',
},
{
name: '>=',
value: '>=',
},
{
name: '<=',
value: '<=',
},
],
default: 'equal',
},
@@ -856,7 +857,7 @@ export const leadFields: INodeProperties[] = [
description: 'ID of contact that needs to be fetched',
},
{
displayName: 'Campaign',
displayName: 'Campaign Name or ID',
name: 'campaignId',
type: 'options',
typeOptions: {
@@ -874,7 +875,7 @@ export const leadFields: INodeProperties[] = [
],
},
},
description: 'ID of the campaign that needs to be fetched',
description: 'ID of the campaign that needs to be fetched. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
{
displayName: 'Options',
@@ -977,14 +978,14 @@ export const leadFields: INodeProperties[] = [
description: 'Whether true, only the note owner or a user with the “Modify All Data” permission can view the note or query it via the API',
},
{
displayName: 'Owner',
displayName: 'Owner Name or ID',
name: 'owner',
type: 'options',
typeOptions: {
loadOptionsMethod: 'getUsers',
},
default: '',
description: 'ID of the user who owns the note',
description: 'ID of the user who owns the note. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/nodes/expressions.html#expressions">expression</a>.',
},
],
},