Skip to content

Commit

Permalink
[tradfri] Internationalization of discovery results (openhab#11498)
Browse files Browse the repository at this point in the history
Signed-off-by: Laurent Garnier <lg.hc@free.fr>
Signed-off-by: Nick Waterton <n.waterton@outlook.com>
  • Loading branch information
lolodomo authored and NickWaterton committed Dec 30, 2021
1 parent 2ff8f38 commit dcceaad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,9 @@ public String getServiceType() {
if (fwVersion != null) {
properties.put(PROPERTY_FIRMWARE_VERSION, fwVersion);
}
return DiscoveryResultBuilder.create(thingUID).withProperties(properties).withLabel("TRÅDFRI Gateway")
.withRepresentationProperty(GATEWAY_CONFIG_HOST).build();
return DiscoveryResultBuilder.create(thingUID).withProperties(properties)
.withLabel("@text/discovery.gateway.label").withRepresentationProperty(GATEWAY_CONFIG_HOST)
.build();
} else {
logger.warn("Discovered Tradfri gateway doesn't have an IP address: {}", service);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,7 @@ thing-type.config.tradfri.device.id.description = The identifier of the device o

channel-type.tradfri.position.label = Position
channel-type.tradfri.position.description = Control the position of the blind or curtain in percent from 0 (open) to 100 (closed).

# discovery result

discovery.gateway.label = TRÅDFRI Gateway

0 comments on commit dcceaad

Please sign in to comment.