n8n/packages/nodes-base/nodes/Cockpit/SingletonDescription.ts

47 lines
791 B
TypeScript
Raw Normal View History

2020-04-04 07:04:25 -07:00
import { INodeProperties } from 'n8n-workflow';
export const singletonOperations: INodeProperties[] = [
2020-04-04 07:04:25 -07:00
{
displayName: 'Operation',
name: 'operation',
type: 'options',
displayOptions: {
show: {
resource: [
'singleton',
2020-04-04 07:04:25 -07:00
],
},
},
options: [
{
name: 'Get',
value: 'get',
description: 'Get a singleton',
2020-04-04 07:04:25 -07:00
},
],
default: 'get',
2020-04-04 07:04:25 -07:00
description: 'The operation to perform.',
2020-10-22 06:46:03 -07:00
},
];
export const singletonFields: INodeProperties[] = [
{
displayName: 'Singleton',
name: 'singleton',
type: 'options',
default: '',
typeOptions: {
loadOptionsMethod: 'getSingletons',
},
displayOptions: {
show: {
resource: [
'singleton',
],
},
},
required: true,
2020-10-22 06:46:03 -07:00
description: 'Name of the singleton to operate on.',
},
];