mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-15 00:54:06 -08:00
2febc61ec9
Github issue / Community forum post (link here to close automatically): https://community.n8n.io/t/add-more-outputs-to-switch-node/3864 --------- Signed-off-by: Oleg Ivaniv <me@olegivaniv.com>
188 lines
3.9 KiB
JSON
188 lines
3.9 KiB
JSON
{
|
|
"name": "My workflow 109",
|
|
"nodes": [
|
|
{
|
|
"parameters": {},
|
|
"id": "7ae16f96-5c2c-44a3-9f96-167e426336f9",
|
|
"name": "When clicking \"Execute Workflow\"",
|
|
"type": "n8n-nodes-base.manualTrigger",
|
|
"typeVersion": 1,
|
|
"position": [
|
|
620,
|
|
720
|
|
]
|
|
},
|
|
{
|
|
"parameters": {
|
|
"jsCode": "return [{\n \"output\": \"third\",\n \"text\": \"third output text\"\n}, {\n \"output\": \"fourth\",\n \"text\": \"fourth output text\"\n}, {\n \"output\": \"first\",\n \"text\": \"first output text\"\n}, {\n \"output\": \"second\",\n \"text\": \"second output text\"\n}]"
|
|
},
|
|
"id": "31e9aada-7aa2-4c62-8e15-0cecb91788e4",
|
|
"name": "Code",
|
|
"type": "n8n-nodes-base.code",
|
|
"typeVersion": 2,
|
|
"position": [
|
|
840,
|
|
720
|
|
]
|
|
},
|
|
{
|
|
"parameters": {
|
|
"dataType": "string",
|
|
"value1": "={{ $json.output }}",
|
|
"rules": {
|
|
"rules": [
|
|
{
|
|
"value2": "first",
|
|
"outputKey": "First Output"
|
|
},
|
|
{
|
|
"value2": "second",
|
|
"outputKey": "Second Output"
|
|
},
|
|
{
|
|
"value2": "third",
|
|
"outputKey": "Third Output"
|
|
}
|
|
]
|
|
},
|
|
"fallbackOutput": 2
|
|
},
|
|
"id": "0dd6e98a-2830-42fb-9a9d-6d4ff8678cbd",
|
|
"name": "Switch",
|
|
"type": "n8n-nodes-base.switch",
|
|
"typeVersion": 2,
|
|
"position": [
|
|
1120,
|
|
720
|
|
]
|
|
},
|
|
{
|
|
"parameters": {},
|
|
"id": "cf10b4c7-16a6-4c16-a17c-7b83f954f7b9",
|
|
"name": "No Operation, do nothing",
|
|
"type": "n8n-nodes-base.noOp",
|
|
"typeVersion": 1,
|
|
"position": [
|
|
1380,
|
|
560
|
|
]
|
|
},
|
|
{
|
|
"parameters": {},
|
|
"id": "3e7e7f4a-bff9-4ce1-a5e5-58505853260f",
|
|
"name": "No Operation, do nothing1",
|
|
"type": "n8n-nodes-base.noOp",
|
|
"typeVersion": 1,
|
|
"position": [
|
|
1380,
|
|
720
|
|
]
|
|
},
|
|
{
|
|
"parameters": {},
|
|
"id": "205f59d6-52f5-4412-9511-b680a91d0be2",
|
|
"name": "No Operation, do nothing2",
|
|
"type": "n8n-nodes-base.noOp",
|
|
"typeVersion": 1,
|
|
"position": [
|
|
1380,
|
|
880
|
|
]
|
|
}
|
|
],
|
|
"pinData": {
|
|
"No Operation, do nothing": [
|
|
{
|
|
"json": {
|
|
"output": "first",
|
|
"text": "first output text"
|
|
}
|
|
|
|
}
|
|
],
|
|
"No Operation, do nothing1": [
|
|
{
|
|
"json": {
|
|
"output": "second",
|
|
"text": "second output text"
|
|
}
|
|
|
|
}
|
|
],
|
|
"No Operation, do nothing2": [
|
|
{
|
|
"json": {
|
|
"output": "third",
|
|
"text": "third output text"
|
|
}
|
|
|
|
},
|
|
{
|
|
"json": {
|
|
"output": "fourth",
|
|
"text": "fourth output text"
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"connections": {
|
|
"When clicking \"Execute Workflow\"": {
|
|
"main": [
|
|
[
|
|
{
|
|
"node": "Code",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
]
|
|
]
|
|
},
|
|
"Code": {
|
|
"main": [
|
|
[
|
|
{
|
|
"node": "Switch",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
]
|
|
]
|
|
},
|
|
"Switch": {
|
|
"main": [
|
|
[
|
|
{
|
|
"node": "No Operation, do nothing",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"node": "No Operation, do nothing1",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
],
|
|
[
|
|
{
|
|
"node": "No Operation, do nothing2",
|
|
"type": "main",
|
|
"index": 0
|
|
}
|
|
]
|
|
]
|
|
}
|
|
},
|
|
"active": false,
|
|
"settings": {
|
|
"executionOrder": "v1"
|
|
},
|
|
"versionId": "627af20f-47fc-47a7-8da6-a7e7b21225df",
|
|
"id": "xjPY8ZYJK53G6nQ1",
|
|
"meta": {
|
|
"instanceId": "ec7a5f4ffdb34436e59d23eaccb5015b5238de2a877e205b28572bf1ffecfe04"
|
|
},
|
|
"tags": []
|
|
}
|