I have a Login Action which is used by all of the web and mobile apps. It checks to ensure the user is active in LDAP and sets their account to active like so:
On Web applications this works fine, the "User_Login" also correctly sets the User.last_Logon field. However on Mobile applications, neither is set. So if I look at that user account in Users app, their account is still inactive and the User.Last_login is not correct. The user is still able to log into the app and use it.
Any ideas what might be happening?
ThanksChris
Hi Chris.
Have you tried debugging it and seeing if everything is getting called? I am assuming that your mobile app is online when all this is running.
Stacey
Hello Stacey, Appreciate your advice. I have done a bit of debugging and it seems that everything is being called correctly on login, I have tested it in both Dev and Prod environments and it seems to work for my account and my test account which are all configured the same as other users.
However I just got a different user to log in and the last log in date was not updated.
The Last Login date is set in the User_Login Action, which is obviously called if the user is able to log on. Just it doesnt appear to be set all the time for users logging into mobile app.
All of this is done online wifi/4g as the server action wouldnt be called at all offline.
Thanks
Chris
Hi Chris,
So one more question. What version of the platform are you using? What version of OutSystems UI?
That will help me look into it more.
We are using OutSystems 11,
OutSystems UI (Library) version 2.5.6 though this is different in production
Thanks,
I have also raised a support case with OutSystems as they might be able to see what is happening on their side, I will update you if i get any further information from them, but in the mean time I really appreciate you helping.
Hi Chris, I have a similar issue - did you get any response from Outsystems?
Tim
Hello Tim, Apologies for the delay in my reply. Outsystems support think it may be the logic ive used in my login action that might be causing it so we have implemented some log messages to try and catch any exceptions etc. Will let you know how I get on, but may be some time.
Hello Christopher!
Have you been able to solve this?
Hello Wendy,
I dont think we ever got to the bottom of it. However we did create a bespoke application user login tracker so we could tell who has logged into what app and when.
I shall double check and get back to you.
Something I found is if you have another action that updates the user entity before the User_Login action then you need a committransaction action between them to ensure the User.Last_Login is updated during the user_login action.