Tariffs: add outdoor temperature type and OpenMeteo (#27780)
Co-authored-by: Michael Geers <michael@geers.tv>
This commit is contained in:
parent
68db0b7727
commit
d68e5e5809
34 changed files with 449 additions and 135 deletions
|
|
@ -562,7 +562,7 @@ func cleanupTariffRef(name string) {
|
|||
return
|
||||
}
|
||||
|
||||
for _, ref := range []*string{&refs.Grid, &refs.FeedIn, &refs.Co2, &refs.Planner} {
|
||||
for _, ref := range []*string{&refs.Grid, &refs.FeedIn, &refs.Co2, &refs.Planner, &refs.Temperature} {
|
||||
if *ref == name {
|
||||
*ref = ""
|
||||
}
|
||||
|
|
|
|||
|
|
@ -470,6 +470,9 @@ func testInstance(ctx context.Context, instance any) map[string]testResult {
|
|||
case api.TariffTypeSolar:
|
||||
valueKey = "power"
|
||||
ratesKey = "solarRates"
|
||||
case api.TariffTypeTemperature:
|
||||
valueKey = "outdoorTemp"
|
||||
ratesKey = "temperatureRates"
|
||||
default:
|
||||
valueKey = "price"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue