export stuff

This commit is contained in:
2018-04-03 00:40:50 +02:00
parent 2e251fe3bc
commit b9ac97f2df

View File

@ -59,6 +59,7 @@ function RelayBoxOpenHABExport(itemId: string, stateTopicPre: string, feedbackTo
let o : string[] = [] let o : string[] = []
itemNames.forEach((label: string, index: number) => { itemNames.forEach((label: string, index: number) => {
o.push(`Switch ${itemId}${index} "${label}" {mqtt=">[localbroker:${stateTopicPre}/${index}:command:*:default],<[localbroker:${feedbackTopicPre}/${index}:state:default]"}`) o.push(`Switch ${itemId}${index} "${label}" {mqtt=">[localbroker:${stateTopicPre}/${index}:command:*:default],<[localbroker:${feedbackTopicPre}/${index}:state:default]"}`)
o.push(`Switch ${itemId}${index}Conflict "${label} [%s]" {mqtt="<[localbroker:${conflictTopicPre}/${index}:state:default]"}`)
}) })
return o return o
} }