Skip to content

Lad als routing#342

Merged
OSPFNeighbour merged 2 commits intomaster-devfrom
lad-ALS-routing
Mar 17, 2026
Merged

Lad als routing#342
OSPFNeighbour merged 2 commits intomaster-devfrom
lad-ALS-routing

Conversation

@OSPFNeighbour
Copy link
Collaborator

This pull request adds support for ranking and displaying teams based on road travel time using Amazon Location Service routing, rather than just crow-flies (haversine) distance. It introduces a new helper for batch route fetching, integrates road-routing into the team suggestion engine, and updates the UI to show travel time calculations and allow users to enable road-routing in the config. The changes improve the accuracy of team suggestions and provide more informative feedback to users.

Road-routing integration:

  • Added batchRoute.js helper to fetch road-routing summaries (distance and travel time) for multiple origin→destination pairs using Amazon Location Service, with robust error handling and geometry extraction.
  • Updated InstantTaskViewModel to cache route results per team, trigger route fetches when the instant-task dropdown opens, and re-rank teams using road travel time when enabled. Also added logic to cancel pending requests when the dropdown closes. [1] [2]

Team suggestion engine enhancements:

  • Modified TeamSuggestionEngine.js to use travelTimeSeconds as the proximity dimension when available, falling back to haversine distance otherwise. Added proximityValue and fmtProximity helpers for sorting and display, updated sorting and scoring logic, and improved summary lines to show travel time and road distance when routing data is present. [1] [2] [3] [4] [5] [6]

UI and config updates:

  • Added a Knockout custom binding bsDropdownOpen to bridge Bootstrap dropdown events to an observable, enabling route fetches only while the dropdown is open. [1] [2] [3]
  • Updated job popup UI to show a spinner and "Calculating travel time…" message while route data is loading.
  • Added a config option suggestionUseRouting to enable/disable road-routing for team suggestions, including persistence and reactive updates. [1] [2] [3] [4]

@OSPFNeighbour OSPFNeighbour merged commit 40763a2 into master-dev Mar 17, 2026
@OSPFNeighbour OSPFNeighbour deleted the lad-ALS-routing branch March 17, 2026 10:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant