mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-09 22:24:05 -08:00
fix(n8n Form Trigger Node): Remove custom attribution option (no-changelog) (#10229)
This commit is contained in:
parent
711b667ebe
commit
e5dfd7faf9
|
@ -460,9 +460,6 @@
|
|||
<div class='n8n-link'>
|
||||
<a href={{n8nWebsiteLink}} target='_blank'>
|
||||
Form automated with
|
||||
{{#if customAttribution}}
|
||||
{{{customAttribution}}}
|
||||
{{else}}
|
||||
<svg
|
||||
width='73'
|
||||
height='20'
|
||||
|
@ -489,7 +486,6 @@
|
|||
fill='#101330'
|
||||
/>
|
||||
</svg>
|
||||
{{/if}}
|
||||
</a>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
|
|
@ -40,7 +40,6 @@ export type FormTriggerData = {
|
|||
formFields: FormTriggerInput[];
|
||||
useResponseData?: boolean;
|
||||
appendAttribution?: boolean;
|
||||
customAttribution?: string;
|
||||
};
|
||||
|
||||
export const FORM_TRIGGER_AUTHENTICATION_PROPERTY = 'authentication';
|
||||
|
|
|
@ -49,7 +49,6 @@ describe('FormTrigger, formWebhook', () => {
|
|||
|
||||
expect(mockRender).toHaveBeenCalledWith('form-trigger', {
|
||||
appendAttribution: true,
|
||||
customAttribution: undefined,
|
||||
formDescription: 'Test Description',
|
||||
formFields: [
|
||||
{
|
||||
|
@ -247,7 +246,6 @@ describe('FormTrigger, prepareFormData', () => {
|
|||
],
|
||||
useResponseData: true,
|
||||
appendAttribution: true,
|
||||
customAttribution: undefined,
|
||||
redirectUrl: 'https://example.com/thank-you',
|
||||
});
|
||||
});
|
||||
|
@ -293,7 +291,6 @@ describe('FormTrigger, prepareFormData', () => {
|
|||
],
|
||||
useResponseData: undefined,
|
||||
appendAttribution: true,
|
||||
customAttribution: undefined,
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
@ -26,7 +26,6 @@ export function prepareFormData({
|
|||
instanceId,
|
||||
useResponseData,
|
||||
appendAttribution = true,
|
||||
customAttribution,
|
||||
}: {
|
||||
formTitle: string;
|
||||
formDescription: string;
|
||||
|
@ -38,7 +37,6 @@ export function prepareFormData({
|
|||
instanceId?: string;
|
||||
useResponseData?: boolean;
|
||||
appendAttribution?: boolean;
|
||||
customAttribution?: string;
|
||||
}) {
|
||||
const validForm = formFields.length > 0;
|
||||
const utm_campaign = instanceId ? `&utm_campaign=${instanceId}` : '';
|
||||
|
@ -58,7 +56,6 @@ export function prepareFormData({
|
|||
formFields: [],
|
||||
useResponseData,
|
||||
appendAttribution,
|
||||
customAttribution,
|
||||
};
|
||||
|
||||
if (redirectUrl) {
|
||||
|
@ -157,7 +154,6 @@ export async function formWebhook(context: IWebhookFunctions) {
|
|||
formSubmittedText?: string;
|
||||
useWorkflowTimezone?: boolean;
|
||||
appendAttribution?: boolean;
|
||||
customAttribution?: string;
|
||||
};
|
||||
const res = context.getResponseObject();
|
||||
const req = context.getRequestObject();
|
||||
|
@ -225,7 +221,6 @@ export async function formWebhook(context: IWebhookFunctions) {
|
|||
instanceId,
|
||||
useResponseData,
|
||||
appendAttribution,
|
||||
customAttribution: options.customAttribution as string,
|
||||
});
|
||||
|
||||
res.render('form-trigger', data);
|
||||
|
|
|
@ -115,17 +115,6 @@ const descriptionV2: INodeTypeDescription = {
|
|||
placeholder: 'Add option',
|
||||
default: {},
|
||||
options: [
|
||||
{
|
||||
displayName: 'Custom Attribution',
|
||||
name: 'customAttribution',
|
||||
type: 'string',
|
||||
placeholder: 'e.g. <svg> ...</svg>',
|
||||
description: "HTML code that will be shown at the bottom of the form instead n8n's logo",
|
||||
default: '',
|
||||
typeOptions: {
|
||||
rows: 2,
|
||||
},
|
||||
},
|
||||
{
|
||||
// eslint-disable-next-line n8n-nodes-base/node-param-display-name-miscased
|
||||
displayName: 'Append n8n Attribution',
|
||||
|
|
Loading…
Reference in a new issue