Create an account and login in the same session
LastvisitDate in the #_users table to be set to the login time
LastvisitDate stays at 0000:0000:0000:0000 until you login in a new session
Joomla 3.4.8
am I missing something, should I clear something for this to work, this is rather odd.
ahh clever...
but too clever
most people just expect it to be the time/date you last logged in or better last time you made a request, so having it show "NEVER" as it does now in the backend control panel makes no sense, since the user is actually visiting that moment.
It is called last visit not last logged in so it makes perfect sense for
what it is supposed to be. You want it to be something different
On 15 March 2016 at 15:45, Joris Ceelen notifications@github.com wrote:
ahh clever...
but too clever
most people just expect it to be the time/date you last logged in or
better last time you made a request, so having it show "NEVER" as it does
now in the backend control panel makes no sense, since the user is actually
visiting that moment.—
You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
#9436 (comment)
Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/
man.. you freak me, you think to difficult
when you invite your neighbours over for a visit , he comes and then he goes away, you can't say then his last visit date was NEVER, this is what it does now.
the user is visiting at the moment, is current logged in and when I do a search in the backend on that user it says in the last visit date NEVER, even after he goes away it will keep saying NEVER as a last visit date until he visits again in a new session.
You havent done a last visit until the first visit is over.
when you invite your neighbours over for a visit , he comes and then he goes away, you can't say then his last visit date was NEVER, this is what it does now.
Nice conversation :D
Don't worry, I do really appreciate @brianteeman, I often wear my IT hat and try to apply strict logical rules, but I do freak myself sometimes too by missing something obvious and the end user suffers because he cannot understand what is happening, and I feel Joomla is a bit like that for the end user sometimes.
In this case I think the user misses out on a visit, and it shows the wrong information in the backend report, can anybody else give an opinion?
Sorry I was completely wrong. Serves me right for doing it from memory.
I have just checked and the record is created on login not logout so your expectation was correct and I was wrong
However when I went to check that this was indeed happening (or not as you stated) then it did correctly create a timestamp as soon as I logged in. So your expectation was correct but I cannot replicate your bug report.
okay I will get back to you let me verify that, I need to do a few things now first but I will get back to you and I definitely have this issue in some way or another.
Thanks @brianteeman
What i didnt test was self registration. I was creating site in the admin and then using it in he front end
Ok I will test that, those are two different sessions I think as you can
log-in as a different users in front and backend at the same time.
It may take a few days before I get back, I will get back. Joris
On 2016-03-15 20:22, Brian Teeman wrote:
What i didnt test was self registration. I was creating site in the admin and then using it in he front end
This comment was created with the J!Tracker Application [1] at issues.joomla.org/joomla-cms/9436 [2].
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub [3]
POQUEIRAWEB.COM [4]
This message was sent with Roundcube, free open-source software
licensed with the GNU General Public License 5 Version 3.
Our office is 100% solar powered.
[1] https://github.com/joomla/jissues
[2] https://issues.joomla.org/tracker/joomla-cms/9436
[3]
#9436 (comment)
[4] http://poqueiraweb.com
[5] https://www.gnu.org/licenses/gpl.html
Labels |
Added:
?
|
Hey @GeoTimber - know you said you'd be a few days but just wanted to check in and see if you had made any progress on this?
Hi @brianteeman, @wilsonge
I only work on Monday and Tuesday on this, have some other projects going ;), thanks for getting back.
I created a clean install and tested front user creation and could not recreate the problem.
So I investigated my code more and traced it back to a
$user=JFactory::getUser();
$user->name=$newName;
if (!$user->save()) {..}
call I do in the first session ( in a save event of a custom user profile edit screen with the ability to change the users's name )
Here the current logged in user object is retrieved from the session storage and not from the jml_users table in the database
( file/code)
libraries/joomla/factory.php line 236 :
public static function getUser($id = null)
{
$instance = self::getSession()->get('user');
thus the user object from the session storage has the lastvistDate not set YET apparently, and therefore on a save it will be overwritten.
So more or less a fiddle, but nevertheless not exactly the expected behavior in my case.
... I guess the last visit is not set until it is over ;) ...
Hope this helps and that I am right, Joris
As you have stated that their is no issue in the core code but in your custom code I am closing this
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-03-29 10:32:05 |
Closed_By | ⇒ | brianteeman |
You havent done a last visit until the first visit is over.
On 15 March 2016 at 15:13, Joris Ceelen notifications@github.com wrote:
Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/