@semilimes/node-red-semilimes
Advanced tools
Comparing version 1.1.0 to 1.1.1
{ | ||
"name": "@semilimes/node-red-semilimes", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "The new semilimes connector which integrates with the public API", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -14,2 +14,4 @@ "use strict"; | ||
this.choiceSelectionMode = config.choiceSelectionMode; | ||
this.title = config.title; | ||
@@ -142,3 +144,23 @@ this.titleType = config.titleType; | ||
case 'singlechoice': | ||
// => multichoice | ||
var titleFieldValue = smeHelper.getNodeConfigValue(node, msg, node.titleType, node.title); | ||
var requiredFieldValue = smeHelper.getNodeConfigValue(node, msg, node.requiredType, node.required); | ||
var optionsFieldValue = []; | ||
node.choices.forEach(choice => { | ||
optionsFieldValue.push({ | ||
name: choice.name, | ||
value: choice.value | ||
}); | ||
}); | ||
var fc = { | ||
refName: referenceFieldValue || "", | ||
formComponentType: node.component, | ||
title: titleFieldValue ?? "", | ||
requiredSelection: requiredFieldValue, | ||
options: optionsFieldValue | ||
}; | ||
if (node.choiceSelectionMode) { | ||
fc.mode = node.choiceSelectionMode; | ||
} | ||
location.formComponents.push(fc); | ||
break; | ||
case 'multichoice': | ||
@@ -145,0 +167,0 @@ var titleFieldValue = smeHelper.getNodeConfigValue(node, msg, node.titleType, node.title); |
@@ -15,12 +15,23 @@ "use strict"; | ||
this.refName = config.refName; | ||
this.refNameType = config.refNameType; | ||
this.submitText = config.submitText; | ||
this.submitTextType = config.submitTextType; | ||
this.submitEnabled = config.submitEnabled; | ||
this.retainStatus = config.retainStatus; | ||
this.receiverType = config.receiverType; | ||
this.recipientId = config.recipientId; | ||
this.recipientIdType = config.recipientIdType; | ||
this.receiverType = config.receiverType; | ||
this.refName = config.refName; | ||
this.refNameType = config.refNameType; | ||
this.groupChatId = config.groupChatId; | ||
this.groupChatIdType = config.groupChatIdType; | ||
this.channelId = config.channelId; | ||
this.channelIdType = config.channelIdType; | ||
var node = this; | ||
@@ -27,0 +38,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
819402
4005