Simplify HEMS api (#31428)

This commit is contained in:
andig 2026-07-18 10:58:06 +02:00 • committed by GitHub
parent 199365288a
commit e239af5d25
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 255 additions and 121 deletions

View file

@ -370,10 +370,10 @@ func runRoot(cmd *cobra.Command, args []string) {
Status: struct {
Dimmed *bool `json:"dimmed,omitempty"`
Curtailed *int `json:"curtailed,omitempty"`
MaxConsumptionPower float64 `json:"maxConsumptionPower,omitempty"`
MaxConsumptionPower *float64 `json:"maxConsumptionPower,omitempty"`
MaxProductionPower *float64 `json:"maxProductionPower,omitempty"`
}{
Dimmed: hemsInstance.Dimmed(),
Dimmed: hems.Dimmed(hemsInstance),
Curtailed: hemsInstance.CurtailedPercent(),
MaxConsumptionPower: hemsInstance.MaxConsumptionPower(),
MaxProductionPower: hemsInstance.MaxProductionPower(),