mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-16 09:34:07 -08:00
6f95121fac
* 👕 Add `action` to `INodePropertyOptions` * 👕 Apply `node-param-operation-option-without-action` * ✏️ Fix add/remove phrasing * ✏️ Fix email template phrasing * ✏️ Fix add/remove phrasing * ✏️ Fix custom fields phrasing * ✏️ Fix job report phrasing * ✏️ Fix query phrasing * ✏️ Various phrasing fixes * ✏️ Fix final phrasings * ✏️ Remove `conversation` * ✏️ Fix plural
71 lines
1.3 KiB
TypeScript
71 lines
1.3 KiB
TypeScript
import {
|
|
INodeProperties,
|
|
} from 'n8n-workflow';
|
|
|
|
export const mediaOperations: INodeProperties[] = [
|
|
{
|
|
displayName: 'Operation',
|
|
name: 'operation',
|
|
noDataExpression: true,
|
|
type: 'options',
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'media',
|
|
],
|
|
},
|
|
},
|
|
options: [
|
|
{
|
|
name: 'Download',
|
|
value: 'download',
|
|
description: 'Download media',
|
|
action: 'Download media',
|
|
},
|
|
],
|
|
default: 'download',
|
|
},
|
|
];
|
|
|
|
export const mediaFields: INodeProperties[] = [
|
|
/* -------------------------------------------------------------------------- */
|
|
/* media:download */
|
|
/* -------------------------------------------------------------------------- */
|
|
{
|
|
displayName: 'Resource Name',
|
|
name: 'resourceName',
|
|
type: 'string',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'media',
|
|
],
|
|
operation: [
|
|
'download',
|
|
],
|
|
},
|
|
},
|
|
default: '',
|
|
description: 'Name of the media that is being downloaded',
|
|
},
|
|
{
|
|
displayName: 'Binary Property',
|
|
name: 'binaryPropertyName',
|
|
type: 'string',
|
|
default: 'data',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'media',
|
|
],
|
|
operation: [
|
|
'download',
|
|
],
|
|
},
|
|
},
|
|
description: 'Name of the binary property to which to write the data of the read file',
|
|
},
|
|
];
|