mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-23 17:26:42 +00:00
Fix picking energy sensors for gas (#14448)
This commit is contained in:
parent
9bae4a646d
commit
0aa2c9044a
@ -24,6 +24,9 @@ import {
|
|||||||
isExternalStatistic,
|
isExternalStatistic,
|
||||||
} from "../../../../data/recorder";
|
} from "../../../../data/recorder";
|
||||||
|
|
||||||
|
const gasDeviceClasses = ["gas", "energy"];
|
||||||
|
const gasUnitClasses = ["volume", "energy"];
|
||||||
|
|
||||||
@customElement("dialog-energy-gas-settings")
|
@customElement("dialog-energy-gas-settings")
|
||||||
export class DialogEnergyGasSettings
|
export class DialogEnergyGasSettings
|
||||||
extends LitElement
|
extends LitElement
|
||||||
@ -103,11 +106,9 @@ export class DialogEnergyGasSettings
|
|||||||
|
|
||||||
<ha-statistic-picker
|
<ha-statistic-picker
|
||||||
.hass=${this.hass}
|
.hass=${this.hass}
|
||||||
.includeUnitClass=${this._params.allowedGasUnitClass || [
|
.includeUnitClass=${this._params.allowedGasUnitClass ||
|
||||||
"volume",
|
gasUnitClasses}
|
||||||
"energy",
|
.includeDeviceClass=${gasDeviceClasses}
|
||||||
]}
|
|
||||||
include-device-class="gas"
|
|
||||||
.value=${this._source.stat_energy_from}
|
.value=${this._source.stat_energy_from}
|
||||||
.label=${`${this.hass.localize(
|
.label=${`${this.hass.localize(
|
||||||
"ui.panel.config.energy.gas.dialog.gas_usage"
|
"ui.panel.config.energy.gas.dialog.gas_usage"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user