You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Client groups. A group is a named collection of clients with its own URL list. Membership is many-to-many, so one screen can sit in several groups at once - a building, and a role such as "outdoor". A group either adds its URLs to each member's normal rotation, or replaces them entirely for a takeover; where a client lands in more than one active replace group, the highest priority wins. Groups can be parked without being deleted, and removing a client or a group clears its membership so a screen registered later under a recycled name cannot inherit somebody else's groups.
Emergency mode can target a group or a single client. Previously it was all or nothing: a weather warning for one building put every screen in the estate onto the emergency URLs. The global switch is unchanged and still overrides everything, but alongside it any group or client can be put into emergency mode on its own, from the group page, the client page, or a new panel on the Emergency Messages screen that lists everything currently live. Emergency URLs are scoped the same way, and a target with no URLs of its own falls back to the shared list.
Emergency mode now expires by itself. Every targeted emergency, and the global switch when the monitor raises it, records an expiry taken from the alert's own CAP <expires> where there is one. The client page honours it, so a monitor that stops running mid-alert no longer strands every display on it indefinitely - previously nothing stood emergency mode down except the monitor running again.
Alert routing. The emergency monitor can send an alert to particular screens rather than all of them, configured under Emergency Messages → Alert Routing: "an alert whose fieldmatchesvalue raises emergency mode for this group or client", with a minimum severity. Routing reads CAP category, certainty, areaDesc and geocode (SAME, FIPS6 and UGC) - the fields you actually address a locality by, none of which were parsed before - as well as event, severity, urgency, sender and headline. CAP allows those to repeat, so an alert covering three counties reaches a rule naming any one of them, and each destination gets its own message so two groups can show two different alerts at once. With no rules configured the monitor drives the global switch exactly as it did in 3.0.0, and once rules exist the global switch is only raised by a rule that explicitly targets every client, so a targeted alert cannot black out the estate. The monitor only ever clears emergencies it raised itself, so a takeover switched on by hand is never cancelled by the next feed poll.
A test suite, run in CI on PHP 7.4, 8.1, 8.3 and 8.4.php Tests/run-tests.php stands up a throwaway install - a copy of the application, a SQLite database built from the shipped schema, and a web server - and drives it over HTTP, covering what a display is served, group resolution, emergency precedence and expiry, the monitor's CAP parsing and routing, and upgrading a database that predates each feature. CI also lints every PHP file and compiles every Smarty template. It needs nothing installed, matching the fact that UNS ships without Composer.
New tables (client_groups, client_group_members, group_links, emerg_targets, emerg_routes) and the two new emerg columns are created on demand the first time they are used, so existing installs need no upgrade step.
🐞 Bug fixes
Emergency mode served nothing at all on a fresh install. The client page selected emergency URLs against an emerg.cl_id column that has never existed in any of the three schema files and that no code path has ever written - it dates to the original 1.0 import. Turning emergency mode on returned HTTP 500 with an empty body on SQLite, and left the display with no_urls on MySQL. The same condition was also mis-grouped, so the branch ignored whether an emergency URL was enabled.
A rotating display could show the same page twice in a row. The check for "the URL served last time" ordered only by a timestamp with one-second resolution, so any two requests landing in the same second left the previous URL arbitrary.
The client page emitted a PHP warning on every request for an unknown client, or one with no URLs, because the emergency flag was read from an array element those paths do not return. Present since the original import.
The uns_ver value seeded into a manually-created database still read 2.0.0; it is now kept in step with the release.