-
-
Notifications
You must be signed in to change notification settings - Fork 523
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Config UI: add missing config sections / partial yaml inputs (BC) #13319
base: master
Are you sure you want to change the base?
Conversation
@naltatis ich brauche mal eine Idee. ModbusProxy ist eine Liste. Wie wollen wir hier mit Updates umgehen:
Meine Tendenz wäre per Element über numerischen Index. Passt das? |
@andig Im ersten Schritt (dieser PR) würde ich dir nur einen Yaml Block geben und keine Rücksicht auf die innere Struktur nehmen. Heißt, ein Update hat immer ein komplettes Neu-initialisieren zur Folge. Nichts auf Item-Ebene. Gleiches gilt für Messaging. Da ist die Struktur ja noch komplizierter, weil Messages und Services (Liste). Das ist natürlich nicht schön und wir müssen das früher oder später sauber als Struktur/Liste ausmodellieren. Aber ich sehe das hier erstmal als einen pragmatischen Zwischenschritt. |
Passt, das ist hässlich aber einfach. |
@naltatis die existierenden Site APIs, z.B: Vorschlag:
Wenn das passt müssen wir noch die Settings initial migrieren und dann nur noch aus der DB lesen. |
cmd/migrate.go
Outdated
// TODO remove yaml file | ||
settings.SetInt(keys.Interval, int64(conf.Interval)) | ||
|
||
// TODO add remaining settings @naltatis (site? loadpoints? residualpower?) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing values are: siteTitle
, sponsorToken
, residualPower
, maxGridSupplyWhileBatteryCharging
,
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Es lassen sich nur die globalen Settings migrieren, also das Token. Der Rest ist in der global Config aktuell nicht ausmodelliert. Das müssten wir sonst noch ändern. Ich schaue nochmal...
Ähhhhh- aber wieso landen wir beim Golf jetzt bei Temp statt Soc? |
siehe Kommentar am Screenshot 😄 |
@naltatis statt "configured" bei Circuits the Leistungen/Ströme? |
Gerne. Configured: true ist gerade mein Save-Default der für alle YAML Entitäten geht. Da check ich einfach, ob der GET-Endpunkt Inhalt zurückliefert. Bei MQTT/Influx werden die gepublishten Details genommen. Wenn wir für die anderen Einträge auch sinnvolle Infos haben, wäre das total gut und einfach einzubauen. Connection-Status wäre bei Influx und MQTT auch spannend. Also ob der letzte Kommunikationsversuch erfolgreich war oder nicht. Aber jetzt sind wir im Nict To Have Bereich. |
ClassGo | ||
ClassHEMS | ||
ClassInflux | ||
ClassMessenger |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No ModbusProxy?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dazu gibts ein Todo. Kann egtl. fast keinen Fehler machen ausser Port belegt. Kannnich ergänzen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In der UI reagiere ich bereits auf modbusproxy
. Brauchst also nur die Implementierung dafür ergänzen und dann sollte es laufen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, Sponsortoken ebenfalls hinzu gefügt!
@andig Ich hab bei Achja: Migrate schreibt, zumindest bei mir. Momentan noch nichts in die Datenbank. |
All done except
|
Ich habs jetzt |
@@ -834,6 +834,7 @@ func configureTariffs(conf globalconfig.Tariffs) (*tariff.Tariffs, error) { | |||
} | |||
|
|||
func configureDevices(conf globalconfig.All) error { | |||
// TODO: add name/identifier to error for better highlighting in UI |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@naltatis wird doch mal einen Blick in configureMeters
. Das TODO kann weg...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Das war übrigens die Diskussion zum RCT vom Freitag wo wir genau das ausprobiert hatten ;)
Ich hab ein paar Anpassungen an der Migration gemacht. Nun startet es auch und kopiert die richtigen Daten. Allerdings funktioniert |
Wohl so ein ORM-Ding. Ich schaus an. An der Stelle müssen wir ja leider echt löschen- leer setzen reicht nicht. |
Replaces #11739
Goal
Later steps (seperate PRs)
BC
Todos
remove all ns conversions from UI@naltatistemp
in addition tosoc
@naltatisdirty
api to web socketOut of scope: