Alerts that are recently viewed need to persist per user, and even when the machine changes, it still needs to be there.
Todo:
[x] Research on how to implement cache
UPDATE:
After researching, recently viewed alerts should be stored as in db as a new column/key in the Agent table/collection.
recentlyViewedAlerts in the Agent table is updated every time an agent logs out.
Temporarily it is still going to be stored in local storage as this is a data that is frequently changing.
Storing it in local storage will reduce the workload of the db.
Todo:
[x] Build db route to store recently viewed alerts in the agent table.
Alerts that are recently viewed need to persist per user, and even when the machine changes, it still needs to be there.
Todo:
UPDATE: After researching, recently viewed alerts should be stored as in db as a new column/key in the Agent table/collection. recentlyViewedAlerts in the Agent table is updated every time an agent logs out. Temporarily it is still going to be stored in local storage as this is a data that is frequently changing. Storing it in local storage will reduce the workload of the db.
Todo: