Closed MichaelTunnell closed 7 years ago
Well, actually the given code should not be used the way you've described. There is a logical mistake. If the appropriate warning is switched off (or not defined), then the operator will be shown as "online" regardless of his actual status.
At the same time I understand that you want to be able to get an actual status of an operator on any page in the administrative interface.
Now one could use is_online
value in the templates for any page of the administrative interface.
Awesome, so I can modify my theme to use the new is_online call to display it how I intended?
Please wait for a while until we release 2.2.0. At the moment I can't guarantee that the variable's name will stay the same.
that's fine . . . I will just put it as a known bug so people can be aware of the issue in the meantime.
So, it's done, the name will be the same old isOnline
.
So I assume I won't need to change the code after all?
Yep, seems so.
Nice! ;)
The above code is used to indicate if an operator is logged in or not but the value it outputs is inconsistent depending on the page parsing it.
On the dashboard:
In the console (visitors page):
On any other page:
This can be tested using my theme where I moved the indicator to the side menu.