[mqtt.generic] Percentage range fix #10586 (#10587)

Signed-off-by: Rogier Hofboer <rogier@hofboer.nl>
This commit is contained in:
Rogier Hofboer
2021-06-21 21:24:54 +02:00
committed by GitHub
parent ef1deff4e9
commit ea2cb217e0

View File

@@ -154,7 +154,7 @@ public class PercentageValue extends Value {
@Override
public StateDescriptionFragmentBuilder createStateDescription(boolean readOnly) {
return super.createStateDescription(readOnly).withMaximum(max).withMinimum(min).withStep(step)
return super.createStateDescription(readOnly).withMaximum(HUNDRED).withMinimum(BigDecimal.ZERO).withStep(step)
.withPattern("%s %%");
}
}