Skip to content

Commit

Permalink
feature: add other vessel cpa notification
Browse files Browse the repository at this point in the history
Add other vessel's context id to cpa notification.
  • Loading branch information
tkurki committed Feb 22, 2025
1 parent 6cc9889 commit 87d8ac5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion calcs/cpa_tcpa.js
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,7 @@ module.exports = function (app, plugin) {
message: `Crossing vessel ${vesselName} ${cpa.toFixed(
2
)} m away in ${(tcpa / 60).toFixed(2)} minutes`,
other: `vessels.${vessel}`,
cpaPositions,
timestamp: new Date().toISOString()
}
Expand Down Expand Up @@ -365,7 +366,8 @@ function normalAlarmDelta (selfId, vessel) {
path: 'notifications.navigation.closestApproach.' + vessel,
value: {
state: 'normal',
timestamp: new Date().toISOString()
timestamp: new Date().toISOString(),
other: `vessels.${vessel}`
}
}
]
Expand Down

0 comments on commit 87d8ac5

Please sign in to comment.