Revise power and energy units and property names. (#6212)

* Revise power and energy units and property names.

* Add change for new wemo parameter.
This commit is contained in:
Greg Dowling authored and Pascal Vizeli committed 2017-03-19 22:02:11 +01:00
1 parent 970bde9e99
commit acf75b5253
12 files changed
+50 -49

No files matched your search

-4
View File
@@ -23,10 +23,7 @@ REQUIREMENTS = ['pynetio==0.1.6']
_LOGGER = logging.getLogger(__name__)
ATTR_CURRENT_POWER_MWH = 'current_power_mwh'
ATTR_CURRENT_POWER_W = 'current_power_w'
ATTR_START_DATE = 'start_date'
ATTR_TODAY_MWH = 'today_mwh'
ATTR_TOTAL_CONSUMPTION_KWH = 'total_energy_kwh'
CONF_OUTLETS = 'outlets'
@@ -172,7 +169,6 @@ class NetioSwitch(SwitchDevice):
def state_attributes(self):
"""Return optional state attributes."""
return {
ATTR_CURRENT_POWER_W: self.current_power_w,
ATTR_TOTAL_CONSUMPTION_KWH: self.cumulated_consumption_kwh,
ATTR_START_DATE: self.start_date.split('|')[0]
}