Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

showLastSeen option only shows as 'a few seconds ago' #29

Open
E3V3A opened this issue May 4, 2018 · 3 comments
Open

showLastSeen option only shows as 'a few seconds ago' #29

E3V3A opened this issue May 4, 2018 · 3 comments
Labels

Comments

@E3V3A
Copy link
Contributor

E3V3A commented May 4, 2018

Currently, when using the showLastSeen option, your entire lists, shows:
a few seconds ago, which is redundant, IMO.

Instead, it would be preferred that the last seen is:

  • only shown for devices that are were not present in the last scan, but within the keepAlive interval.
  • is shown in minutes, or something like: 2 min ago.

I realize this may be dependent on showOffline.

@ianperrin
What do you think?

@E3V3A
Copy link
Contributor Author

E3V3A commented May 4, 2018

I just noticed that when using both: showOffline and showLastSeen, the last seen is not shown for offline devices...which kind of defeats the purpose. That also causes the table columns for the device name to be misaligned.

@E3V3A
Copy link
Contributor Author

E3V3A commented May 9, 2018

How is the last seen text string constructed? I.e. a few seconds ago.

  1. I would like to get rid of that (since it is redundant) for the devices that are already shown as online.
  2. I would like to change it to:
  • < T sec for new online devices, that has appeared in the last scan interval of T.
  • X min || X hours for others

@ianperrin
Copy link
Owner

@E3V3A - it looks like there are some issues with the way the last seen time is calculated. I’ll need to trace the code for this at some point.

The value should be updated each time the device is found online and then displayed in a format relative to the current time using the moment library.

Once the value is being correctly set, the display should work in a similar way to how you’ve suggested.

@ianperrin ianperrin added the bug label May 10, 2018
@ianperrin ianperrin changed the title Improve showLastSeen option behaviour showLastSeen option only shows as 'a few seconds ago' May 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants