mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
* 👕 Enable `consistent-type-imports` for nodes-base * 👕 Apply to nodes-base * ⏪ Undo unrelated changes * 🚚 Move to `.eslintrc.js` in nodes-base * ⏪ Revert "Enable `consistent-type-imports` for nodes-base" This reverts commit 529ad72b051478fa1633aaf84b2864f2fdc7613c. * 👕 Fix severity
149 lines
2.9 KiB
TypeScript
149 lines
2.9 KiB
TypeScript
import type { INodeProperties } from 'n8n-workflow';
|
|
|
|
export const accountContactOperations: INodeProperties[] = [
|
|
{
|
|
displayName: 'Operation',
|
|
name: 'operation',
|
|
type: 'options',
|
|
noDataExpression: true,
|
|
displayOptions: {
|
|
show: {
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
options: [
|
|
{
|
|
name: 'Create',
|
|
value: 'create',
|
|
description: 'Create an association',
|
|
action: 'Create an account contact',
|
|
},
|
|
{
|
|
name: 'Delete',
|
|
value: 'delete',
|
|
description: 'Delete an association',
|
|
action: 'Delete an account contact',
|
|
},
|
|
{
|
|
name: 'Update',
|
|
value: 'update',
|
|
description: 'Update an association',
|
|
action: 'Update an account contact',
|
|
},
|
|
],
|
|
default: 'create',
|
|
},
|
|
];
|
|
|
|
export const accountContactFields: INodeProperties[] = [
|
|
// ----------------------------------
|
|
// accountContact:create
|
|
// ----------------------------------
|
|
{
|
|
displayName: 'Account ID',
|
|
name: 'account',
|
|
type: 'number',
|
|
default: '',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['create'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
},
|
|
{
|
|
displayName: 'Contact ID',
|
|
name: 'contact',
|
|
type: 'number',
|
|
default: '',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['create'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
},
|
|
{
|
|
displayName: 'Additional Fields',
|
|
name: 'additionalFields',
|
|
type: 'collection',
|
|
placeholder: 'Add Field',
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['create'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
default: {},
|
|
options: [
|
|
{
|
|
displayName: 'Job Title',
|
|
name: 'jobTitle',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Job Title of the contact at the account',
|
|
},
|
|
],
|
|
},
|
|
// ----------------------------------
|
|
// accountContact:delete
|
|
// ----------------------------------
|
|
{
|
|
displayName: 'Account Contact ID',
|
|
name: 'accountContactId',
|
|
type: 'number',
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['delete'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
default: 0,
|
|
required: true,
|
|
description: 'ID of the account contact to delete',
|
|
},
|
|
// ----------------------------------
|
|
// accountContact:update
|
|
// ----------------------------------
|
|
{
|
|
displayName: 'Account Contact ID',
|
|
name: 'accountContactId',
|
|
type: 'number',
|
|
default: '',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['update'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
description: 'Account ID',
|
|
},
|
|
|
|
{
|
|
displayName: 'Update Fields',
|
|
name: 'updateFields',
|
|
type: 'collection',
|
|
description: 'The fields to update',
|
|
placeholder: 'Add Field',
|
|
displayOptions: {
|
|
show: {
|
|
operation: ['update'],
|
|
resource: ['accountContact'],
|
|
},
|
|
},
|
|
default: {},
|
|
options: [
|
|
{
|
|
displayName: 'Job Title',
|
|
name: 'jobTitle',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Job Title of the contact at the account',
|
|
},
|
|
],
|
|
},
|
|
];
|