User tests: Successful: Unsuccessful:
Propose showing of relative date instead of date time in the Logged in Users module in admin.
Check the Home Dashboard -> Logged In Users module - look at it
Apply PR
Look at it again and note the times are now relative
none
Status | New | ⇒ | Pending |
Category | ⇒ | Modules Administration |
Title |
|
That is correct. It’s actually a last seen date and not a logged in date time
Check without this PR and you will see the same thing - it updates on page load
Sent from my iPhone
On 29 Mar 2021, at 05:29, Rishabh Ranjan Jha @.***> wrote:
It always shows Less than a minute ago.—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
Without this PR, logged in date and time shown
No it doesnt.
Without this PR, the mod_logged shows the time
field from the #__session
table which is updated on every page load.
It is retrieved from the #__session
table here:
This module is not telling you the time someone logged in, as confusing as that is for a module called mod_logged.
Its telling you time the session was updated (the last page load normally)
This PR make no changes to that logic, all it does is display the date/time in a different way.
Thanks for clarification
I can find no examples of getDate
accepting a unix timestamp as a parameter, and that's what we have here.
I'll test later tonight.
Can we please make this configurable? As I created PR #31675 already some time ago, where it is documented that not everyone prefers the relative display instead of an absolute one. If we add relative display not only for the action logs, but also in other places in core, it might be better to have a user-specific setting for this instead of the parameter I added for com_actionlogs.
If I read the code right, the relative date will only show if the date is less than 4 weeks, else the full date would be shown as normal. The things on the dashboard are recent things, and so a relative date is best for them.
I have tested this item
I was confused by the Less than a minute ago
too but with the explanation of the time being since the last page load I definitely approve. I use this feature quite a loy in a J3 installation.
The home dashboard is an overview of the RECENT happenings on a site therefore it MAKES SENSE that this screen should have relative dates.
On normal listing screens date stamps are better, and can be ordered etc, but on the Home Dashboard a relative timestamp is better.... unless your site is dead and inactive and you have nothing to show recently of course, then, the relative date AFTER FOUR WEEKS turns back into a date
IIRC you can also hover over "one hour ago" to see the exact date/time. Apparently not, although that could easily be added.
Labels |
Added:
?
|
maybe i've been unexplicative
matter of personal taste
much more imho
Well as Joomla 3.9, 3.10 and 4.0 are no longer accepting "new features" any "preference selection" would have to be a different PR aimed at 4.1 whenever that would be released in 2030+
grr
i always hate when something is on the bordeline
whatever can be your choice....i'm optimistic here 50/50... 2025?
I'll do the work, but I have no say in when, if ever, it gets merged. At the moment Ive had several rejected.
If I read the code right, the relative date will only show if the date is less than 4 weeks, else the full date would be shown as normal.
That's correct. Still I'm confused by things like "2 weeks ago" or "5 days ago" - was it Wednesday? Thursday? Let me calculate...
Though I see your point here:
The home dashboard is an overview of the RECENT happenings on a site therefore it MAKES SENSE that this screen should have relative dates.
On normal listing screens date stamps are better, and can be ordered etc, but on the Home Dashboard a relative timestamp is better.... unless your site is dead and inactive and you have nothing to show recently of course, then, the relative date AFTER FOUR WEEKS turns back into a date
Whether one or the other is better is a question of personal taste, thus, I'd prefer the parameter. As you see in #31675, there are several people saying "just get rid of the parameter and display it in absolute format" and several saying "just get rid of the parameter and display it in relative format".
I agree that the argumentation for relative dates is stronger in this case here than for the whole action logs table.
IIRC you can also hover over "one hour ago" to see the exact date/time.Apparently not, although that could easily be added.
So I'd kindly ask you to at least include this tooltip in your PRs to give users the chance to see the absolute date.
Well as Joomla 3.9, 3.10 and 4.0 are no longer accepting "new features" any "preference selection" would have to be a different PR aimed at 4.1 whenever that would be released in 2030+
Seems a bit counterintuitive to me that changing the display would be considered a bug fix or cosmetical change (for 4.0), but making it configurable would be a new feature (4.1)?
Okay, you two are writing faster than I am.
I'll do the work, but I have no say in when, if ever, it gets merged. At the moment Ive had several rejected.
Would be very much appreciated! :-)
I have tested this item
Tested successfully in Beta8-dev of 29 March in Wampserver 3.2.4 using PHP 8.0.2.
Im not going to add yet-another-useless-option to toggle between relative/absolute dates on a dashboard of "recent activity"... sorry. Joomla has enough insane options.
So lets get this tested, (hint: it works) and then we can get it merged and move on.
I have tested this item
Works fine - I like it.
Status | Pending | ⇒ | Ready to Commit |
RTC
Did anyone tested that filtering by date is still functional after applying this PR?
Its was not possible before or after this PR to sort by date in this module.
Yeah, just realised that this is not a list view although it resembles one
I'm against this change for multiple reasons but most of them are personal ;-)
Anyway column header is "Date" the value "2 minutes ago" is not a date so it should be "last seen" aside this I prefer real dates especially if the values are bigger then a day. Also there is no fallback like a tooltip with the real date.
Status | Ready to Commit | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2021-04-08 08:14:17 |
Closed_By | ⇒ | PhilETaylor | |
Labels |
Added:
?
|
It always shows Less than a minute ago.