Skip to content

Commit

Permalink
Merge c398a3a into a39846b
Browse files Browse the repository at this point in the history
  • Loading branch information
ludeeus committed Nov 2, 2018
2 parents a39846b + c398a3a commit f83d04d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions homeassistant/components/input_number.py
Expand Up @@ -28,6 +28,7 @@
MODE_SLIDER = 'slider'
MODE_BOX = 'box'

ATTR_INITIAL = 'initial'
ATTR_VALUE = 'value'
ATTR_MIN = 'min'
ATTR_MAX = 'max'
Expand Down Expand Up @@ -131,6 +132,7 @@ def __init__(self, object_id, name, initial, minimum, maximum, step, icon,
self.entity_id = ENTITY_ID_FORMAT.format(object_id)
self._name = name
self._current_value = initial
self._initial = initial
self._minimum = minimum
self._maximum = maximum
self._step = step
Expand Down Expand Up @@ -167,6 +169,7 @@ def unit_of_measurement(self):
def state_attributes(self):
"""Return the state attributes."""
return {
ATTR_INITIAL: self._initial,
ATTR_MIN: self._minimum,
ATTR_MAX: self._maximum,
ATTR_STEP: self._step,
Expand Down

0 comments on commit f83d04d

Please sign in to comment.