EEBUS: configure by default (#26944)
This commit is contained in:
parent
ca7bbba0a4
commit
768656e0c3
52 changed files with 712 additions and 324 deletions
|
|
@ -297,7 +297,6 @@ func (s *HTTPd) RegisterSystemHandler(site *core.Site, pub publisher, cache *uti
|
|||
|
||||
// yaml handlers
|
||||
for key, fun := range map[string]func() (any, any){
|
||||
keys.EEBus: func() (any, any) { return map[string]any{}, eebus.Config{} },
|
||||
keys.Hems: func() (any, any) { return map[string]any{}, config.Typed{} },
|
||||
keys.Tariffs: func() (any, any) { return map[string]any{}, globalconfig.Tariffs{} },
|
||||
keys.Messaging: func() (any, any) { return map[string]any{}, globalconfig.Messaging{} }, // has default
|
||||
|
|
@ -316,6 +315,7 @@ func (s *HTTPd) RegisterSystemHandler(site *core.Site, pub publisher, cache *uti
|
|||
keys.ModbusProxy: func() any { return new([]globalconfig.ModbusProxy) }, // slice
|
||||
keys.Shm: func() any { return new(shm.Config) },
|
||||
keys.Influx: func() any { return new(globalconfig.Influx) },
|
||||
keys.EEBus: func() any { return new(eebus.Config) },
|
||||
} {
|
||||
routes["update"+key] = route{Method: "POST", Pattern: "/" + key, HandlerFunc: settingsSetJsonHandler(key, pub, fun)}
|
||||
routes["delete"+key] = route{Method: "DELETE", Pattern: "/" + key, HandlerFunc: settingsDeleteJsonHandler(key, pub, fun())}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue