I like the idea.
Since the device name is already clickable, maybe an optional “Battery Management” page/view within the app itself would make sense for local app-managed items such as:
- battery type
- replacement dates
- custom thresholds
- notes/history
I may be misunderstanding part of the request, but I would probably avoid direct device setting/configuration changes from within the app itself, since those are typically driver/device-specific within Hubitat.
That would keep device configuration in Hubitat, while making battery management workflows much easier from within the app.
1 Like
I'm liking what I'm seeing so far.
Couple of things that I think need to be adjusted:
After going into Device Battery Management and setting a device's battery type, when you go back in, that same device is selected. That should be cleared out, in my opinion, each time you enter that section of the app.
Also, unless I am missing something, you need to hit the Done button and then go back to keep setting battery types. Seems a bit inconvenient when you have many devices. There should be a way to go through and set each device's battery type and hit save to move on to the next device, rather than hitting Done and having to go back. Hope that makes sense,
1 Like
Getting there.
The Device Battery Management section still opens to the last device selected.
Why not have it open to "No selection"?

This is a bit awkward and unnecessary, if the selection list were to default to "No selection".

Lastly, currently, when you toggle "Clear device selection" the last device still shows here after the selection has been cleared:

This all would be unnecessary if the device list simply defaulted to "No selection".
Issue is with how the page renders and HE limitations. I will circle back to the "no selection" because i did not think of that.
Refresh you app code to BETA 3. Report back
1 Like
Missing the entire Battery Type section in Beta 3.
Also, the Battery Replacement History section should no longer be needed here:

1 Like
got it- i will come back to this in a few hours.... 
Fix one thing, break 3 others.......
2 Likes
It's all looking good to me.
One note that I believe I mentioned above, but I'm not sure if it can be done or not. After toggling "Clear device selection" this should likely be cleared as well:

Clear Device Selection in BETA 3:
This is a known Hubitat framework limitation I ran into during development. App settings persist across re-renders, so clearing the device selection and having the header disappear in the same render cycle isn't possible within the framework. The header will clear on the next page entry after the toggled fired.
BETA 4
I removed the clear toggle in BETA 4 and replaced it with a note explaining that the last selected device is remembered — change the dropdown to switch devices. It's not perfect but it's the most reliable behavior I can get within Hubitat's constraints.
I tried about 15 variations and this one was the cleanest solution.
If anyone has an idea to make this work, I'm all ears.
1 Like
I forgot to update the code in the link.......
swap for BETA 4
1 Like
Thoughts on removing the progress bars for a smoother and more compact summary view...... Once established, it disappears anyway.
1 Like
Beautiful!!!!
And, yes, remove the progress bars,
Great work on this!!
I may be misunderstanding part of the request, but I would probably avoid direct device setting/configuration changes from within the app itself, since those are typically driver/device-specific within Hubitat.
Oh, that's not what I had in mind. The confusion is probably from where I was describing that the default action when clicking on a device name is to go to the device settings page. Since that's already accessible from the Devices menu, I was envisioning that clicking in the device name within Battery Monitor would got to battery management for the specific device.
BETA 6 addresses some of it but in a different way. Device set up, via app, was problematic.