mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-09 22:24:05 -08:00
fix(Wait Node): Append n8n attribution option (#10585)
This commit is contained in:
parent
ccb553a550
commit
81f4322d45
|
@ -14,6 +14,7 @@ import { createTransport } from 'nodemailer';
|
|||
import type SMTPTransport from 'nodemailer/lib/smtp-transport';
|
||||
|
||||
import { updateDisplayOptions } from '@utils/utilities';
|
||||
import { appendAttributionOption } from '../../../utils/descriptions';
|
||||
|
||||
const properties: INodeProperties[] = [
|
||||
// TODO: Add choice for text as text or html (maybe also from name)
|
||||
|
@ -137,11 +138,7 @@ const properties: INodeProperties[] = [
|
|||
default: {},
|
||||
options: [
|
||||
{
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
name: 'appendAttribution',
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
...appendAttributionOption,
|
||||
description:
|
||||
'Whether to include the phrase “This email was sent automatically with n8n” to the end of the email',
|
||||
},
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import type { INodeProperties } from 'n8n-workflow';
|
||||
import { appendAttributionOption } from '../../utils/descriptions';
|
||||
|
||||
export const webhookPath: INodeProperties = {
|
||||
displayName: 'Form Path',
|
||||
|
@ -314,3 +315,8 @@ export const respondWithOptions: INodeProperties = {
|
|||
},
|
||||
],
|
||||
};
|
||||
|
||||
export const appendAttributionToForm: INodeProperties = {
|
||||
...appendAttributionOption,
|
||||
description: 'Whether to include the link “Form automated with n8n” at the bottom of the form',
|
||||
};
|
||||
|
|
|
@ -10,6 +10,7 @@ import {
|
|||
|
||||
import { formWebhook } from '../utils';
|
||||
import {
|
||||
appendAttributionToForm,
|
||||
formDescription,
|
||||
formFields,
|
||||
formRespondMode,
|
||||
|
@ -116,15 +117,7 @@ const descriptionV2: INodeTypeDescription = {
|
|||
placeholder: 'Add option',
|
||||
default: {},
|
||||
options: [
|
||||
{
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
name: 'appendAttribution',
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
description:
|
||||
'Whether to include the link “Form automated with n8n” at the bottom of the form',
|
||||
},
|
||||
appendAttributionToForm,
|
||||
{
|
||||
...respondWithOptions,
|
||||
displayOptions: {
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import type { INodeProperties } from 'n8n-workflow';
|
||||
import { appendAttributionOption } from '../../../../utils/descriptions';
|
||||
|
||||
export const messageOperations: INodeProperties[] = [
|
||||
{
|
||||
|
@ -200,11 +201,7 @@ export const messageFields: INodeProperties[] = [
|
|||
default: {},
|
||||
options: [
|
||||
{
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
name: 'appendAttribution',
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
...appendAttributionOption,
|
||||
description:
|
||||
'Whether to include the phrase “This email was sent automatically with n8n” to the end of the email',
|
||||
},
|
||||
|
|
|
@ -11,6 +11,7 @@ import type {
|
|||
import { BINARY_ENCODING, NodeConnectionType, NodeOperationError } from 'n8n-workflow';
|
||||
|
||||
import { addAdditionalFields, apiRequest, getPropertyName } from './GenericFunctions';
|
||||
import { appendAttributionOption } from '../../utils/descriptions';
|
||||
|
||||
export class Telegram implements INodeType {
|
||||
description: INodeTypeDescription = {
|
||||
|
@ -1508,11 +1509,7 @@ export class Telegram implements INodeType {
|
|||
default: {},
|
||||
options: [
|
||||
{
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
name: 'appendAttribution',
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
...appendAttributionOption,
|
||||
description:
|
||||
'Whether to include the phrase “This message was sent automatically with n8n” to the end of the message',
|
||||
displayOptions: {
|
||||
|
|
|
@ -27,6 +27,7 @@ import {
|
|||
respondWithOptions,
|
||||
formRespondMode,
|
||||
formTitle,
|
||||
appendAttributionToForm,
|
||||
} from '../Form/common.descriptions';
|
||||
import { formWebhook } from '../Form/utils';
|
||||
import { updateDisplayOptions } from '../../utils/utilities';
|
||||
|
@ -436,7 +437,7 @@ export class Wait extends Webhook {
|
|||
responseMode: ['responseNode'],
|
||||
},
|
||||
},
|
||||
options: [respondWithOptions, webhookSuffix],
|
||||
options: [appendAttributionToForm, respondWithOptions, webhookSuffix],
|
||||
},
|
||||
{
|
||||
displayName: 'Options',
|
||||
|
@ -452,7 +453,7 @@ export class Wait extends Webhook {
|
|||
responseMode: ['onReceived', 'lastNode'],
|
||||
},
|
||||
},
|
||||
options: [webhookSuffix],
|
||||
options: [appendAttributionToForm, webhookSuffix],
|
||||
},
|
||||
],
|
||||
};
|
||||
|
|
|
@ -41,6 +41,14 @@ export const looseTypeValidationProperty: INodeProperties = {
|
|||
default: true,
|
||||
};
|
||||
|
||||
export const appendAttributionOption: INodeProperties = {
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
name: 'appendAttribution',
|
||||
type: 'boolean',
|
||||
default: true,
|
||||
};
|
||||
|
||||
export const encodeDecodeOptions: INodePropertyOptions[] = [
|
||||
{
|
||||
name: 'armscii8',
|
||||
|
|
Loading…
Reference in a new issue