mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +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,14 +1,8 @@
|
||||
import {
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
import { INodeProperties } from 'n8n-workflow';
|
||||
|
||||
import {
|
||||
allCurrencies,
|
||||
} from './currencies';
|
||||
import { allCurrencies } from './currencies';
|
||||
|
||||
import {
|
||||
activeCampaignDefaultGetAllProperties,
|
||||
} from './GenericFunctions';
|
||||
import { activeCampaignDefaultGetAllProperties } from './GenericFunctions';
|
||||
|
||||
export const ecomOrderOperations: INodeProperties[] = [
|
||||
{
|
||||
@@ -18,9 +12,7 @@ export const ecomOrderOperations: INodeProperties[] = [
|
||||
noDataExpression: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
options: [
|
||||
@@ -70,15 +62,12 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the order in the external service. ONLY REQUIRED IF EXTERNALCHECKOUTID NOT INCLUDED.',
|
||||
description:
|
||||
'The ID of the order in the external service. ONLY REQUIRED IF EXTERNALCHECKOUTID NOT INCLUDED.',
|
||||
},
|
||||
{
|
||||
displayName: 'External Checkout ID',
|
||||
@@ -87,15 +76,12 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the cart in the external service. ONLY REQUIRED IF EXTERNALID IS NOT INCLUDED.',
|
||||
description:
|
||||
'The ID of the cart in the external service. ONLY REQUIRED IF EXTERNALID IS NOT INCLUDED.',
|
||||
},
|
||||
{
|
||||
displayName: 'Order Source',
|
||||
@@ -105,15 +91,12 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The order source code (0 - will not trigger automations, 1 - will trigger automations)',
|
||||
description:
|
||||
'The order source code (0 - will not trigger automations, 1 - will trigger automations)',
|
||||
},
|
||||
{
|
||||
displayName: 'Customer Email',
|
||||
@@ -124,12 +107,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The email address of the customer who placed the order',
|
||||
@@ -142,15 +121,12 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The total price of the order in cents, including tax and shipping charges. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
description:
|
||||
'The total price of the order in cents, including tax and shipping charges. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
},
|
||||
{
|
||||
displayName: 'Order Currency',
|
||||
@@ -160,12 +136,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
options: allCurrencies,
|
||||
@@ -179,12 +151,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the connection from which this order originated',
|
||||
@@ -197,12 +165,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the customer associated with this order',
|
||||
@@ -215,12 +179,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
required: true,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The date the order was placed',
|
||||
@@ -232,12 +192,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: '',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The date the cart was abandoned. REQUIRED ONLY IF INCLUDING EXTERNALCHECKOUTID.',
|
||||
@@ -252,12 +208,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
},
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
default: {},
|
||||
@@ -276,7 +228,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
name: 'price',
|
||||
type: 'number',
|
||||
default: 0,
|
||||
description: 'The price of the product, in cents. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
description:
|
||||
'The price of the product, in cents. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
},
|
||||
{
|
||||
displayName: 'Product Quantity',
|
||||
@@ -336,12 +289,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
placeholder: 'Add Field',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'create',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['create'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
default: {},
|
||||
@@ -396,7 +345,6 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: '',
|
||||
description: 'The order number. This can be different than the externalid.',
|
||||
},
|
||||
|
||||
],
|
||||
},
|
||||
|
||||
@@ -410,12 +358,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: 0,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['update'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the e-commerce order',
|
||||
@@ -428,12 +372,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
placeholder: 'Add Field',
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'update',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['update'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
default: {},
|
||||
@@ -443,21 +383,24 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
name: 'externalid',
|
||||
type: 'string',
|
||||
default: '',
|
||||
description: 'The ID of the order in the external service. ONLY REQUIRED IF EXTERNALCHECKOUTID NOT INCLUDED.',
|
||||
description:
|
||||
'The ID of the order in the external service. ONLY REQUIRED IF EXTERNALCHECKOUTID NOT INCLUDED.',
|
||||
},
|
||||
{
|
||||
displayName: 'External Checkout ID',
|
||||
name: 'externalcheckoutid',
|
||||
type: 'string',
|
||||
default: '',
|
||||
description: 'The ID of the cart in the external service. ONLY REQUIRED IF EXTERNALID IS NOT INCLUDED.',
|
||||
description:
|
||||
'The ID of the cart in the external service. ONLY REQUIRED IF EXTERNALID IS NOT INCLUDED.',
|
||||
},
|
||||
{
|
||||
displayName: 'Order Source',
|
||||
name: 'source',
|
||||
type: 'number',
|
||||
default: 0,
|
||||
description: 'The order source code (0 - will not trigger automations, 1 - will trigger automations)',
|
||||
description:
|
||||
'The order source code (0 - will not trigger automations, 1 - will trigger automations)',
|
||||
},
|
||||
{
|
||||
displayName: 'Customer Email',
|
||||
@@ -472,7 +415,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
name: 'totalPrice',
|
||||
type: 'number',
|
||||
default: 0,
|
||||
description: 'The total price of the order in cents, including tax and shipping charges. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
description:
|
||||
'The total price of the order in cents, including tax and shipping charges. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
},
|
||||
{
|
||||
displayName: 'Order Currency',
|
||||
@@ -508,7 +452,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
name: 'abandonedDate',
|
||||
type: 'dateTime',
|
||||
default: '',
|
||||
description: 'The date the cart was abandoned. REQUIRED ONLY IF INCLUDING EXTERNALCHECKOUTID.',
|
||||
description:
|
||||
'The date the cart was abandoned. REQUIRED ONLY IF INCLUDING EXTERNALCHECKOUTID.',
|
||||
},
|
||||
{
|
||||
displayName: 'Shipping Amount',
|
||||
@@ -585,7 +530,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
name: 'price',
|
||||
type: 'number',
|
||||
default: 0,
|
||||
description: 'The price of the product, in cents. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
description:
|
||||
'The price of the product, in cents. (i.e. $456.78 => 45678). Must be greater than or equal to zero.',
|
||||
},
|
||||
{
|
||||
displayName: 'Product Quantity',
|
||||
@@ -638,7 +584,6 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
],
|
||||
},
|
||||
|
||||
@@ -652,12 +597,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: 0,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'delete',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['delete'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the e-commerce order',
|
||||
@@ -673,12 +614,8 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
default: 0,
|
||||
displayOptions: {
|
||||
show: {
|
||||
operation: [
|
||||
'get',
|
||||
],
|
||||
resource: [
|
||||
'ecommerceOrder',
|
||||
],
|
||||
operation: ['get'],
|
||||
resource: ['ecommerceOrder'],
|
||||
},
|
||||
},
|
||||
description: 'The ID of the e-commerce order',
|
||||
@@ -688,5 +625,4 @@ export const ecomOrderFields: INodeProperties[] = [
|
||||
// ecommerceOrder:getAll
|
||||
// ----------------------------------
|
||||
...activeCampaignDefaultGetAllProperties('ecommerceOrder', 'getAll'),
|
||||
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user