Hello! I've had my hubitat about a week now and loving the potential. I come from a long background of coding wordpress and php, with a little javscript here and there. I'm certainly struggling to learn groovy, and find the documentation a bit challenging at times.
However, I've muddled my way through my first coding endeavor. This is a driver which simply generates a new horoscope message of the day. It has a few other attributes returned from the API, and schedules a cron to run once a day at midnight to get new data.
I have two questions which I'm still unsure.
Is it possible to subscribe to event changes from a driver? Or does it have to be from an app?
On this horoscope driver, when editing the device, I click save preferences. But the attributes on the page do not update until a second page reload. The dashboard tile updates immediately. Is this normal behavior to need a second page reload of the device to see the updated results?
!) I figured, thank you.
2) It's funny, because I click save, the page reloads, and for a brief second the attributes show the correct values, then are overwritten with the older results. On a second reload, the updated results display correctly.
Great app idea! Horoscopes and biorhythms were the very first thing I programmed into my Hewlett-Packard 10C pocket calculator over 40 years ago, and (from a mathematical point of view, anyway) they still hold my interest.
Can't wait to see what you release. I'm already planning to include it on a "Wellness Chart" that I have in mind for my next dashboard project.
Thank you, thank you. Love the username.. appropriate! Yes, love how mathematics and astronomy/astrology work together. I was browsing free api's, and thought this would be a nice crash course into the groovy programming. I'll definitely have to learn apps next. Thanks for the kind words, be well, and hope to cross paths again soon!