iOS Safari has no beforeinstallprompt API, so the portal's Install
button (?install=1) silently did nothing there. IosInstallHint now
shows Share -> Add to Home Screen steps on Safari, or a prompt to
switch to Safari first if opened in another iOS browser/in-app
webview (those can't install PWAs on iOS at all).
Also added apple-mobile-web-app-title + apple-touch-icon so the
home screen icon isn't a page screenshot, and added the
beforeinstallprompt handler that was missing entirely (Android
Install button did nothing either).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The unordered plant_asset_latest query could return rows in a different
order after every MQTT upsert, making the field list under each asset card
appear to shuffle. Added ORDER BY, plus a curated label/unit/order table
for the known water-softener fields (Salt Level 42%, Tank A Capacity
1850 L, Regeneration Active Yes/No, ...) with a title-case + alphabetical
fallback for anything not yet mapped.
Regen flow indicators now show 2 chevrons instead of 3 so the diagram row
fits without wrapping on narrow cards. Added a pulsing vertical chevron
stack under each tank's % reading, shown when that tank is actually
in-service and passing water (not regenerating).
Tank A / Brine / Tank B reads more clearly as which side brine is flowing
into than the previous Brine / A / B order. Flow chevrons now point away
from the brine tank toward whichever resin tank is regenerating.
The regenerating tank is the one NOT currently in service — on an
alternating twin-tank softener, service switches to the other tank the
moment one depletes, and the just-depleted tank regenerates offline. Was
previously showing regen on the in-service tank. Also splits the flow
indicator so it visually tracks whichever tank is actually regenerating.
Per-asset diagram_config (JSONB) maps live MQTT field_keys to brine/resin
tank roles, editable on the Assets page with dropdowns populated from that
asset's actual telemetry. Dashboard renders brine + 1-2 resin tanks with
color-coded fill levels, an "in service" tank indicator, and an animated
flow/regen indicator when regeneration is active.
Was reading the shared central mqtt integration, which meant plant
silently authenticated as whichever app's credentials were pasted
there (no plant/# ACL on any of them, so no telemetry ever arrived).
Now reads mqtt_plant instead, its own dedicated slug.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Read-only monitoring/alerting for boilers, water softener, calorifiers
and pumps via a generic MQTT-topic-prefix asset model, so new
equipment can be onboarded without new ingestion code. Threshold and
stale-data alert rules with email + in-app notification.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>